fix #200, close search at changing tab

This commit is contained in:
tibbi 2018-07-16 23:48:42 +02:00
parent 4083bdcbb1
commit c081fd18bf
1 changed files with 4 additions and 0 deletions

View File

@ -296,6 +296,10 @@ class MainActivity : SimpleActivity(), RefreshContactsListener {
it.icon?.applyColorFilter(config.textColor)
},
tabSelectedAction = {
if (isSearchOpen) {
getCurrentFragment()?.onSearchQueryChanged("")
searchMenuItem?.collapseActionView()
}
viewpager.currentItem = it.position
it.icon?.applyColorFilter(getAdjustedPrimaryColor())
}