OLD | NEW |
---|---|
(Empty) | |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | |
tapted
2013/08/15 04:39:23
nit: no (c)
jackhou1
2013/08/16 02:50:41
Done.
| |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef CHROME_BROWSER_UI_COCOA_APPS_APP_MENU_CONTROLLER_MAC_H_ | |
6 #define CHROME_BROWSER_UI_COCOA_APPS_APP_MENU_CONTROLLER_MAC_H_ | |
7 | |
8 #import <Cocoa/Cocoa.h> | |
9 | |
10 #include "base/mac/scoped_nsobject.h" | |
11 | |
12 // This controller listens to NSWindowDidBecomeMainNotification and | |
13 // NSWindowDidResignMainNotification and modifies the main menu bar to mimic a | |
14 // main menu for the app. When an app window becomes main, all Chrome menu items | |
15 // are hidden and menu items for the app are appended to the main menu. When the | |
16 // app window resigns main, its menu items are removed and all Chrome menu items | |
17 // are unhidden. | |
18 @interface AppMenuController : NSObject { | |
19 @private | |
20 // The app id of the currently focused packaged app. | |
tapted
2013/08/15 04:39:23
nit: maybe in the comment call it an extension id
jackhou1
2013/08/16 02:50:41
Done.
| |
21 base::scoped_nsobject<NSString> appId_; | |
22 // An array of items related to the currently focused packaged app. | |
23 base::scoped_nsobject<NSMutableArray> appMenuItems_; | |
tapted
2013/08/15 04:39:23
I think until we add multiple items, this should j
jackhou1
2013/08/16 02:50:41
Done.
| |
24 } | |
25 | |
26 - (id)init; | |
tapted
2013/08/15 04:39:23
Don't need to redeclare this, since you inherit th
jackhou1
2013/08/16 02:50:41
Done.
| |
27 | |
28 @end | |
29 | |
30 #endif // CHROME_BROWSER_UI_COCOA_APPS_APP_MENU_CONTROLLER_MAC_H_ | |
OLD | NEW |