Chromium Code Reviews
[email protected] (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(22)

Issue 10913134: Add is_fullscreen to video updates (Closed)

Created:
8 years, 3 months ago by rharrison
Modified:
8 years, 3 months ago
Reviewers:
flackr, sadrul, Daniel Erat
CC:
chromium-reviews, sadrul, nkostylev+watch_chromium.org, ben+watch_chromium.org, oshima+watch_chromium.org, stevenjb+watch_chromium.org, davemoore+watch_chromium.org
Visibility:
Public.

Description

Add is_fullscreen to video updates This is a re-attempt at http://codereview.chromium.org/10916123/, which also ended up being reverted. This was reverted due to a failing unit test on Win_Aura. Through an unfortunate set of mistakes this builder was not in the default try set or the CQ set, but could close the tree leading to the revert. Through testing I have been able to reproduce the failure on linux_chromeos, so it might be a flakey failure, since it passed sometimes on that bot. This CL is basically the same as the CL list above, except that there is now a window->Focus() call in the unit test, since the reason the test was failing was when it was being made full screen it ceased to visible. This fixes the issue within this test. I will added a comment about this on the bug tracking the underlying issue. This is a re-attempt at http://codereview.chromium.org/10905026/, which ended up being reverted. The crash that caused the revert was actually due to powerd not being able to parse the protobuf correctly. https://gerrit.chromium.org/gerrit/32243/ corrects this issue, so once that CL lands this CL is good to go. I confirmed the combination of CLs works correctly. This is the original CL description: This adds a boolean to the video update message sent to powerd that indicates whether or not the video playing window is fullscreen'd. This is information used in powerd for controlling when to enable/disable keyboard backlights. Specifically if video is playing and fullscreen we assume that the user is doing something like watching a movie so will disable backlight. An additional change that I have made is to convert the message being sent from an int64 to a protobuffer that contains a int64 and a boolean. Currently, since the receiver of this message does not live in the same repo it means that every time one wants to change the message format there is a small window where bad builds can be generated or one has to land two changes to the other repo, one to add handling of the new message format and then a second one to remove the old format. Converting to a protobuffer means that for common cases this issues are removed. This CL depends on CLs for power_manager (https://gerrit.chromium.org/gerrit/32092/), one for system_api (https://gerrit.chromium.org/gerrit/31916), and a DEPS roll(http://codereview.chromium.org/10915032/). There will be future CLs for power_manager that will use this information and more thourghly tests this code. BUG=chrome-os-partner:9203 TEST=Run updated unittests. Confirm there is no messages in the cros logs about this method being mishandled. Make sure that powerd is not crashing due to protocol buffer processing failing. Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=156008

Patch Set 1 #

Total comments: 3

Patch Set 2 : Cleaned up the disabling in line with flackr's comments #

Patch Set 3 : Fix outstanding issue with unit test #

Unified diffs Side-by-side diffs Delta from patch set Stats (+95 lines, -17 lines) Patch
M ash/wm/video_detector.h View 1 chunk +1 line, -1 line 0 comments Download
M ash/wm/video_detector.cc View 2 chunks +5 lines, -1 line 0 comments Download
M ash/wm/video_detector_unittest.cc View 1 2 7 chunks +54 lines, -4 lines 0 comments Download
M chrome/browser/chromeos/power/video_activity_notifier.h View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/chromeos/power/video_activity_notifier.cc View 1 chunk +3 lines, -4 lines 0 comments Download
M chromeos/chromeos.gyp View 2 chunks +15 lines, -0 lines 0 comments Download
M chromeos/dbus/mock_power_manager_client.h View 1 chunk +1 line, -1 line 0 comments Download
M chromeos/dbus/power_manager_client.h View 1 chunk +4 lines, -2 lines 0 comments Download
M chromeos/dbus/power_manager_client.cc View 3 chunks +11 lines, -3 lines 0 comments Download

Messages

Total messages: 12 (0 generated)
rharrison
Sorry for having to upload this CL yet again. It was reverted due to a ...
8 years, 3 months ago (2012-09-07 17:00:01 UTC) #1
flackr
http://codereview.chromium.org/10913134/diff/1/ash/wm/video_detector_unittest.cc File ash/wm/video_detector_unittest.cc (right): http://codereview.chromium.org/10913134/diff/1/ash/wm/video_detector_unittest.cc#newcode241 ash/wm/video_detector_unittest.cc:241: TEST_F(VideoDetectorTest, DISABLED_FullscreenWindow) { Typically I've seen us use the ...
8 years, 3 months ago (2012-09-07 17:06:17 UTC) #2
Daniel Erat
http://codereview.chromium.org/10913134/diff/1/ash/wm/video_detector.cc File ash/wm/video_detector.cc (right): http://codereview.chromium.org/10913134/diff/1/ash/wm/video_detector.cc#newcode107 ash/wm/video_detector.cc:107: bool is_fullscreen = wm::IsWindowFullscreen(window); Does this method work differently ...
8 years, 3 months ago (2012-09-07 17:07:09 UTC) #3
rharrison
On 2012/09/07 17:07:09, Daniel Erat wrote: > http://codereview.chromium.org/10913134/diff/1/ash/wm/video_detector.cc > File ash/wm/video_detector.cc (right): > > http://codereview.chromium.org/10913134/diff/1/ash/wm/video_detector.cc#newcode107 ...
8 years, 3 months ago (2012-09-07 18:01:22 UTC) #4
Daniel Erat
On 2012/09/07 18:01:22, rharrison wrote: > On 2012/09/07 17:07:09, Daniel Erat wrote: > > http://codereview.chromium.org/10913134/diff/1/ash/wm/video_detector.cc ...
8 years, 3 months ago (2012-09-07 18:08:49 UTC) #5
rharrison
On 2012/09/07 18:08:49, Daniel Erat wrote: > On 2012/09/07 18:01:22, rharrison wrote: > > On ...
8 years, 3 months ago (2012-09-07 18:18:31 UTC) #6
rharrison
http://codereview.chromium.org/10913134/diff/1/ash/wm/video_detector_unittest.cc File ash/wm/video_detector_unittest.cc (right): http://codereview.chromium.org/10913134/diff/1/ash/wm/video_detector_unittest.cc#newcode241 ash/wm/video_detector_unittest.cc:241: TEST_F(VideoDetectorTest, DISABLED_FullscreenWindow) { On 2012/09/07 17:06:18, flackr wrote: > ...
8 years, 3 months ago (2012-09-07 18:20:55 UTC) #7
Daniel Erat
lgtm
8 years, 3 months ago (2012-09-07 18:28:24 UTC) #8
flackr
LGTM nit: Could reference the bug before the disable define block (similar to http://dev.chromium.org/developers/tree-sheriffs/sheriff-details-chromium/handling-a-failing-test).
8 years, 3 months ago (2012-09-07 19:16:48 UTC) #9
rharrison
On 2012/09/07 19:16:48, flackr wrote: > LGTM > > nit: Could reference the bug before ...
8 years, 3 months ago (2012-09-10 18:18:04 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/[email protected]/10913134/2003
8 years, 3 months ago (2012-09-11 13:22:07 UTC) #11
commit-bot: I haz the power
8 years, 3 months ago (2012-09-11 13:23:32 UTC) #12
Change committed as 156008

Powered by Google App Engine
This is Rietveld 408576698