diff --git a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MainActivity.kt b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MainActivity.kt index 73fcde9a0..3c8f40b80 100644 --- a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MainActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MainActivity.kt @@ -78,6 +78,7 @@ class MainActivity : SimpleActivity(), DirectoryAdapter.DirOperationsListener { menu.findItem(R.id.increase_column_count).isVisible = config.dirColumnCnt < 10 menu.findItem(R.id.reduce_column_count).isVisible = config.dirColumnCnt > 1 } + menu.findItem(R.id.temporarily_show_hidden).isVisible = !config.showHiddenMedia return true } @@ -106,6 +107,7 @@ class MainActivity : SimpleActivity(), DirectoryAdapter.DirOperationsListener { mDirs.clear() } tryloadGallery() + invalidateOptionsMenu() } override fun onPause() { diff --git a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MediaActivity.kt b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MediaActivity.kt index 57ab19dd6..06e1fb9c4 100644 --- a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MediaActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MediaActivity.kt @@ -76,6 +76,7 @@ class MediaActivity : SimpleActivity(), MediaAdapter.MediaOperationsListener { mMedia.clear() } tryloadGallery() + invalidateOptionsMenu() } override fun onPause() { @@ -133,6 +134,8 @@ class MediaActivity : SimpleActivity(), MediaAdapter.MediaOperationsListener { findItem(R.id.open_camera).isVisible = mShowAll findItem(R.id.about).isVisible = mShowAll + findItem(R.id.temporarily_show_hidden).isVisible = !config.showHiddenMedia + findItem(R.id.increase_column_count).isVisible = config.mediaColumnCnt < 10 findItem(R.id.reduce_column_count).isVisible = config.mediaColumnCnt > 1 }