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

Issue 12313118: Refactor: Shelf Widget (Closed)

Created:
7 years, 10 months ago by Harry McCleave
Modified:
7 years, 9 months ago
CC:
chromium-reviews, tfarina, sadrul, dcheng, ben+watch_chromium.org
Base URL:
http://git.chromium.org/chromium/src.git@master
Visibility:
Public.

Description

Refactor: Shelf Widget Refactor the classes related with displaying the shelf (background behind the launcher/status area widget) to be a separate class. Removing background delegates from the launcher and status area widget (represented on tray views). TBR=ben@chromium.org BUG=163002 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=187122

Patch Set 1 #

Patch Set 2 : cleanup #

Patch Set 3 : fixed unit tests #

Patch Set 4 : removed double shadow (invisible) #

Patch Set 5 : formatting and moved a couple unit tests #

Total comments: 19

Patch Set 6 : #

Patch Set 7 : #

Total comments: 45

Patch Set 8 : #

Total comments: 31

Patch Set 9 : #

Total comments: 4

Patch Set 10 : #

Total comments: 65

Patch Set 11 : #

Patch Set 12 : #

Total comments: 1

Patch Set 13 : #

Patch Set 14 : rebase #

Patch Set 15 : + TargetBounds::~TargetBounds #

Patch Set 16 : another rebase #

Patch Set 17 : and again..... #

