From 5c12491fc157acd697c355734bef4a17fb7afe5b Mon Sep 17 00:00:00 2001 From: tibbi Date: Sun, 4 Dec 2016 12:58:47 +0100 Subject: [PATCH] add Set as wallpaper to photovideoactivity --- .../gallery/activities/PhotoVideoActivity.kt | 1 + app/src/main/res/menu/photo_video_menu.xml | 7 +++---- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/PhotoVideoActivity.kt b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/PhotoVideoActivity.kt index 8cdb06175..ef2b431c1 100644 --- a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/PhotoVideoActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/PhotoVideoActivity.kt @@ -72,6 +72,7 @@ open class PhotoVideoActivity : SimpleActivity(), ViewPagerFragment.FragmentClic override fun onCreateOptionsMenu(menu: Menu): Boolean { menuInflater.inflate(R.menu.photo_video_menu, menu) + menu.findItem(R.id.menu_set_as_wallpaper).isVisible = mMedium.isImage() return true } diff --git a/app/src/main/res/menu/photo_video_menu.xml b/app/src/main/res/menu/photo_video_menu.xml index 9537315f3..419993caf 100644 --- a/app/src/main/res/menu/photo_video_menu.xml +++ b/app/src/main/res/menu/photo_video_menu.xml @@ -7,10 +7,9 @@ android:title="@string/share" app:showAsAction="ifRoom"/> + android:id="@+id/menu_set_as_wallpaper" + android:title="@string/set_as_wallpaper" + app:showAsAction="never"/>