setup context for making notifications open via setContextIntent()
This commit is contained in:
parent
50c5314eaf
commit
11e8e38f2c
4 changed files with 20 additions and 13 deletions
|
|
@ -180,7 +180,8 @@ public final class BackgroundPlayer extends Service {
|
|||
.setSmallIcon(R.drawable.ic_newpipe_triangle_white)
|
||||
.setVisibility(NotificationCompat.VISIBILITY_PUBLIC)
|
||||
.setCustomContentView(notRemoteView)
|
||||
.setCustomBigContentView(bigNotRemoteView);
|
||||
.setCustomBigContentView(bigNotRemoteView)
|
||||
.setContentIntent(NavigationHelper.getServicePlayerControlPendingIntent(this, BackgroundPlayerActivity.class));
|
||||
if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.JELLY_BEAN) builder.setPriority(NotificationCompat.PRIORITY_MAX);
|
||||
return builder;
|
||||
}
|
||||
|
|
@ -453,7 +454,6 @@ public final class BackgroundPlayer extends Service {
|
|||
super.setupBroadcastReceiver(intentFilter);
|
||||
intentFilter.addAction(ACTION_CLOSE);
|
||||
intentFilter.addAction(ACTION_PLAY_PAUSE);
|
||||
intentFilter.addAction(ACTION_OPEN_CONTROLS);
|
||||
intentFilter.addAction(ACTION_REPEAT);
|
||||
intentFilter.addAction(ACTION_PLAY_PREVIOUS);
|
||||
intentFilter.addAction(ACTION_PLAY_NEXT);
|
||||
|
|
@ -478,9 +478,6 @@ public final class BackgroundPlayer extends Service {
|
|||
case ACTION_PLAY_PAUSE:
|
||||
onVideoPlayPause();
|
||||
break;
|
||||
case ACTION_OPEN_CONTROLS:
|
||||
NavigationHelper.openBackgroundPlayerControl(getApplicationContext());
|
||||
break;
|
||||
case ACTION_REPEAT:
|
||||
onRepeatClicked();
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue