我试图隐藏 inputToolbar 但不工作。
`导入 UIKit 导入 JSQMessagesViewController 导入 ProgressHUD 导入 IQAudioRecorderController 导入 IDMPhotoBrowser 导入 AVFoundation 导入 AVKit 导入 FirebaseFirestore
类 ChatViewController: JSQMessagesViewController {
var outgoingBubble = JSQMessagesBubbleImageFactory()?.outgoingMessagesBubbleImage(with: UIColor.jsq_messageBubbleBlue())
var incomingBubble = JSQMessagesBubbleImageFactory()?.incomingMessagesBubbleImage(with: UIColor.jsq_messageBubbleLightGray())
override func viewDidLayoutSubviews() {
perform(Selector(("jsq_updateCollectionViewInsets")))
}
override func viewDidLoad() {
super.viewDidLoad()
self.senderId=FUser.currentId()
self.senderDisplayName=FUser.currentUser()!.firstname
let constrain = perform(Selector(("toolbarBottomLayoutGuide")))?.takeUnretainedValue() as! NSLayoutConstraint
constrain.priority=UILayoutPriority(rawValue: 1000)
self.inputToolbar.bottomAnchor.constraint(equalTo: self.view.safeAreaLayoutGuide.bottomAnchor).isActive=true
}
} `