Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(979)

Issue 81693003: Release media player resources when device is locked (Closed)

Created:
7 years, 1 month ago by kbalazs
Modified:
7 years ago
Reviewers:
qinmin, wolenetz
CC:
chromium-reviews, joi+watch-content_chromium.org, feature-media-reviews_chromium.org, jam, darin-cc_chromium.org, bulach
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Visibility:
Public.

Description

Release media player resources when device is locked Stop holding on resources when the device gets locked while fullscreen media player is active. This is the same as what we do for non-fullscreen and the MediaPlayerAndroid implementations alreay has logic to be able to restart after Release is called. The special case for fullscreen has been introduced as a workaround because restarting did not work in fullscreen. This cl removes the special case and fix the original issue: which is that we drop the reference to the surface we got from the fullscreen player so when we restart we could not set up the new MediaPlayer to draw onto it. BUG=322181 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=237243

Patch Set 1 #

Total comments: 2

Patch Set 2 : reuploading to get diffs in retvield #

Patch Set 3 : fixed a mistake I just realized #

Total comments: 1

Patch Set 4 : using openVideo instead of holding reference to surface #

Patch Set 5 : with comment #

Total comments: 2

Patch Set 6 : fix nits #

Patch Set 7 : 1 more typo #

Unified diffs Side-by-side diffs Delta from patch set Stats (+14 lines, -4 lines) Patch
M content/browser/media/android/browser_media_player_manager.h View 1 2 3 1 chunk +3 lines, -0 lines 0 comments Download
M content/browser/media/android/browser_media_player_manager.cc View 1 2 3 4 5 6 4 chunks +11 lines, -4 lines 0 comments Download

Messages

