@Override public boolean onMenuItemSelected(int featureId, MenuItem item) { boolean b = super.onMenuItemSelected(featureId, item); if (mImageMenuRunnable != null) { mImageMenuRunnable.aboutToCall(item, mAllImages.getImageAt(mCurrentPosition)); } return b; }
@Override public boolean onPrepareOptionsMenu(Menu menu) { super.onPrepareOptionsMenu(menu); if (mPaused) return false; IImage image = mAllImages.getImageAt(mCurrentPosition); if (mImageMenuRunnable != null) { mImageMenuRunnable.gettingReadyToOpen(menu, image); } Uri uri = mAllImages.getImageAt(mCurrentPosition).fullSizeImageUri(); MenuHelper.enableShareMenuItem(menu, MenuHelper.isWhiteListUri(uri)); MenuHelper.enableShowOnMapMenuItem(menu, MenuHelper.hasLatLngData(image)); return true; }