Replace deprecated MenuItemCompat.collapseActionView

This commit is contained in:
Nikola Trubitsyn 2018-01-30 14:13:12 +03:00
parent 04823c8fa4
commit e57bb9531b

View file

@ -222,9 +222,7 @@ class MainActivity : SimpleActivity(), RefreshContactsListener {
override fun onPageScrollStateChanged(state: Int) {
if (isSearchOpen) {
getCurrentFragment().onSearchQueryChanged("")
if (searchMenuItem != null) {
MenuItemCompat.collapseActionView(searchMenuItem)
}
searchMenuItem?.collapseActionView()
}
}