Brackets and position fixed

This commit is contained in:
Guillaume 2017-11-03 22:05:56 +01:00 committed by GitHub
parent 1aa9ebe286
commit b4e43d1c21
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -236,14 +236,15 @@ class ViewPagerActivity : SimpleActivity(), ViewPager.OnPageChangeListener, View
findItem(R.id.menu_share_1).isVisible = !config.replaceShare
findItem(R.id.menu_share_2).isVisible = config.replaceShare
findItem(R.id.menu_rotate).isVisible = currentMedium.isImage()
findItem(R.id.menu_rotate).setShowAsAction(
if (mRotationDegrees !== 0f)
MenuItem.SHOW_AS_ACTION_ALWAYS
else
MenuItem.SHOW_AS_ACTION_IF_ROOM)
findItem(R.id.menu_save_as).isVisible = mRotationDegrees != 0f
findItem(R.id.menu_hide).isVisible = !currentMedium.name.startsWith('.')
findItem(R.id.menu_unhide).isVisible = currentMedium.name.startsWith('.')
findItem(R.id.menu_rotate).setShowAsAction(
if (mRotationDegrees !== 0f) {
MenuItem.SHOW_AS_ACTION_ALWAYS
} else {
MenuItem.SHOW_AS_ACTION_IF_ROOM
})
}
return true