kopia lustrzana https://github.com/TeamNewPipe/NewPipe
-Fixed new task intent for opening controls on players between sdk 21 and 24.
rodzic
9a5da5199d
commit
3d5c173d61
|
@ -132,8 +132,8 @@ public final class BackgroundPlayer extends Service {
|
||||||
//////////////////////////////////////////////////////////////////////////*/
|
//////////////////////////////////////////////////////////////////////////*/
|
||||||
|
|
||||||
public void openControl(final Context context) {
|
public void openControl(final Context context) {
|
||||||
final Intent intent = new Intent(context, BackgroundPlayerActivity.class);
|
Intent intent = new Intent(context, BackgroundPlayerActivity.class);
|
||||||
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.LOLLIPOP) {
|
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.N) {
|
||||||
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
|
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
|
||||||
}
|
}
|
||||||
context.startActivity(intent);
|
context.startActivity(intent);
|
||||||
|
|
|
@ -314,8 +314,8 @@ public final class PopupVideoPlayer extends Service {
|
||||||
}
|
}
|
||||||
|
|
||||||
public void openControl(final Context context) {
|
public void openControl(final Context context) {
|
||||||
final Intent intent = new Intent(context, PopupVideoPlayerActivity.class);
|
Intent intent = new Intent(context, PopupVideoPlayerActivity.class);
|
||||||
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.LOLLIPOP) {
|
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.N) {
|
||||||
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
|
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
|
||||||
}
|
}
|
||||||
context.startActivity(intent);
|
context.startActivity(intent);
|
||||||
|
|
Ładowanie…
Reference in New Issue