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

Issue 2825533003: mash: Prerequisites for removing ShelfDelegate. (Closed)

Created:
3 years, 8 months ago by msw
Modified:
3 years, 8 months ago
Reviewers:
James Cook, Yusuke Sato
CC:
chromium-reviews, elijahtaylor+arcwatch_chromium.org, sadrul, yusukes+watch_chromium.org, hidehiko+watch_chromium.org, oshima+watch_chromium.org, lhchavez+watch_chromium.org, victorhsieh+watch_chromium.org, kalyank, davemoore+watch_chromium.org
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

mash: Prerequisites for removing ShelfDelegate. This CL splits out some optionally prerequisite work from: https://codereview.chromium.org/2791463002/ Most changes are test-only, and shouldn't affect production. Nix unused CreatePanel function in accelerator_controller_unittest.cc Nix UserMetricsRecorderTest::CreateTestWindow, add ShelfModel items. Nix unnecessary ShelfTooltipManagerTest and ShelfTest item delegates. Make ShelfApplicationMenuModel work with a null item delegate. (supports a simplification in the test file) Make AshTestBase set the shelf item type property for test panels. (uses ShelfWindowWatcher for test panels, similar to production) Cleanup shelf_view_unittest.cc: -Base classes on ash::ShelfItemDelegate, not TestShelfItemDelegate. -Track the count of selections, rather than a bool & Reset(). -Add ShelfModel items directly instead of making windows for items. -Nix TestShelfDelegateForShelfView, rely on TestShelfDelegate instead. -Refactor helper functions for adding shelf items. Make TestShelfDelegate directly manipulate ShelfModel items. (behaves much more like CLC, the production ShelfDelegate impl) Move ShelfInitializer from TestShelfDelegate to TestShellDelegate. (TestShelfDelegate will be removed, but tests still need shelf init) Exclude a few expectations for mash in PanelLayoutManagerTest.* Refine PanelWindowResizerTest comments and expectations. -Expect panel ordering like production (added right to left). -Skip testing a panel as a transient child of a panel (odd, broken). BUG=557406, 698887 TEST=No Chrome OS shelf behavior changes. Tests pass. R=jamescook@chomium.org TBR=yusukes@chromium.org Review-Url: https://codereview.chromium.org/2825533003 Cr-Commit-Position: refs/heads/master@{#465272} Committed: https://chromium.googlesource.com/chromium/src/+/448103a0613cc1d0170c2fddf815c5d39ba411f7

Patch Set 1 #

Patch Set 2 : Refine TestShelfDelegate::IsAppPinned; cleanup. #

Total comments: 23

Patch Set 3 : Make TestShelfDelegate work more like production. #

Patch Set 4 : Address comments. #

Patch Set 5 : Expand CheckWindowAndItemPlacement comment. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+228 lines, -444 lines) Patch
M ash/accelerators/accelerator_controller_unittest.cc View 2 chunks +0 lines, -9 lines 0 comments Download
M ash/metrics/user_metrics_recorder_unittest.cc View 4 chunks +18 lines, -36 lines 0 comments Download
M ash/shelf/shelf_application_menu_model.cc View 1 chunk +2 lines, -2 lines 0 comments Download
M ash/shelf/shelf_application_menu_model_unittest.cc View 2 chunks +1 line, -3 lines 0 comments Download
M ash/shelf/shelf_tooltip_manager_unittest.cc View 2 chunks +0 lines, -4 lines 0 comments Download
M ash/shelf/shelf_unittest.cc View 2 chunks +0 lines, -5 lines 0 comments Download
M ash/shelf/shelf_view_unittest.cc View 1 2 3 13 chunks +60 lines, -176 lines 0 comments Download
M ash/shelf/wm_shelf.cc View 1 chunk +0 lines, -1 line 0 comments Download
M ash/test/ash_test_base.cc View 2 chunks +4 lines, -0 lines 0 comments Download
M ash/test/test_shelf_delegate.h View 1 2 chunks +1 line, -31 lines 0 comments Download
M ash/test/test_shelf_delegate.cc View 1 2 3 3 chunks +42 lines, -107 lines 0 comments Download
M ash/test/test_shell_delegate.h View 2 chunks +3 lines, -0 lines 0 comments Download
M ash/test/test_shell_delegate.cc View 1 2 3 4 chunks +30 lines, -0 lines 0 comments Download
M ash/wm/overview/window_selector_unittest.cc View 2 chunks +0 lines, -2 lines 0 comments Download
M ash/wm/panels/panel_layout_manager_unittest.cc View 1 6 chunks +19 lines, -11 lines 0 comments Download
M ash/wm/panels/panel_window_resizer_unittest.cc View 1 2 3 4 6 chunks +48 lines, -52 lines 0 comments Download
M ash/wm/window_cycle_controller_unittest.cc View 2 chunks +0 lines, -2 lines 0 comments Download
M ash/wm/workspace_controller_unittest.cc View 2 chunks +0 lines, -2 lines 0 comments Download
M chrome/browser/chromeos/arc/arc_session_manager.cc View 1 chunk +0 lines, -1 line 0 comments Download