Patch Set 18 : safer shutdown (status_area_widget_) #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1193 lines, -3772 lines) Patch
M ash/accelerators/accelerator_controller.cc View 1 2 3 4 5 6 7 8 9 10 3 chunks +3 lines, -2 lines 0 comments Download
M ash/ash.gyp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 5 chunks +9 lines, -6 lines 0 comments Download
M ash/dip_unittest.cc View 1 2 3 4 5 6 7 2 chunks +2 lines, -1 line 0 comments Download
M ash/display/display_controller_unittest.cc View 1 2 3 4 5 6 7 8 9 3 chunks +3 lines, -2 lines 0 comments Download
M ash/focus_cycler_unittest.cc View 1 2 3 4 5 6 7 8 9 10 7 chunks +46 lines, -46 lines 0 comments Download
D ash/launcher/background_animator.h View 1 chunk +0 lines, -72 lines 0 comments Download
D ash/launcher/background_animator.cc View 1 chunk +0 lines, -57 lines 0 comments Download
M ash/launcher/launcher.h View 1 2 3 4 5 6 7 8 9 10 7 chunks +10 lines, -62 lines 0 comments Download
M ash/launcher/launcher.cc View 1 2 3 4 5 6 7 8 9 10 4 chunks +26 lines, -295 lines 0 comments Download
M ash/launcher/launcher_alignment_menu.cc View 1 1 chunk +2 lines, -2 lines 0 comments Download
M ash/launcher/launcher_button.cc View 1 chunk +1 line, -1 line 0 comments Download
M ash/launcher/launcher_tooltip_manager.h View 1 2 3 4 5 1 chunk +2 lines, -2 lines 0 comments Download
M ash/launcher/launcher_tooltip_manager.cc View 1 2 3 4 5 1 chunk +1 line, -1 line 0 comments Download
M ash/launcher/launcher_tooltip_manager_unittest.cc View 1 2 3 4 5 6 7 8 9 10 5 chunks +8 lines, -6 lines 0 comments Download
M ash/launcher/launcher_unittest.cc View 1 2 3 chunks +1 line, -123 lines 0 comments Download
M ash/launcher/launcher_view.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +0 lines, -1 line 0 comments Download
M ash/launcher/launcher_view.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +2 lines, -1 line 0 comments Download
M ash/launcher/launcher_view_unittest.cc View 1 2 3 4 5 6 7 8 2 chunks +7 lines, -5 lines 0 comments Download
M ash/launcher/overflow_bubble.cc View 1 1 chunk +1 line, -1 line 0 comments Download
M ash/launcher/overflow_button.h View 1 chunk +1 line, -1 line 0 comments Download
M ash/launcher/overflow_button.cc View 1 chunk +1 line, -1 line 0 comments Download
M ash/root_window_controller.h View 1 2 3 4 5 6 7 8 9 10 6 chunks +12 lines, -27 lines 0 comments Download
M ash/root_window_controller.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 12 chunks +36 lines, -103 lines 0 comments Download
M ash/root_window_controller_unittest.cc View 1 2 3 4 5 6 7 8 9 10 2 chunks +5 lines, -1 line 0 comments Download
M ash/screen_ash.cc View 1 2 chunks +3 lines, -2 lines 0 comments Download
M ash/screen_ash_unittest.cc View 1 2 3 4 5 6 7 8 9 10 2 chunks +4 lines, -2 lines 0 comments Download
A + ash/shelf/background_animator.h View 1 2 3 4 5 6 3 chunks +4 lines, -5 lines 0 comments Download
A + ash/shelf/background_animator.cc View 1 chunk +1 line, -1 line 0 comments Download
A + ash/shelf/shelf_layout_manager.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 8 chunks +15 lines, -21 lines 0 comments Download
A + ash/shelf/shelf_layout_manager.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 22 chunks +162 lines, -184 lines 0 comments Download
A + ash/shelf/shelf_layout_manager_unittest.cc View 1 2 3 4 5 6 7 8 9 10 28 chunks +70 lines, -94 lines 0 comments Download
A + ash/shelf/shelf_types.h View 1 2 3 4 5 6 7 2 chunks +3 lines, -3 lines 0 comments Download
A ash/shelf/shelf_widget.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 1 chunk +104 lines, -0 lines 0 comments Download
A ash/shelf/shelf_widget.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 1 chunk +312 lines, -0 lines 0 comments Download
A ash/shelf/shelf_widget_unittest.cc View 1 2 3 4 5 6 7 8 9 10 1 chunk +156 lines, -0 lines 0 comments Download
D ash/shelf_types.h View 1 chunk +0 lines, -46 lines 0 comments Download
M ash/shell.h View 1 2 3 4 5 6 7 8 9 10 3 chunks +8 lines, -8 lines 0 comments Download
M ash/shell.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 4 chunks +16 lines, -9 lines 0 comments Download
M ash/shell/context_menu.h View 1 2 3 4 5 6 7 2 chunks +4 lines, -4 lines 0 comments Download
M ash/shell/context_menu.cc View 1 chunk +1 line, -1 line 0 comments Download
M ash/shell/window_type_launcher.cc View 1 2 3 4 5 6 7 8 9 2 chunks +3 lines, -2 lines 0 comments Download
M ash/shell/window_watcher.cc View 3 chunks +5 lines, -2 lines 0 comments Download
M ash/shell_unittest.cc View 1 2 3 4 5 6 7 8 9 10 4 chunks +10 lines, -6 lines 0 comments Download
M ash/shell_window_ids.h View 1 chunk +2 lines, -2 lines 0 comments Download
M ash/system/ime/tray_ime.cc View 1 2 3 4 5 6 7 8 9 2 chunks +1 line, -1 line 0 comments Download
M ash/system/session_length_limit/tray_session_length_limit.cc View 1 chunk +1 line, -1 line 0 comments Download
M ash/system/status_area_widget.h View 1 2 3 2 chunks +1 line, -7 lines 0 comments Download
M ash/system/status_area_widget.cc View 1 2 3 3 chunks +2 lines, -10 lines 0 comments Download
M ash/system/status_area_widget_delegate.h View 1 chunk +1 line, -1 line 0 comments Download
M ash/system/tray/system_tray.cc View 1 2 3 4 5 6 7 8 9 2 chunks +1 line, -1 line 0 comments Download
M ash/system/tray/system_tray_item.h View 1 chunk +1 line, -1 line 0 comments Download
M ash/system/tray/system_tray_unittest.cc View 3 chunks +4 lines, -3 lines 0 comments Download
M ash/system/tray/tray_background_view.h View 1 2 3 4 5 6 3 chunks +2 lines, -9 lines 0 comments Download
M ash/system/tray/tray_background_view.cc View 1 2 3 4 5 6 7 8 9 8 chunks +6 lines, -19 lines 0 comments Download
M ash/system/tray/tray_event_filter.cc View 1 2 chunks +1 line, -1 line 0 comments Download
M ash/system/tray/tray_item_view.cc View 1 chunk +1 line, -1 line 0 comments Download
M ash/system/tray/tray_views.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1 chunk +1 line, -1 line 0 comments Download
M ash/system/tray_update.cc View 1 3 chunks +3 lines, -2 lines 0 comments Download
M ash/system/web_notification/web_notification_tray.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1 chunk +1 line, -1 line 0 comments Download
M ash/system/web_notification/web_notification_tray_unittest.cc View 1 2 3 4 5 6 7 8 9 10 2 chunks +3 lines, -2 lines 0 comments Download
M ash/wm/activation_controller.cc View 1 chunk +1 line, -1 line 0 comments Download
M ash/wm/app_list_controller.cc View 1 2 3 4 5 6 7 8 9 10 2 chunks +3 lines, -2 lines 0 comments Download
M ash/wm/ash_activation_controller.cc View 1 2 chunks +8 lines, -15 lines 0 comments Download
M ash/wm/ash_activation_controller_unittest.cc View 1 2 chunks +2 lines, -1 line 0 comments Download
M ash/wm/ash_focus_rules.cc View 1 chunk +1 line, -1 line 0 comments Download
M ash/wm/base_layout_manager.cc View 1 1 chunk +1 line, -1 line 0 comments Download
M ash/wm/drag_window_resizer_unittest.cc View 1 2 3 4 5 6 7 8 9 10 2 chunks +2 lines, -2 lines 0 comments Download
M ash/wm/gestures/shelf_gesture_handler.cc View 1 2 3 4 5 6 7 8 9 10 4 chunks +9 lines, -7 lines 0 comments Download
M ash/wm/gestures/system_pinch_handler.cc View 1 2 chunks +2 lines, -1 line 0 comments Download
M ash/wm/maximize_bubble_controller.cc View 1 chunk +1 line, -1 line 0 comments Download
M ash/wm/panels/panel_layout_manager.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 4 chunks +9 lines, -6 lines 0 comments Download
M ash/wm/panels/panel_layout_manager_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 2 chunks +5 lines, -2 lines 0 comments Download
M ash/wm/panels/panel_window_resizer.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 2 chunks +4 lines, -3 lines 0 comments Download
M ash/wm/panels/panel_window_resizer_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 2 chunks +4 lines, -2 lines 0 comments Download
M ash/wm/session_state_animator.cc View 2 chunks +2 lines, -2 lines 0 comments Download
D ash/wm/shelf_layout_manager.h View 1 chunk +0 lines, -338 lines 0 comments Download
D ash/wm/shelf_layout_manager.cc View 1 chunk +0 lines, -945 lines 0 comments Download
D ash/wm/shelf_layout_manager_unittest.cc View 1 2 1 chunk +0 lines, -1132 lines 0 comments Download
M ash/wm/stacking_controller_unittest.cc View 1 2 3 4 5 6 7 8 9 10 1 chunk +1 line, -1 line 0 comments Download
M ash/wm/status_area_layout_manager.h View 1 2 3 4 5 6 2 chunks +3 lines, -4 lines 0 comments Download
M ash/wm/status_area_layout_manager.cc View 1 3 chunks +5 lines, -4 lines 0 comments Download
M ash/wm/workspace/frame_maximize_button.cc View 1 2 chunks +2 lines, -1 line 0 comments Download
M ash/wm/workspace/phantom_window_controller.cc View 1 chunk +1 line, -1 line 0 comments Download
M ash/wm/workspace/workspace_cycler_animator.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 2 chunks +6 lines, -6 lines 0 comments Download
M ash/wm/workspace/workspace_layout_manager_unittest.cc View 1 2 3 4 5 6 7 8 9 10 2 chunks +4 lines, -3 lines 0 comments Download
M ash/wm/workspace/workspace_manager.cc View 1 1 chunk +1 line, -1 line 0 comments Download
M ash/wm/workspace/workspace_manager_unittest.cc View 1 2 3 4 5 6 7 8 9 10 5 chunks +11 lines, -5 lines 0 comments Download
M ash/wm/workspace/workspace_window_resizer_unittest.cc View 1 2 3 4 5 6 7 8 9 10 3 chunks +4 lines, -4 lines 0 comments Download
M chrome/browser/ui/ash/chrome_shell_delegate.cc View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/ui/ash/launcher/chrome_launcher_controller.h View 1 2 3 4 5 6 7 8 9 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/ash/launcher/chrome_launcher_controller_per_app.h View 1 2 3 4 5 6 7 8 9 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/ash/launcher/chrome_launcher_controller_per_browser.h View 1 2 3 4 5 6 7 8 9 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/ash/shelf_browsertest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/browser/ui/views/immersive_mode_controller_browsertest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +3 lines, -3 lines 0 comments Download

