Don't restore keyboard after CVC message context menu if the menu item presented a VC.
This commit is contained in:
parent
c474d3f07c
commit
2bf974bc58
@ -323,10 +323,17 @@ extension ConversationViewController: ContextMenuInteractionDelegate {
|
||||
if let contextInteraction = interaction as? ChatHistoryContextMenuInteraction, let cell = contextInteraction.view as? CVCell, let componentView = cell.componentView {
|
||||
componentView.contextMenuPresentationDidEnd?()
|
||||
|
||||
// Restore the keyboard unless the context menu item presented
|
||||
// a view controller.
|
||||
if contextInteraction.keyboardWasActive {
|
||||
popKeyBoard()
|
||||
if self.presentedViewController == nil {
|
||||
popKeyBoard()
|
||||
} else {
|
||||
// If we're not going to restore the keyboard, update
|
||||
// chat history layout.
|
||||
self.loadCoordinator.enqueueReload()
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
collectionViewActiveContextMenuInteraction = nil
|
||||
|
||||
@ -81,6 +81,8 @@ extension ConversationViewController: MessageActionsDelegate {
|
||||
}
|
||||
|
||||
func messageActionsForwardItem(_ itemViewModel: CVItemViewModelImpl) {
|
||||
AssertIsOnMainThread()
|
||||
|
||||
ForwardMessageViewController.present(forItemViewModels: [itemViewModel],
|
||||
from: self,
|
||||
delegate: self)
|
||||
|
||||
@ -362,6 +362,8 @@ extension ConversationViewController {
|
||||
}
|
||||
|
||||
func didTapForwardSelectedItems() {
|
||||
AssertIsOnMainThread()
|
||||
|
||||
let selectionItems = self.selectionState.selectionItems
|
||||
guard !selectionItems.isEmpty else {
|
||||
owsFailDebug("Invalid selection.")
|
||||
|
||||
Loading…
Reference in New Issue
Block a user