Ver Fonte

fix swipe to reply icon visibility issue on iOS 11 and 12

cyberta há 4 anos atrás
pai
commit
f067e89a87
1 ficheiros alterados com 3 adições e 2 exclusões
  1. 3 2
      deltachat-ios/Chat/ChatViewController.swift

+ 3 - 2
deltachat-ios/Chat/ChatViewController.swift

@@ -493,14 +493,15 @@ class ChatViewController: UITableViewController {
                                             self?.replyToMessage(at: indexPath)
                                             self?.replyToMessage(at: indexPath)
                                             completionHandler(true)
                                             completionHandler(true)
                                         })
                                         })
-        if #available(iOS 12.0, *) {
+        if #available(iOS 13.0, *) {
             action.image = UIImage(named: traitCollection.userInterfaceStyle == .light ? "ic_reply_black" : "ic_reply")
             action.image = UIImage(named: traitCollection.userInterfaceStyle == .light ? "ic_reply_black" : "ic_reply")
+            action.backgroundColor = DcColors.chatBackgroundColor
         } else {
         } else {
             action.image = UIImage(named: "ic_reply_black")
             action.image = UIImage(named: "ic_reply_black")
+            action.backgroundColor = .systemBlue
         }
         }
         action.image?.accessibilityTraits = .button
         action.image?.accessibilityTraits = .button
         action.image?.accessibilityLabel = String.localized("menu_reply")
         action.image?.accessibilityLabel = String.localized("menu_reply")
-        action.backgroundColor = DcColors.chatBackgroundColor
         let configuration = UISwipeActionsConfiguration(actions: [action])
         let configuration = UISwipeActionsConfiguration(actions: [action])
 
 
         return configuration
         return configuration