Commit ec0ad541 authored by Kateryna Kostiuk's avatar Kateryna Kostiuk Committed by Andreas Traczyk

UI: fix bugs

This patch fixes next bugs:
- "No result" label still shown when contact or conversation found.
- keyboard hide after sending message (occurs after making call)
- navigation bar appearance for ios 9 and 10

Change-Id: Id4ac9ca9c4d9016d10f1abb65d4b19b4a8f3bdec
Reviewed-by: Andreas Traczyk's avatarAndreas Traczyk <andreas.traczyk@savoirfairelinux.com>
parent fa8127dd
......@@ -297,6 +297,7 @@ class ConversationViewController: UIViewController, UITextFieldDelegate, Storybo
super.viewDidAppear(animated)
self.scrollToBottom(animated: false)
self.textFieldShouldEndEditing = false
self.messagesLoadingFinished()
}
......
......@@ -72,6 +72,11 @@ class SmartlistViewController: UIViewController, StoryboardBased, ViewModelBased
NotificationCenter.default.addObserver(self, selector: #selector(keyboardWillHide(withNotification:)), name: NSNotification.Name.UIKeyboardWillHide, object: nil)
}
override func viewWillAppear(_ animated: Bool) {
super.viewWillAppear(animated)
self.navigationController?.navigationBar.setBackgroundImage(UIImage(), for: UIBarMetrics.default)
}
func setupUI() {
self.navigationItem.title = L10n.Global.homeTabBarTitle
......
......@@ -176,7 +176,8 @@ class SmartlistViewModel: Stateable, ViewModel {
}
self.searchStatus.onNext("")
} else {
if self.filteredResults.value.isEmpty {
if self.filteredResults.value.isEmpty
&& self.contactFoundConversation.value == nil {
self.searchStatus.onNext(L10n.Smartlist.noResults)
} else {
self.searchStatus.onNext("")
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment