Merge pull request #1429 from mfietz/issue/episodes-share

*EpisodesFragment: Fix context menu sharing
This commit is contained in:
Tom Hennen 2015-11-28 11:36:04 -05:00
commit 87daa77ce4
2 changed files with 5 additions and 0 deletions

View File

@ -261,9 +261,13 @@ public class AllEpisodesFragment extends Fragment {
@Override
public boolean onContextItemSelected(MenuItem item) {
Log.d(TAG, "onContextItemSelected() called with: " + "item = [" + item + "]");
if(!isVisible()) {
return false;
}
if(item.getItemId() == R.id.share_item) {
return true; // avoids that the position is reset when we need it in the submenu
}
int pos = listAdapter.getPosition();
if(pos < 0) {
return false;

View File

@ -320,6 +320,7 @@ public class QueueFragment extends Fragment {
@Override
public boolean onContextItemSelected(MenuItem item) {
Log.d(TAG, "onContextItemSelected() called with: " + "item = [" + item + "]");
if(!isVisible()) {
return false;
}