Total messages: 27 (0 generated)
kbalazs
7 years, 1 month ago (2013-11-21 22:44:26 UTC) #1
wolenetz
Rietveld isn't showing diffs, and raw diffs hurt my eyes. Would you please try re-uploading ...
7 years, 1 month ago (2013-11-21 23:09:49 UTC) #2
kbalazs
On 2013/11/21 23:09:49, wolenetz wrote: > Rietveld isn't showing diffs, and raw diffs hurt my ...
7 years, 1 month ago (2013-11-21 23:15:49 UTC) #3
wolenetz
On 2013/11/21 23:15:49, kbalazs wrote: > On 2013/11/21 23:09:49, wolenetz wrote: > > Rietveld isn't ...
7 years, 1 month ago (2013-11-21 23:41:25 UTC) #4
qinmin
https://codereview.chromium.org/81693003/diff/1/media/base/android/media_player_bridge.cc File media/base/android/media_player_bridge.cc (right): https://codereview.chromium.org/81693003/diff/1/media/base/android/media_player_bridge.cc#newcode114 media/base/android/media_player_bridge.cc:114: this is not correct. SetVideoSurface() may get called before ...
7 years, 1 month ago (2013-11-22 01:55:01 UTC) #5
kbalazs
On 2013/11/22 01:55:01, qinmin wrote: > https://codereview.chromium.org/81693003/diff/1/media/base/android/media_player_bridge.cc > File media/base/android/media_player_bridge.cc (right): > > https://codereview.chromium.org/81693003/diff/1/media/base/android/media_player_bridge.cc#newcode114 > ...
7 years, 1 month ago (2013-11-22 16:31:49 UTC) #6
kbalazs
Checked again, we do not get a surface again when returning from lock in fullscreen. ...
7 years, 1 month ago (2013-11-22 17:21:35 UTC) #7
qinmin
On 2013/11/22 17:21:35, kbalazs wrote: > Checked again, we do not get a surface again ...
7 years, 1 month ago (2013-11-22 18:04:56 UTC) #8
qinmin
https://codereview.chromium.org/81693003/diff/230001/media/base/android/media_player_bridge.cc File media/base/android/media_player_bridge.cc (right): https://codereview.chromium.org/81693003/diff/230001/media/base/android/media_player_bridge.cc#newcode78 media/base/android/media_player_bridge.cc:78: JNIEnv* env = base::android::AttachCurrentThread(); env is already defined inside ...
7 years, 1 month ago (2013-11-22 18:06:55 UTC) #9
wolenetz
Are unit tests that exercise fullscreen release/start() possible for at least media_source_player_unittests, if not also ...
7 years, 1 month ago (2013-11-22 18:41:12 UTC) #10
kbalazs
On 2013/11/22 18:04:56, qinmin wrote: > On 2013/11/22 17:21:35, kbalazs wrote: > > Checked again, ...
7 years, 1 month ago (2013-11-22 18:50:15 UTC) #11
qinmin
On 2013/11/22 18:50:15, kbalazs wrote: > On 2013/11/22 18:04:56, qinmin wrote: > > On 2013/11/22 ...
7 years, 1 month ago (2013-11-22 19:00:54 UTC) #12
kbalazs
On 2013/11/22 19:00:54, qinmin wrote: > On 2013/11/22 18:50:15, kbalazs wrote: > > On 2013/11/22 ...
7 years, 1 month ago (2013-11-22 20:58:57 UTC) #13
qinmin
On 2013/11/22 20:58:57, kbalazs wrote: > On 2013/11/22 19:00:54, qinmin wrote: > > On 2013/11/22 ...
7 years, 1 month ago (2013-11-22 21:28:19 UTC) #14
kbalazs
openVideo works well but I find another small problem (not because of this, because of ...
7 years, 1 month ago (2013-11-22 23:49:54 UTC) #15
qinmin
On 2013/11/22 23:49:54, kbalazs wrote: > openVideo works well but I find another small problem ...
7 years, 1 month ago (2013-11-23 00:11:18 UTC) #16
kbalazs
On 2013/11/23 00:11:18, qinmin wrote: > On 2013/11/22 23:49:54, kbalazs wrote: > > openVideo works ...
7 years, 1 month ago (2013-11-23 00:53:15 UTC) #17
qinmin
On 2013/11/23 00:53:15, kbalazs wrote: > On 2013/11/23 00:11:18, qinmin wrote: > > On 2013/11/22 ...
7 years, 1 month ago (2013-11-23 00:59:56 UTC) #18
wolenetz
On 2013/11/23 00:53:15, kbalazs wrote: > On 2013/11/23 00:11:18, qinmin wrote: > > On 2013/11/22 ...
7 years, 1 month ago (2013-11-23 01:00:04 UTC) #19
kbalazs
> > ok, please file a crbug and put a TODO in the code to ...
7 years, 1 month ago (2013-11-23 01:10:15 UTC) #20
kbalazs
Added comment referring to crbug.com/322798. Could you review? :)
7 years ago (2013-11-25 19:39:20 UTC) #21
wolenetz
(rubber-stamp) lgtm % nits and % qinmin@'s review of the actual updated release behavior. https://codereview.chromium.org/81693003/diff/530001/content/browser/media/android/browser_media_player_manager.cc ...
7 years ago (2013-11-25 20:59:37 UTC) #22
qinmin
lgtm
7 years ago (2013-11-25 22:23:51 UTC) #23
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/b.kelemen@samsung.com/81693003/570001
7 years ago (2013-11-25 22:28:28 UTC) #24
commit-bot: I haz the power
Change committed as 237243
7 years ago (2013-11-26 03:34:52 UTC) #25
wolenetz
On 2013/11/26 03:34:52, I haz the power (commit-bot) wrote: > Change committed as 237243 kbalazs: ...
7 years ago (2013-12-12 18:20:33 UTC) #26
kbalazs
7 years ago (2013-12-12 21:23:38 UTC) #27
Message was sent while issue was closed.
On 2013/12/12 18:20:33, wolenetz wrote:
> On 2013/11/26 03:34:52, I haz the power (commit-bot) wrote:
> > Change committed as 237243
> 
> kbalazs: Reviewing irc logs, I just now saw your query of me on irc from long
> ago about this CL. Sorry it took me this long to see your query. In general,
> rubber-stamp implies "don't block on my l*tm, but needs l*tm from someone else
> reviewing in more detail". So, pending qinmin@'s l*tm was the right way to
> proceed :)

I see, thanks for explaining this :)

Powered by Google App Engine
This is Rietveld 408576698