Chromium Code Reviews| Index: chrome/android/java/src/org/chromium/chrome/browser/media/ui/MediaNotificationManager.java |
| diff --git a/chrome/android/java/src/org/chromium/chrome/browser/media/ui/MediaNotificationManager.java b/chrome/android/java/src/org/chromium/chrome/browser/media/ui/MediaNotificationManager.java |
| index 01c791d7718515f67e5a2fa88122a78ac04111a4..c4013918973d7712d5a76a7963ed9a56d8252f46 100644 |
| --- a/chrome/android/java/src/org/chromium/chrome/browser/media/ui/MediaNotificationManager.java |
| +++ b/chrome/android/java/src/org/chromium/chrome/browser/media/ui/MediaNotificationManager.java |
| @@ -661,10 +661,14 @@ public class MediaNotificationManager { |
| return; |
| } |
| - if (mService == null && mediaNotificationInfo.isPaused) return; |
| - |
| mMediaNotificationInfo = mediaNotificationInfo; |
| + // If there's no pending service start request, don't try to start service. If there is a |
| + // pending service start request but the service haven't started yet, only update the |
| + // |mMediaNotificationInfo|. The service will update the notification later once it's |
| + // started. |
| + if (mService == null && mediaNotificationInfo.isPaused) return; |
|
whywhat
2017/03/23 16:27:39
But we just added this line this month!
Hopefully
Zhiqiang Zhang (Slow)
2017/03/23 17:07:52
That's why we need more tests :)
|
| + |
| if (mService == null) { |
| updateMediaSession(); |
| updateNotificationBuilder(); |