Skip to content

Commit ce60f3c

Browse files
committed
Merge branch 'hotfix/1.6.2'
2 parents 9278580 + 6b09ee6 commit ce60f3c

2 files changed

Lines changed: 12 additions & 2 deletions

File tree

tubeLoadNative/tubeLoadNative.Droid/Activities/CurrentSong.cs

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,11 +88,21 @@ protected override void OnResume()
8888
{
8989
base.OnResume();
9090

91+
if (bannerFrame != null)
92+
bannerFrame.Resume();
93+
9194
checkCurrentSong();
9295

9396
ChangePlayingView();
9497
}
9598

99+
protected override void OnPause()
100+
{
101+
if (bannerFrame != null)
102+
bannerFrame.Pause();
103+
base.OnPause();
104+
}
105+
96106
void ChangePlayingView()
97107
{
98108
if (mediaPlayer.IsPlaying)

tubeLoadNative/tubeLoadNative.Droid/Utils/NotificationHandler.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ static NotificationHandler()
2929

3030
builder.SetOngoing(true);
3131

32-
if (Android.OS.Build.VERSION.SdkInt <= Android.OS.Build.VERSION_CODES.Lollipop)
32+
if (Android.OS.Build.VERSION.SdkInt < Android.OS.Build.VERSION_CODES.M)
3333
{
3434
CreateNotificationMediaActions();
3535
}
@@ -62,7 +62,7 @@ public static void BuildNotification(String songId)
6262
bitmap = BitmapFactory.DecodeResource(Application.Context.Resources, Resource.Drawable.default_song_image);
6363
}
6464

65-
if (Android.OS.Build.VERSION.SdkInt > Android.OS.Build.VERSION_CODES.Lollipop)
65+
if (Android.OS.Build.VERSION.SdkInt >= Android.OS.Build.VERSION_CODES.M)
6666
{
6767
RemoteViews notificationLayoutExpanded = new RemoteViews(Application.Context.PackageName, Resource.Layout.view_notification_actions);
6868
notificationLayoutExpanded.SetTextViewText(Resource.Id.notificationTitle, title);

0 commit comments

Comments
 (0)