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

Issue 2003803002: Remove dependency of power_save_blocker_android on various content bits (Closed)

Created:
4 years, 7 months ago by scottmg
Modified:
4 years, 6 months ago
CC:
chromium-reviews, darin-cc_chromium.org, jam
Base URL:
https://chromium.googlesource.com/chromium/src.git@power-save-task-runners
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Remove dependency of power_save_blocker_android on various content bits BUG=612337, 612563 TEST=start/stop video on m.youtube.com, content_browsertests Committed: https://crrev.com/a25943038ebc706537cdd5e6229924c53217ed31 Cr-Commit-Position: refs/heads/master@{#399549}

Patch Set 1 #

Patch Set 2 : . #

Patch Set 3 : . #

Patch Set 4 : . #

Patch Set 5 : . #

Patch Set 6 : . #

Patch Set 7 : fix #

Patch Set 8 : . #

Total comments: 2

Patch Set 9 : weakptr #

Patch Set 10 : clear #

Total comments: 2

Patch Set 11 : no null check #

Total comments: 2

Patch Set 12 : back to weakptr #

Total comments: 6

Patch Set 13 : review fixes #

Total comments: 2

Patch Set 14 : only .reset() #

Unified diffs Side-by-side diffs Delta from patch set Stats (+88 lines, -60 lines) Patch
M content/browser/DEPS View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +1 line, -7 lines 0 comments Download
M content/browser/devtools/render_frame_devtools_agent_host.h View 1 2 3 4 5 6 7 8 9 10 11 3 chunks +6 lines, -0 lines 0 comments Download
M content/browser/devtools/render_frame_devtools_agent_host.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +12 lines, -1 line 0 comments Download
M content/browser/media/media_web_contents_observer.h View 1 2 3 4 5 6 7 8 10 11 2 chunks +7 lines, -0 lines 0 comments Download
M content/browser/media/media_web_contents_observer.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +9 lines, -2 lines 0 comments Download
M content/browser/power_save_blocker_android.cc View 1 2 3 4 5 6 7 8 9 10 11 12 6 chunks +20 lines, -40 lines 0 comments Download
M content/browser/power_save_blocker_impl.h View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +10 lines, -4 lines 0 comments Download
M content/browser/wake_lock/wake_lock_service_context.h View 1 2 3 4 5 6 7 8 10 11 3 chunks +8 lines, -0 lines 0 comments Download
M content/browser/wake_lock/wake_lock_service_context.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 3 chunks +13 lines, -2 lines 0 comments Download
M content/public/android/java/src/org/chromium/content/browser/PowerSaveBlocker.java View 2 chunks +2 lines, -4 lines 0 comments Download

Messages

