New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 678225 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Android MediaRouter only (left Chro...
Closed: Jan 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 1
Type: Feature



Sign in to add a comment

media session notification should persist

Project Member Reported by fbeaufort@chromium.org, Jan 4 2017

Issue description

It would be nice(r) if the media session notification would persist when switching between audio apps. That way, I could resume media session from the notifications without having to go back to the website window and find the "play" button.

See what is currently happening in video below.
 
non-persisting-notifications.mp4
3.0 MB View Download
Labels: -Type-Bug Type-Feature
Status: Available (was: Unconfirmed)
At the moment, we made a decision to never show more than one media notification to avoid pouting the user with zombie notifications. It's based on the assumption that Chrome will mostly compete with other applications for audio focus, not with other websites. This might change in the future :)
Sorry for the misunderstanding, I wasn't clear.

Here's the scenario:

- Android Application plays audio
- Media Notification A shows up

- Web Application start playing audio
- Media Notification B shows up
- Media Notification A persists however

- Android Application plays audio
- Media Notification B disappears ;(

I'd like Media Notification B to stay there as long as Web Application Audio is "paused".

Hopefully it makes more sense.

Could this be solved together with #678221, i.e. keeping MediaSession more active based on mediaSession.playbackState?
Labels: -Pri-3 M-57 Pri-1
Owner: zqzh...@chromium.org
I think it's a bit different from  bug 678221 . My comment above is actually wrong. Based on comment #2, it seems that the behaviour fbeaufort@ wants is that we do not hide the notification when the Audio Focus Manager pauses Chrome. Instead, we should stop playing but keep the notification around like other media applications.
Status: Started (was: Available)
https://codereview.chromium.org/2613143003/
Project Member

Comment 6 by bugdroid1@chromium.org, Jan 10 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/0c63aa9cb9891cc2d5376e5cec4c4b808ebdb3da

commit 0c63aa9cb9891cc2d5376e5cec4c4b808ebdb3da
Author: zqzhang <zqzhang@chromium.org>
Date: Tue Jan 10 14:57:38 2017

[MediaSession] Keep MediaSession controllable when losing audio focus

This is for keeping the media notification more persistent when the
audio focus is lost. The rationale is to reduce the effort to resume
audio. Otherwise, the user go back to Chrome and find the tab and click
play.

BUG= 678225 

Review-Url: https://codereview.chromium.org/2613143003
Cr-Commit-Position: refs/heads/master@{#442587}

[modify] https://crrev.com/0c63aa9cb9891cc2d5376e5cec4c4b808ebdb3da/content/browser/media/session/audio_focus_delegate_android.cc
[modify] https://crrev.com/0c63aa9cb9891cc2d5376e5cec4c4b808ebdb3da/content/browser/media/session/audio_focus_delegate_android.h
[modify] https://crrev.com/0c63aa9cb9891cc2d5376e5cec4c4b808ebdb3da/content/public/android/java/src/org/chromium/content/browser/AudioFocusDelegate.java
[modify] https://crrev.com/0c63aa9cb9891cc2d5376e5cec4c4b808ebdb3da/content/public/android/javatests/src/org/chromium/content/browser/MediaSessionTest.java

I've just verified in latest Chromium build (57.0.2979.0) and it works great. Thank you zqzhang@! 
And for the record, here's attached a screen record of the user experience.
media-session.mp4
9.5 MB View Download
Status: Fixed (was: Started)

Sign in to add a comment