Messages

Total messages: 38 (28 generated)
msw
Hey James, please take a look; thanks! This CL is simpler than my exhaustive CL ...
3 years, 8 months ago (2017-04-17 22:02:40 UTC) #7
James Cook
Mostly questions. Also, you have a browser_tests failure. https://codereview.chromium.org/2825533003/diff/20001/ash/shelf/shelf_view_unittest.cc File ash/shelf/shelf_view_unittest.cc (left): https://codereview.chromium.org/2825533003/diff/20001/ash/shelf/shelf_view_unittest.cc#oldcode685 ash/shelf/shelf_view_unittest.cc:685: void ...
3 years, 8 months ago (2017-04-17 23:59:02 UTC) #16
msw
Test failures should be fixed (by patch set 3). Please take another look, thanks! https://codereview.chromium.org/2825533003/diff/20001/ash/shelf/shelf_view_unittest.cc ...
3 years, 8 months ago (2017-04-18 01:07:05 UTC) #19
James Cook
LGTM. Thanks for splitting this into a separate patch. https://codereview.chromium.org/2825533003/diff/20001/ash/wm/panels/panel_window_resizer_unittest.cc File ash/wm/panels/panel_window_resizer_unittest.cc (left): https://codereview.chromium.org/2825533003/diff/20001/ash/wm/panels/panel_window_resizer_unittest.cc#oldcode562 ash/wm/panels/panel_window_resizer_unittest.cc:562: ...
3 years, 8 months ago (2017-04-18 15:10:36 UTC) #24
msw
https://codereview.chromium.org/2825533003/diff/20001/ash/wm/panels/panel_window_resizer_unittest.cc File ash/wm/panels/panel_window_resizer_unittest.cc (right): https://codereview.chromium.org/2825533003/diff/20001/ash/wm/panels/panel_window_resizer_unittest.cc#newcode137 ash/wm/panels/panel_window_resizer_unittest.cc:137: (first_item_bounds.y() < second_item_bounds.y())); On 2017/04/18 15:10:36, James Cook wrote: ...
3 years, 8 months ago (2017-04-18 16:43:46 UTC) #25
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2825533003/80001
3 years, 8 months ago (2017-04-18 16:44:20 UTC) #28
commit-bot: I haz the power
Try jobs failed on following builders: chromium_presubmit on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presubmit/builds/413918)
3 years, 8 months ago (2017-04-18 16:52:18 UTC) #30
msw
+TBR yusukes@ for removing an unused include from: chrome/browser/chromeos/arc/arc_session_manager.cc
3 years, 8 months ago (2017-04-18 16:56:29 UTC) #33
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2825533003/80001
3 years, 8 months ago (2017-04-18 16:56:58 UTC) #35
commit-bot: I haz the power
3 years, 8 months ago (2017-04-18 17:25:12 UTC) #38
Message was sent while issue was closed.
Committed patchset #5 (id:80001) as
https://chromium.googlesource.com/chromium/src/+/448103a0613cc1d0170c2fddf815...

Powered by Google App Engine
This is Rietveld 408576698