diff --git a/app/src/main/kotlin/com/simplemobiletools/filemanager/pro/activities/MainActivity.kt b/app/src/main/kotlin/com/simplemobiletools/filemanager/pro/activities/MainActivity.kt index 12ffd470..c9707920 100644 --- a/app/src/main/kotlin/com/simplemobiletools/filemanager/pro/activities/MainActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/filemanager/pro/activities/MainActivity.kt @@ -642,7 +642,9 @@ class MainActivity : SimpleActivity() { return } - if (getCurrentFragment()!!.breadcrumbs.getItemCount() <= 1) { + if (isSearchOpen && mSearchMenuItem != null) { + mSearchMenuItem!!.collapseActionView() + } else if (getCurrentFragment()!!.breadcrumbs.getItemCount() <= 1) { if (!wasBackJustPressed && config.pressBackTwice) { wasBackJustPressed = true toast(R.string.press_back_again)