DescriptionSwap main menu with app-specific menu when app window focused.
When an app window is focused, a new menu item is created for that app
and appended to the main menu. All of Chrome's menu items are hidden.
When a Chrome window is focused, the app's menu item is removed and
Chrome's menu items are unhidden.
This is a second attempt at https://codereview.chromium.org/18089012/
which had to be reverted because it broke keyboard shortcuts.
This moves all packaged app menu item handling into a new AppShimMenuController.
BUG=168080, 276052
Focus the app window, the only item in the main menu bar should be that app.
Focus a browser window, the main menu bar returns to normal.
Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=220540
Patch Set 1 #
Total comments: 39
Patch Set 2 : Also catch NSWindowWillCloseNotification. #Patch Set 3 : Don't recreate the menu each time. #
Total comments: 20
Patch Set 4 : Address comments #Patch Set 5 : Factor out initialization code. #
Total comments: 3
Patch Set 6 : Use isEqualToString #Patch Set 7 : Sync and rebase #Patch Set 8 : Move platform_app_browsertest_util.h #Patch Set 9 : Missed something in rebase. #
Total comments: 12
Patch Set 10 : Address comments #Patch Set 11 : Address comment #
Total comments: 4
Patch Set 12 : Address comments #Patch Set 13 : Sync and rebase #Patch Set 14 : Fix gypi #
Messages
Total messages: 18 (0 generated)
|