Total messages: 62 (29 generated)
scottmg
4 years, 7 months ago (2016-05-24 23:48:32 UTC) #3
scottmg
Apparently this doesn't work. I'm not too sure what I'm doing here, but I guess ...
4 years, 6 months ago (2016-05-26 23:05:21 UTC) #4
scottmg
+nick for content/ Do you feel able to review this (including the .java)? (All of ...
4 years, 6 months ago (2016-05-26 23:37:59 UTC) #7
boliu
hmm, code no longer handles the case of PowerSaveBlockerImpl::Delegate outliving WebContents/ViewAndroid. previously this was done ...
4 years, 6 months ago (2016-05-31 17:23:44 UTC) #9
ncarter (slow)
I can give an owners stamp but you'll need a primary reviewer (bo?) who is ...
4 years, 6 months ago (2016-05-31 17:43:09 UTC) #10
scottmg
On 2016/05/31 17:23:44, boliu wrote: > hmm, code no longer handles the case of PowerSaveBlockerImpl::Delegate ...
4 years, 6 months ago (2016-05-31 20:02:38 UTC) #11
scottmg
On 2016/05/31 20:02:38, scottmg wrote: > On 2016/05/31 17:23:44, boliu wrote: > > hmm, code ...
4 years, 6 months ago (2016-05-31 20:48:10 UTC) #12
boliu
On 2016/05/31 20:48:10, scottmg wrote: > On 2016/05/31 20:02:38, scottmg wrote: > > On 2016/05/31 ...
4 years, 6 months ago (2016-05-31 20:56:29 UTC) #13
scottmg
On 2016/05/31 20:56:29, boliu wrote: > On 2016/05/31 20:48:10, scottmg wrote: > > On 2016/05/31 ...
4 years, 6 months ago (2016-06-01 21:13:10 UTC) #21
boliu
https://codereview.chromium.org/2003803002/diff/310001/content/browser/power_save_blocker_android.cc File content/browser/power_save_blocker_android.cc (right): https://codereview.chromium.org/2003803002/diff/310001/content/browser/power_save_blocker_android.cc#newcode59 content/browser/power_save_blocker_android.cc:59: if (view_android_ && !view_android_->GetViewAndroidDelegate().is_null()) { the is_null check isn't ...
4 years, 6 months ago (2016-06-01 21:37:07 UTC) #22
scottmg
https://codereview.chromium.org/2003803002/diff/310001/content/browser/power_save_blocker_android.cc File content/browser/power_save_blocker_android.cc (right): https://codereview.chromium.org/2003803002/diff/310001/content/browser/power_save_blocker_android.cc#newcode59 content/browser/power_save_blocker_android.cc:59: if (view_android_ && !view_android_->GetViewAndroidDelegate().is_null()) { On 2016/06/01 21:37:07, boliu ...
4 years, 6 months ago (2016-06-01 21:44:42 UTC) #23
boliu
non-owner lgtm
4 years, 6 months ago (2016-06-01 21:45:21 UTC) #24
ncarter (slow)
lgtm https://codereview.chromium.org/2003803002/diff/330001/content/browser/wake_lock/wake_lock_service_context.cc File content/browser/wake_lock/wake_lock_service_context.cc (right): https://codereview.chromium.org/2003803002/diff/330001/content/browser/wake_lock/wake_lock_service_context.cc#newcode44 content/browser/wake_lock/wake_lock_service_context.cc:44: ->ClearViewForSleepBlocker(); Now that there are 2 downcasts, consider ...
4 years, 6 months ago (2016-06-01 22:01:11 UTC) #25
ncarter (slow)
https://codereview.chromium.org/2003803002/diff/330001/content/browser/wake_lock/wake_lock_service_context.cc File content/browser/wake_lock/wake_lock_service_context.cc (right): https://codereview.chromium.org/2003803002/diff/330001/content/browser/wake_lock/wake_lock_service_context.cc#newcode44 content/browser/wake_lock/wake_lock_service_context.cc:44: ->ClearViewForSleepBlocker(); On 2016/06/01 22:01:11, ncarter wrote: > Now that ...
4 years, 6 months ago (2016-06-01 22:02:56 UTC) #26
ncarter (slow)
https://codereview.chromium.org/2003803002/diff/330001/content/browser/wake_lock/wake_lock_service_context.cc File content/browser/wake_lock/wake_lock_service_context.cc (right): https://codereview.chromium.org/2003803002/diff/330001/content/browser/wake_lock/wake_lock_service_context.cc#newcode44 content/browser/wake_lock/wake_lock_service_context.cc:44: ->ClearViewForSleepBlocker(); On 2016/06/01 22:01:11, ncarter wrote: > Now that ...
4 years, 6 months ago (2016-06-01 22:02:57 UTC) #27
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/2003803002/390001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/2003803002/390001
4 years, 6 months ago (2016-06-02 04:19:09 UTC) #30
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: linux_chromium_chromeos_rel_ng on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_chromeos_rel_ng/builds/222056)
4 years, 6 months ago (2016-06-02 04:38:20 UTC) #32
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/2003803002/390001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/2003803002/390001
4 years, 6 months ago (2016-06-02 15:33:00 UTC) #34
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: linux_android_rel_ng on tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/linux_android_rel_ng/builds/80791)
4 years, 6 months ago (2016-06-02 17:14:13 UTC) #36
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/2003803002/450001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/2003803002/450001
4 years, 6 months ago (2016-06-03 01:34:18 UTC) #40
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: linux_android_rel_ng on tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/linux_android_rel_ng/builds/81305)
4 years, 6 months ago (2016-06-03 02:53:58 UTC) #42
scottmg
Hi, finally got back to this and had to end up switching back to a ...
4 years, 6 months ago (2016-06-11 23:21:29 UTC) #47
boliu
lgtm let actual owner decide if my comments have merit :p https://codereview.chromium.org/2003803002/diff/490001/content/browser/devtools/render_frame_devtools_agent_host.cc File content/browser/devtools/render_frame_devtools_agent_host.cc (right): ...
4 years, 6 months ago (2016-06-13 14:56:43 UTC) #48
ncarter (slow)
lgtm https://codereview.chromium.org/2003803002/diff/490001/content/browser/devtools/render_frame_devtools_agent_host.cc File content/browser/devtools/render_frame_devtools_agent_host.cc (right): https://codereview.chromium.org/2003803002/diff/490001/content/browser/devtools/render_frame_devtools_agent_host.cc#newcode763 content/browser/devtools/render_frame_devtools_agent_host.cc:763: if (view_weak_factory_) On 2016/06/13 14:56:43, boliu wrote: > ...
4 years, 6 months ago (2016-06-13 16:56:20 UTC) #49
scottmg
Thanks! https://codereview.chromium.org/2003803002/diff/490001/content/browser/devtools/render_frame_devtools_agent_host.cc File content/browser/devtools/render_frame_devtools_agent_host.cc (right): https://codereview.chromium.org/2003803002/diff/490001/content/browser/devtools/render_frame_devtools_agent_host.cc#newcode763 content/browser/devtools/render_frame_devtools_agent_host.cc:763: if (view_weak_factory_) On 2016/06/13 14:56:43, boliu wrote: > ...
4 years, 6 months ago (2016-06-13 18:52:56 UTC) #50
boliu
https://codereview.chromium.org/2003803002/diff/510001/content/browser/devtools/render_frame_devtools_agent_host.cc File content/browser/devtools/render_frame_devtools_agent_host.cc (right): https://codereview.chromium.org/2003803002/diff/510001/content/browser/devtools/render_frame_devtools_agent_host.cc#newcode766 content/browser/devtools/render_frame_devtools_agent_host.cc:766: } err, just reset, no need for if or ...
4 years, 6 months ago (2016-06-13 18:54:45 UTC) #51
scottmg
https://codereview.chromium.org/2003803002/diff/510001/content/browser/devtools/render_frame_devtools_agent_host.cc File content/browser/devtools/render_frame_devtools_agent_host.cc (right): https://codereview.chromium.org/2003803002/diff/510001/content/browser/devtools/render_frame_devtools_agent_host.cc#newcode766 content/browser/devtools/render_frame_devtools_agent_host.cc:766: } On 2016/06/13 18:54:45, boliu wrote: > err, just ...
4 years, 6 months ago (2016-06-13 19:10:10 UTC) #52
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/2003803002/530001
4 years, 6 months ago (2016-06-13 19:10:56 UTC) #55
commit-bot: I haz the power
Committed patchset #14 (id:530001)
4 years, 6 months ago (2016-06-13 21:37:30 UTC) #57
commit-bot: I haz the power
CQ bit was unchecked
4 years, 6 months ago (2016-06-13 21:37:44 UTC) #58
commit-bot: I haz the power
Patchset 14 (id:??) landed as https://crrev.com/a25943038ebc706537cdd5e6229924c53217ed31 Cr-Commit-Position: refs/heads/master@{#399549}
4 years, 6 months ago (2016-06-13 21:39:03 UTC) #60
scottmg
On 2016/06/01 22:02:57, ncarter wrote: > https://codereview.chromium.org/2003803002/diff/330001/content/browser/wake_lock/wake_lock_service_context.cc > File content/browser/wake_lock/wake_lock_service_context.cc (right): > > https://codereview.chromium.org/2003803002/diff/330001/content/browser/wake_lock/wake_lock_service_context.cc#newcode44 > ...
4 years, 6 months ago (2016-06-20 22:07:45 UTC) #61
ncarter (slow)
4 years, 6 months ago (2016-06-20 22:18:12 UTC) #62
Message was sent while issue was closed.
Hooray.

