Removed unused showStreamDialog from VideoDetailFragment
VideoDetailFragment already borrows a consistant menu from the stream list it holds.
This commit is contained in:
parent
8b584f3922
commit
30eeef46c2
1 changed files with 0 additions and 36 deletions
|
@ -522,42 +522,6 @@ public class VideoDetailFragment
|
||||||
detailControlsPopup.setOnTouchListener(getOnControlsTouchListener());
|
detailControlsPopup.setOnTouchListener(getOnControlsTouchListener());
|
||||||
}
|
}
|
||||||
|
|
||||||
private void showStreamDialog(final StreamInfoItem item) {
|
|
||||||
final Context context = getContext();
|
|
||||||
if (context == null || context.getResources() == null || getActivity() == null) return;
|
|
||||||
|
|
||||||
final String[] commands = new String[]{
|
|
||||||
context.getResources().getString(R.string.enqueue_on_background),
|
|
||||||
context.getResources().getString(R.string.enqueue_on_popup),
|
|
||||||
context.getResources().getString(R.string.append_playlist),
|
|
||||||
context.getResources().getString(R.string.share)
|
|
||||||
};
|
|
||||||
|
|
||||||
final DialogInterface.OnClickListener actions = (DialogInterface dialogInterface, int i) -> {
|
|
||||||
switch (i) {
|
|
||||||
case 0:
|
|
||||||
NavigationHelper.enqueueOnBackgroundPlayer(context, new SinglePlayQueue(item));
|
|
||||||
break;
|
|
||||||
case 1:
|
|
||||||
NavigationHelper.enqueueOnPopupPlayer(getActivity(), new SinglePlayQueue(item));
|
|
||||||
break;
|
|
||||||
case 2:
|
|
||||||
if (getFragmentManager() != null) {
|
|
||||||
PlaylistAppendDialog.fromStreamInfoItems(Collections.singletonList(item))
|
|
||||||
.show(getFragmentManager(), TAG);
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
case 3:
|
|
||||||
ShareUtils.shareUrl(this.getContext(), item.getName(), item.getUrl());
|
|
||||||
break;
|
|
||||||
default:
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
new InfoItemDialog(getActivity(), item, commands, actions).show();
|
|
||||||
}
|
|
||||||
|
|
||||||
private View.OnTouchListener getOnControlsTouchListener() {
|
private View.OnTouchListener getOnControlsTouchListener() {
|
||||||
return (View view, MotionEvent motionEvent) -> {
|
return (View view, MotionEvent motionEvent) -> {
|
||||||
if (!PreferenceManager.getDefaultSharedPreferences(activity)
|
if (!PreferenceManager.getDefaultSharedPreferences(activity)
|
||||||
|
|
Loading…
Reference in a new issue