Messages

Total messages: 31 (0 generated)
Harry McCleave
Please take a look when you get a chance. https://codereview.chromium.org/12313118/diff/8001/ui/compositor/layer_animation_element.cc File ui/compositor/layer_animation_element.cc (right): https://codereview.chromium.org/12313118/diff/8001/ui/compositor/layer_animation_element.cc#newcode556 ui/compositor/layer_animation_element.cc:556: ...
7 years, 10 months ago (2013-02-27 04:05:38 UTC) #1
Mr4D (OOO till 08-26)
Due to the size of the review I need to do this in turns... Here ...
7 years, 9 months ago (2013-02-27 19:42:51 UTC) #2
Harry McCleave
https://codereview.chromium.org/12313118/diff/8001/ash/focus_cycler_unittest.cc File ash/focus_cycler_unittest.cc (right): https://codereview.chromium.org/12313118/diff/8001/ash/focus_cycler_unittest.cc#newcode58 ash/focus_cycler_unittest.cc:58: Launcher::ForPrimaryDisplay()->shelf_widget()->SetFocusCycler(NULL); On 2013/02/27 19:42:51, Mr4D wrote: > Couldn't you ...
7 years, 9 months ago (2013-03-01 04:31:19 UTC) #3
Mr4D (OOO till 08-26)
Okay. Lots of comments (sorry) - but we are getting there! (good for a first ...
7 years, 9 months ago (2013-03-02 02:02:12 UTC) #4
Harry McCleave
https://codereview.chromium.org/12313118/diff/15001/ash/shelf/shelf_layout_manager.cc File ash/shelf/shelf_layout_manager.cc (right): https://codereview.chromium.org/12313118/diff/15001/ash/shelf/shelf_layout_manager.cc#newcode230 ash/shelf/shelf_layout_manager.cc:230: } On 2013/03/02 02:02:12, Mr4D wrote: > These brackets ...
7 years, 9 months ago (2013-03-04 02:47:40 UTC) #5
James Cook
Ping me when you're ready for OWNERS.
7 years, 9 months ago (2013-03-04 18:03:22 UTC) #6
Mr4D (OOO till 08-26)
I got to run into an IV - but to get you going again, I ...
7 years, 9 months ago (2013-03-04 19:18:04 UTC) #7
tfarina
https://codereview.chromium.org/12313118/diff/14002/ash/launcher/launcher.cc File ash/launcher/launcher.cc (right): https://codereview.chromium.org/12313118/diff/14002/ash/launcher/launcher.cc#newcode63 ash/launcher/launcher.cc:63: Launcher::~Launcher() { On 2013/03/04 19:18:04, Mr4D wrote: > Since ...
7 years, 9 months ago (2013-03-04 19:19:58 UTC) #8
Harry McCleave
https://codereview.chromium.org/12313118/diff/14002/ash/launcher/launcher_view_unittest.cc File ash/launcher/launcher_view_unittest.cc (right): https://codereview.chromium.org/12313118/diff/14002/ash/launcher/launcher_view_unittest.cc#newcode185 ash/launcher/launcher_view_unittest.cc:185: gfx::Rect(0, 0, total_width, shelf_size.height())); On 2013/03/04 19:18:04, Mr4D wrote: ...
7 years, 9 months ago (2013-03-04 20:29:24 UTC) #9
Mr4D (OOO till 08-26)
lgtm A few more nits and then lgtm https://codereview.chromium.org/12313118/diff/14002/ash/root_window_controller.cc File ash/root_window_controller.cc (right): https://codereview.chromium.org/12313118/diff/14002/ash/root_window_controller.cc#newcode426 ash/root_window_controller.cc:426: return ...
7 years, 9 months ago (2013-03-04 22:59:00 UTC) #10
Harry McCleave
Ready for Owner review. https://codereview.chromium.org/12313118/diff/12097/ash/shelf/shelf_layout_manager.h File ash/shelf/shelf_layout_manager.h (right): https://codereview.chromium.org/12313118/diff/12097/ash/shelf/shelf_layout_manager.h#newcode6 ash/shelf/shelf_layout_manager.h:6: #define ASH_WM_SHELF_LAYOUT_MANAGER_H_ On 2013/03/04 22:59:00, ...
7 years, 9 months ago (2013-03-05 05:59:19 UTC) #11
James Cook
I should get to it this afternoon.
7 years, 9 months ago (2013-03-05 18:17:01 UTC) #12
James Cook
Almost there! This is a good cleanup. When this is all done I think you ...
7 years, 9 months ago (2013-03-05 20:30:38 UTC) #13
Mr4D (OOO till 08-26)
One other tiny nit. https://codereview.chromium.org/12313118/diff/27001/ash/shelf/shelf_widget.cc File ash/shelf/shelf_widget.cc (right): https://codereview.chromium.org/12313118/diff/27001/ash/shelf/shelf_widget.cc#newcode97 ash/shelf/shelf_widget.cc:97: child_at(i)->width(),height()); And also but {} ...
7 years, 9 months ago (2013-03-05 20:42:10 UTC) #14
Harry McCleave
https://codereview.chromium.org/12313118/diff/27001/ash/focus_cycler_unittest.cc File ash/focus_cycler_unittest.cc (right): https://codereview.chromium.org/12313118/diff/27001/ash/focus_cycler_unittest.cc#newcode130 ash/focus_cycler_unittest.cc:130: // Cycle focus to the shelf On 2013/03/05 20:30:38, ...
7 years, 9 months ago (2013-03-06 01:59:49 UTC) #15
James Cook
LGTM with one nit. Patch it, land it, and let the pain be over. https://codereview.chromium.org/12313118/diff/45001/ash/shelf/shelf_widget.cc ...
7 years, 9 months ago (2013-03-06 02:39:03 UTC) #16
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/harrym@chromium.org/12313118/74001
7 years, 9 months ago (2013-03-06 03:27:23 UTC) #17
commit-bot: I haz the power
Presubmit check for 12313118-74001 failed and returned exit status 1. INFO:root:Found 88 file(s). Running presubmit ...
7 years, 9 months ago (2013-03-06 03:28:09 UTC) #18
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/harrym@chromium.org/12313118/74001
7 years, 9 months ago (2013-03-06 03:33:45 UTC) #19
commit-bot: I haz the power
Sorry for I got bad news for ya. Compile failed with a clobber build on ...
7 years, 9 months ago (2013-03-06 03:57:46 UTC) #20
Ben Goodger (Google)
lgtm for c/b/u/v
7 years, 9 months ago (2013-03-06 17:49:24 UTC) #21
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/harrym@chromium.org/12313118/92001
7 years, 9 months ago (2013-03-07 01:05:05 UTC) #22
commit-bot: I haz the power
Sorry for I got bad news for ya. Compile failed with a clobber build on ...
7 years, 9 months ago (2013-03-07 02:12:59 UTC) #23
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/harrym@chromium.org/12313118/104001
7 years, 9 months ago (2013-03-07 22:34:42 UTC) #24
commit-bot: I haz the power
Failed to apply patch for ash/wm/panel_layout_manager.cc: While running patch -p1 --forward --force --no-backup-if-mismatch; patching file ...
7 years, 9 months ago (2013-03-07 22:35:12 UTC) #25
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/harrym@chromium.org/12313118/106001
7 years, 9 months ago (2013-03-07 23:54:42 UTC) #26
commit-bot: I haz the power
Retried try job too often on linux_chromeos for step(s) interactive_ui_tests http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=linux_chromeos&number=90976
7 years, 9 months ago (2013-03-08 01:32:38 UTC) #27
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/harrym@chromium.org/12313118/123001
7 years, 9 months ago (2013-03-08 03:26:40 UTC) #28
commit-bot: I haz the power
Retried try job too often on linux_chromeos for step(s) interactive_ui_tests http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=linux_chromeos&number=91042
7 years, 9 months ago (2013-03-08 04:42:38 UTC) #29
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/harrym@chromium.org/12313118/76004
7 years, 9 months ago (2013-03-08 23:42:12 UTC) #30
commit-bot: I haz the power
7 years, 9 months ago (2013-03-09 02:51:03 UTC) #31
Message was sent while issue was closed.
Change committed as 187122

Powered by Google App Engine
This is Rietveld 408576698