Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CHROME_BROWSER_UI_ASH_LAUNCHER_CHROME_LAUNCHER_CONTROLLER_H_ | 5 #ifndef CHROME_BROWSER_UI_ASH_LAUNCHER_CHROME_LAUNCHER_CONTROLLER_H_ |
| 6 #define CHROME_BROWSER_UI_ASH_LAUNCHER_CHROME_LAUNCHER_CONTROLLER_H_ | 6 #define CHROME_BROWSER_UI_ASH_LAUNCHER_CHROME_LAUNCHER_CONTROLLER_H_ |
| 7 | 7 |
| 8 #include <list> | 8 #include <list> |
| 9 #include <map> | 9 #include <map> |
| 10 #include <set> | 10 #include <set> |
| (...skipping 29 matching lines...) Expand all Loading... | |
| 40 class Browser; | 40 class Browser; |
| 41 class BrowserShortcutLauncherItemController; | 41 class BrowserShortcutLauncherItemController; |
| 42 class BrowserStatusMonitor; | 42 class BrowserStatusMonitor; |
| 43 class ExtensionEnableFlow; | 43 class ExtensionEnableFlow; |
| 44 class GURL; | 44 class GURL; |
| 45 class LauncherItemController; | 45 class LauncherItemController; |
| 46 class Profile; | 46 class Profile; |
| 47 class AppWindowLauncherController; | 47 class AppWindowLauncherController; |
| 48 class TabContents; | 48 class TabContents; |
| 49 | 49 |
| 50 class ArcAppWindowLauncherController; | |
|
xiyuan
2016/03/23 23:22:53
nit: not used?
khmel
2016/03/24 16:30:38
Done.
| |
| 51 | |
| 50 namespace ash { | 52 namespace ash { |
| 51 class ShelfItemDelegateManager; | 53 class ShelfItemDelegateManager; |
| 52 class ShelfModel; | 54 class ShelfModel; |
| 53 } | 55 } |
| 54 | 56 |
| 55 namespace aura { | 57 namespace aura { |
| 56 class Window; | 58 class Window; |
| 57 } | 59 } |
| 58 | 60 |
| 59 namespace content { | 61 namespace content { |
| (...skipping 322 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 382 // Called when the user profile is fully loaded and ready to switch to. | 384 // Called when the user profile is fully loaded and ready to switch to. |
| 383 void OnUserProfileReadyToSwitch(Profile* profile); | 385 void OnUserProfileReadyToSwitch(Profile* profile); |
| 384 | 386 |
| 385 // Access to the BrowserStatusMonitor for tests. | 387 // Access to the BrowserStatusMonitor for tests. |
| 386 BrowserStatusMonitor* browser_status_monitor_for_test() { | 388 BrowserStatusMonitor* browser_status_monitor_for_test() { |
| 387 return browser_status_monitor_.get(); | 389 return browser_status_monitor_.get(); |
| 388 } | 390 } |
| 389 | 391 |
| 390 // Access to the AppWindowLauncherController for tests. | 392 // Access to the AppWindowLauncherController for tests. |
| 391 AppWindowLauncherController* app_window_controller_for_test() { | 393 AppWindowLauncherController* app_window_controller_for_test() { |
| 392 return app_window_controller_.get(); | 394 return app_window_controllers_[0].get(); |
| 393 } | 395 } |
| 394 | 396 |
| 395 bool CanPin(const std::string& app_id); | 397 bool CanPin(const std::string& app_id); |
| 396 | 398 |
| 397 protected: | 399 protected: |
| 398 // Creates a new app shortcut item and controller on the shelf at |index|. | 400 // Creates a new app shortcut item and controller on the shelf at |index|. |
| 399 // Use kInsertItemAtEnd to add a shortcut as the last item. | 401 // Use kInsertItemAtEnd to add a shortcut as the last item. |
| 400 ash::ShelfID CreateAppShortcutLauncherItem(const std::string& app_id, | 402 ash::ShelfID CreateAppShortcutLauncherItem(const std::string& app_id, |
| 401 int index); | 403 int index); |
| 402 | 404 |
| (...skipping 148 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 551 // profile new windows are created with. | 553 // profile new windows are created with. |
| 552 Profile* profile_; | 554 Profile* profile_; |
| 553 | 555 |
| 554 // Controller items in this map are owned by |ShelfItemDelegateManager|. | 556 // Controller items in this map are owned by |ShelfItemDelegateManager|. |
| 555 IDToItemControllerMap id_to_item_controller_map_; | 557 IDToItemControllerMap id_to_item_controller_map_; |
| 556 | 558 |
| 557 // Direct access to app_id for a web contents. | 559 // Direct access to app_id for a web contents. |
| 558 WebContentsToAppIDMap web_contents_to_app_id_; | 560 WebContentsToAppIDMap web_contents_to_app_id_; |
| 559 | 561 |
| 560 // Used to track app windows. | 562 // Used to track app windows. |
| 561 scoped_ptr<AppWindowLauncherController> app_window_controller_; | 563 std::vector<scoped_ptr<AppWindowLauncherController>> app_window_controllers_; |
| 562 | 564 |
| 563 // Used to get app info for tabs. | 565 // Used to get app info for tabs. |
| 564 scoped_ptr<AppTabHelper> app_tab_helper_; | 566 scoped_ptr<AppTabHelper> app_tab_helper_; |
| 565 | 567 |
| 566 // Used to load the image for an extension app item. | 568 // Used to load the image for an extension app item. |
| 567 std::vector<scoped_ptr<AppIconLoader>> app_icon_loaders_; | 569 std::vector<scoped_ptr<AppIconLoader>> app_icon_loaders_; |
| 568 | 570 |
| 569 // Used to handle app load/unload events. | 571 // Used to handle app load/unload events. |
| 570 std::vector<scoped_ptr<LauncherAppUpdater>> app_updaters_; | 572 std::vector<scoped_ptr<LauncherAppUpdater>> app_updaters_; |
| 571 | 573 |
| (...skipping 20 matching lines...) Expand all Loading... | |
| 592 // The list of running & un-pinned applications for different users on hidden | 594 // The list of running & un-pinned applications for different users on hidden |
| 593 // desktops. | 595 // desktops. |
| 594 typedef std::vector<std::string> RunningAppListIds; | 596 typedef std::vector<std::string> RunningAppListIds; |
| 595 typedef std::map<std::string, RunningAppListIds> RunningAppListIdMap; | 597 typedef std::map<std::string, RunningAppListIds> RunningAppListIdMap; |
| 596 RunningAppListIdMap last_used_running_application_order_; | 598 RunningAppListIdMap last_used_running_application_order_; |
| 597 | 599 |
| 598 DISALLOW_COPY_AND_ASSIGN(ChromeLauncherController); | 600 DISALLOW_COPY_AND_ASSIGN(ChromeLauncherController); |
| 599 }; | 601 }; |
| 600 | 602 |
| 601 #endif // CHROME_BROWSER_UI_ASH_LAUNCHER_CHROME_LAUNCHER_CONTROLLER_H_ | 603 #endif // CHROME_BROWSER_UI_ASH_LAUNCHER_CHROME_LAUNCHER_CONTROLLER_H_ |
| OLD | NEW |