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

Issue 2391253004: Use mojo Shelf interfaces for both mash and classic ash. (Closed)

Created:
4 years, 2 months ago by msw
Modified:
4 years, 2 months ago
Reviewers:
James Cook, sky
CC:
chromium-reviews, sadrul, qsr+mojo_chromium.org, viettrungluu+watch_chromium.org, yzshen+watch_chromium.org, abarth-chromium, Aaron Boodman, kalyank, darin (slow to review), James Cook, mfomitchev
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Use mojo Shelf interfaces for both mash and classic ash. ( Similar to https://codereview.chromium.org/2381753002 ) Add a mojom::ShelfController implementation in ash. Migrate some functionality from ShelfDelegateMus. (pinning, id mapping, etc. are unused at the moment) Move some chrome-side shelf init checking to ash. Move ownership of the ShelfModel to ShelfController. Move ShelfAlignmentAllowed from ShelfWidget to WmShelf. Remove unused ShelfDelegate::OnShelf* functions. Make ChromeLauncherController a mojom::ShelfObserver. Consolidate functionality from mash and classic ash. New CLC functionality replaces ChromeMashShelfController. Remove CLC::set_instance and CreateInstance helpers. Convert mash manifest usage from interfaces to classes. Inline chrome::InitializeMash. TODO: Make ChromeLauncherController work better in Mash. BUG=557406 TEST=No Chrome OS shelf alignment/auto-hide regressions. R=sky@chromium.org Committed: https://crrev.com/49cfb8939b817e91b0e6f6aa0a2bdd85fb8529a6 Cr-Commit-Position: refs/heads/master@{#424455}

Patch Set 1 #

Patch Set 2 : Use mojo ShelfController interface for both mash and classic ash. #

Patch Set 3 : Working on it... #

Patch Set 4 : Folding shelf client code into ChromeLauncherController. #

Patch Set 5 : Get classic ash working. #

Patch Set 6 : Cleanup #

Patch Set 7 : Sync and rebase. #

Patch Set 8 : Cleanup. #

Patch Set 9 : Sync and rebase. #

Total comments: 20

Patch Set 10 : Address most comments, except manifest, need to sync. #

Total comments: 2

Patch Set 11 : Sync and rebase. #

Patch Set 12 : Address manifest comment; working on test failures/crashes. #

Total comments: 2

Patch Set 13 : Address comment; test fixes and workarounds. #

Patch Set 14 : Fix and workaround test issues. #

Total comments: 4

Patch Set 15 : Address comments. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+757 lines, -1273 lines) Patch
M ash/BUILD.gn View 1 2 3 4 5 6 7 8 9 10 1 chunk +2 lines, -0 lines 0 comments Download
M ash/common/DEPS View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M ash/common/mojo_interface_factory.cc View 1 2 3 chunks +8 lines, -0 lines 0 comments Download
A ash/common/shelf/shelf_controller.h View 1 2 3 4 5 6 7 8 9 1 chunk +76 lines, -0 lines 0 comments Download
A + ash/common/shelf/shelf_controller.cc View 1 2 3 4 5 6 7 8 9 9 chunks +54 lines, -94 lines 0 comments Download
M ash/common/shelf/shelf_delegate.h View 1 2 3 4 1 chunk +0 lines, -20 lines 0 comments Download
M ash/common/shelf/shelf_layout_manager.cc View 1 2 2 chunks +0 lines, -9 lines 0 comments Download
M ash/common/shelf/shelf_widget.h View 1 2 1 chunk +0 lines, -4 lines 0 comments Download
M ash/common/shelf/shelf_widget.cc View 1 2 2 chunks +0 lines, -28 lines 0 comments Download
M ash/common/shelf/wm_shelf.h View 1 2 3 4 5 6 7 8 9 1 chunk +4 lines, -0 lines 0 comments Download
M ash/common/shelf/wm_shelf.cc View 1 2 3 4 5 6 7 8 9 10 11 12 6 chunks +32 lines, -5 lines 0 comments Download
M ash/common/wm/panels/panel_layout_manager.cc View 1 2 3 4 5 1 chunk +1 line, -1 line 0 comments Download
M ash/common/wm_shell.h View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +5 lines, -2 lines 0 comments Download
M ash/common/wm_shell.cc View 1 2 3 4 5 6 7 8 9 10 11 12 6 chunks +17 lines, -11 lines 0 comments Download
M ash/display/window_tree_host_manager.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +3 lines, -5 lines 0 comments Download
M ash/mus/manifest.json View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +5 lines, -0 lines 0 comments Download
M ash/mus/shelf_delegate_mus.h View 1 2 2 chunks +2 lines, -33 lines 0 comments Download
M ash/mus/shelf_delegate_mus.cc View 1 2 3 4 3 chunks +8 lines, -277 lines 0 comments Download
M ash/mus/shell_delegate_mus.cc View 1 2 1 chunk +1 line, -1 line 0 comments Download
M ash/mus/window_manager_application.h View 1 2 4 chunks +0 lines, -7 lines 0 comments Download
M ash/mus/window_manager_application.cc View 1 2 3 4 5 6 3 chunks +0 lines, -10 lines 0 comments Download
M ash/shelf/shelf_view_unittest.cc View 1 2 1 chunk +0 lines, -12 lines 0 comments Download
M ash/shelf/shelf_widget_unittest.cc View 1 2 3 4 5 6 4 chunks +26 lines, -82 lines 0 comments Download
M ash/test/test_shelf_delegate.h View 1 2 1 chunk +0 lines, -6 lines 0 comments Download
M ash/test/test_shelf_delegate.cc View 1 2 1 chunk +0 lines, -12 lines 0 comments Download
M chrome/app/mash/chrome_mash_content_browser_manifest_overlay.json View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +1 line, -7 lines 0 comments Download
M chrome/browser/chrome_content_browser_manifest_overlay.json View 1 2 3 4 5 6 7 8 9 10 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/ui/BUILD.gn View 1 2 3 4 5 6 7 8 1 chunk +0 lines, -2 lines 0 comments Download
M chrome/browser/ui/ash/app_list/app_list_controller_ash.cc View 1 2 3 1 chunk +2 lines, -2 lines 0 comments Download
M chrome/browser/ui/ash/app_list/app_list_service_ash.cc View 1 2 3 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/browser/ui/ash/ash_init.h View 1 2 3 4 5 6 7 8 9 1 chunk +0 lines, -3 lines 0 comments Download
M chrome/browser/ui/ash/ash_init.cc View 1 2 3 4 5 6 7 8 9 2 chunks +0 lines, -6 lines 0 comments Download
M chrome/browser/ui/ash/chrome_shell_delegate.cc View 1 2 3 4 5 6 7 8 9 10 1 chunk +1 line, -2 lines 0 comments Download
M chrome/browser/ui/ash/launcher/app_shortcut_launcher_item_controller.cc View 1 2 3 4 6 chunks +7 lines, -7 lines 0 comments Download
M chrome/browser/ui/ash/launcher/app_window_launcher_item_controller.cc View 1 2 3 2 chunks +3 lines, -3 lines 0 comments Download
M chrome/browser/ui/ash/launcher/arc_app_deferred_launcher_controller.cc View 1 2 3 14 3 chunks +4 lines, -4 lines 0 comments Download
M chrome/browser/ui/ash/launcher/arc_app_deferred_launcher_item_controller.cc View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/ash/launcher/arc_app_window_launcher_controller.cc View 1 2 3 4 5 6 4 chunks +5 lines, -5 lines 0 comments Download
M chrome/browser/ui/ash/launcher/arc_app_window_launcher_item_controller.cc View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/ash/launcher/arc_launcher_context_menu.cc View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/ash/launcher/arc_playstore_shortcut_launcher_item_controller.cc View 1 2 3 2 chunks +3 lines, -3 lines 0 comments Download
M chrome/browser/ui/ash/launcher/browser_shortcut_launcher_item_controller.cc View 1 2 3 5 chunks +7 lines, -8 lines 0 comments Download
M chrome/browser/ui/ash/launcher/chrome_launcher_controller.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 6 chunks +78 lines, -15 lines 0 comments Download
M chrome/browser/ui/ash/launcher/chrome_launcher_controller.cc View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +174 lines, -1 line 0 comments Download
M chrome/browser/ui/ash/launcher/chrome_launcher_controller_impl.h View 1 2 3 4 5 6 7 8 9 10 11 12 12 chunks +1 line, -48 lines 0 comments Download
M chrome/browser/ui/ash/launcher/chrome_launcher_controller_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 26 chunks +82 lines, -221 lines 0 comments Download
M chrome/browser/ui/ash/launcher/chrome_launcher_controller_impl_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 8 chunks +12 lines, -13 lines 0 comments Download
M chrome/browser/ui/ash/launcher/chrome_launcher_controller_mus.h View 1 2 3 4 5 6 7 8 9 4 chunks +12 lines, -11 lines 0 comments Download
M chrome/browser/ui/ash/launcher/chrome_launcher_controller_mus.cc View 1 2 3 4 5 6 7 8 9 4 chunks +89 lines, -24 lines 0 comments Download
D chrome/browser/ui/ash/launcher/chrome_mash_shelf_controller.h View 1 chunk +0 lines, -59 lines 0 comments Download
D chrome/browser/ui/ash/launcher/chrome_mash_shelf_controller.cc View 1 2 3 4 5 6 7 8 1 chunk +0 lines, -181 lines 0 comments Download
M chrome/browser/ui/ash/launcher/extension_app_window_launcher_controller.cc View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/ash/launcher/extension_launcher_context_menu.cc View 1 2 3 4 chunks +6 lines, -7 lines 0 comments Download
M chrome/browser/ui/ash/launcher/launcher_context_menu.cc View 1 2 3 4 5 6 7 8 9 5 chunks +6 lines, -7 lines 0 comments Download
M chrome/browser/ui/ash/launcher/launcher_controller_helper.h View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +2 lines, -3 lines 0 comments Download
M chrome/browser/ui/ash/launcher/launcher_controller_helper.cc View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +0 lines, -4 lines 0 comments Download
M chrome/browser/ui/views/ash/chrome_browser_main_extra_parts_ash.h View 1 2 3 4 5 6 7 8 9 2 chunks +2 lines, -0 lines 0 comments Download
M chrome/browser/ui/views/ash/chrome_browser_main_extra_parts_ash.cc View 1 2 3 4 5 6 7 8 9 2 chunks +8 lines, -2 lines 0 comments Download