On Mon, Jun 20, 2016 at 3:07 PM, <scottmg@chromium.org> wrote:

> On 2016/06/01 22:02:57, ncarter wrote:
> >
>
>
https://codereview.chromium.org/2003803002/diff/330001/content/browser/wake_l...
> > File content/browser/wake_lock/wake_lock_service_context.cc (right):
> >
> >
>
>
https://codereview.chromium.org/2003803002/diff/330001/content/browser/wake_l...
> > content/browser/wake_lock/wake_lock_service_context.cc:44:
> > ->ClearViewForSleepBlocker();
> > On 2016/06/01 22:01:11, ncarter wrote:
> > > Now that there are 2 downcasts, consider making wake_lock_ the Impl
> type, so
> > > that you only have to do the static_cast at CreatePowerSaveBlocker time
> (where
> > > it's also easier to verify that the cast is safe).
> >
> > Or don't -- downcasting while assigning a unique_ptr can be a PITA, and
> it's
> > probably worse than 2 static_casts.
>
> [ Thread necromancy, but just FYI: after moving this all to //device, the
> split
> of PowerSaveBlocker and PowerSaveBlockerImpl is no longer necessary, so the
> downcast is gone. \o/ ]
>
> https://codereview.chromium.org/2003803002/
>

-- 
You received this message because you are subscribed to the Google Groups
"Chromium-reviews" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to chromium-reviews+unsubscribe@chromium.org.

Powered by Google App Engine
This is Rietveld 408576698