Messages

Total messages: 42 (27 generated)
msw
Hey Scott, please take a look; thanks!
4 years, 2 months ago (2016-10-07 00:59:29 UTC) #3
sky
https://codereview.chromium.org/2391253004/diff/150001/ash/common/shelf/shelf_controller.cc File ash/common/shelf/shelf_controller.cc (left): https://codereview.chromium.org/2391253004/diff/150001/ash/common/shelf/shelf_controller.cc#oldcode196 ash/common/shelf/shelf_controller.cc:196: void ShelfDelegateMus::OnShelfVisibilityStateChanged(WmShelf* shelf) {} How come OnShelfAutoHideStateChanged and OnShelfVisibilityStateChanged ...
4 years, 2 months ago (2016-10-07 16:10:18 UTC) #12
msw
Hey Scott, please take another look; thanks! I'm investigating a few more test failures/crashes :( ...
4 years, 2 months ago (2016-10-07 22:45:58 UTC) #15
sky
https://codereview.chromium.org/2391253004/diff/170001/chrome/browser/ui/ash/chrome_shell_delegate.cc File chrome/browser/ui/ash/chrome_shell_delegate.cc (right): https://codereview.chromium.org/2391253004/diff/170001/chrome/browser/ui/ash/chrome_shell_delegate.cc#newcode437 chrome/browser/ui/ash/chrome_shell_delegate.cc:437: shelf_delegate_ = new ChromeLauncherControllerImpl(nullptr, model); Does this leak?
4 years, 2 months ago (2016-10-07 22:59:38 UTC) #16
msw
https://codereview.chromium.org/2391253004/diff/170001/chrome/browser/ui/ash/chrome_shell_delegate.cc File chrome/browser/ui/ash/chrome_shell_delegate.cc (right): https://codereview.chromium.org/2391253004/diff/170001/chrome/browser/ui/ash/chrome_shell_delegate.cc#newcode437 chrome/browser/ui/ash/chrome_shell_delegate.cc:437: shelf_delegate_ = new ChromeLauncherControllerImpl(nullptr, model); On 2016/10/07 22:59:37, sky ...
4 years, 2 months ago (2016-10-07 23:13:01 UTC) #17
sky
This looks good, but as discussed it sounds like you need to make a couple ...
4 years, 2 months ago (2016-10-07 23:26:25 UTC) #18
James Cook
https://codereview.chromium.org/2391253004/diff/210001/ash/common/wm_shell.h File ash/common/wm_shell.h (right): https://codereview.chromium.org/2391253004/diff/210001/ash/common/wm_shell.h#newcode155 ash/common/wm_shell.h:155: ShelfModel* shelf_model() { return shelf_controller_->model(); } drive by: I ...
4 years, 2 months ago (2016-10-10 17:18:14 UTC) #20
msw
Please take another look thanks, I think I resolved the last test issues. https://codereview.chromium.org/2391253004/diff/210001/ash/common/wm_shell.h File ...
4 years, 2 months ago (2016-10-11 00:44:06 UTC) #27
sky
LGTM https://codereview.chromium.org/2391253004/diff/250001/ash/display/window_tree_host_manager.cc File ash/display/window_tree_host_manager.cc (right): https://codereview.chromium.org/2391253004/diff/250001/ash/display/window_tree_host_manager.cc#newcode340 ash/display/window_tree_host_manager.cc:340: if (window_tree_hosts_.count(display_id) == 0) use find and a ...
4 years, 2 months ago (2016-10-11 02:40:37 UTC) #30
msw
https://codereview.chromium.org/2391253004/diff/250001/ash/display/window_tree_host_manager.cc File ash/display/window_tree_host_manager.cc (right): https://codereview.chromium.org/2391253004/diff/250001/ash/display/window_tree_host_manager.cc#newcode340 ash/display/window_tree_host_manager.cc:340: if (window_tree_hosts_.count(display_id) == 0) On 2016/10/11 02:40:37, sky wrote: ...
4 years, 2 months ago (2016-10-11 15:38:00 UTC) #31
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/2391253004/270001
4 years, 2 months ago (2016-10-11 15:38:21 UTC) #34
commit-bot: I haz the power
Try jobs failed on following builders: ios-simulator on master.tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/ios-simulator/builds/84489)
4 years, 2 months ago (2016-10-11 15:59:02 UTC) #36
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/2391253004/270001
4 years, 2 months ago (2016-10-11 16:04:30 UTC) #38
commit-bot: I haz the power
Committed patchset #15 (id:270001)
4 years, 2 months ago (2016-10-11 16:46:42 UTC) #40
commit-bot: I haz the power
4 years, 2 months ago (2016-10-11 16:49:15 UTC) #42
Message was sent while issue was closed.
Patchset 15 (id:??) landed as
https://crrev.com/49cfb8939b817e91b0e6f6aa0a2bdd85fb8529a6
Cr-Commit-Position: refs/heads/master@{#424455}

Powered by Google App Engine
This is Rietveld 408576698