| 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 371 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. | 382 // Called when the user profile is fully loaded and ready to switch to. |
| 383 void OnUserProfileReadyToSwitch(Profile* profile); | 383 void OnUserProfileReadyToSwitch(Profile* profile); |
| 384 | 384 |
| 385 // Access to the BrowserStatusMonitor for tests. | 385 // Access to the BrowserStatusMonitor for tests. |
| 386 BrowserStatusMonitor* browser_status_monitor_for_test() { | 386 BrowserStatusMonitor* browser_status_monitor_for_test() { |
| 387 return browser_status_monitor_.get(); | 387 return browser_status_monitor_.get(); |
| 388 } | 388 } |
| 389 | 389 |
| 390 // Access to the AppWindowLauncherController for tests. | 390 // Access to the AppWindowLauncherController for tests. |
| 391 AppWindowLauncherController* app_window_controller_for_test() { | 391 AppWindowLauncherController* app_window_controller_for_test() { |
| 392 return app_window_controller_.get(); | 392 return app_window_controllers_[0].get(); |
| 393 } | 393 } |
| 394 | 394 |
| 395 bool CanPin(const std::string& app_id); | 395 bool CanPin(const std::string& app_id); |
| 396 | 396 |
| 397 protected: | 397 protected: |
| 398 // Creates a new app shortcut item and controller on the shelf at |index|. | 398 // Creates a new app shortcut item and controller on the shelf at |index|. |
| 399 // Use kInsertItemAtEnd to add a shortcut as the last item. | 399 // Use kInsertItemAtEnd to add a shortcut as the last item. |
| 400 ash::ShelfID CreateAppShortcutLauncherItem(const std::string& app_id, | 400 ash::ShelfID CreateAppShortcutLauncherItem(const std::string& app_id, |
| 401 int index); | 401 int index); |
| 402 | 402 |
| (...skipping 148 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 551 // profile new windows are created with. | 551 // profile new windows are created with. |
| 552 Profile* profile_; | 552 Profile* profile_; |
| 553 | 553 |
| 554 // Controller items in this map are owned by |ShelfItemDelegateManager|. | 554 // Controller items in this map are owned by |ShelfItemDelegateManager|. |
| 555 IDToItemControllerMap id_to_item_controller_map_; | 555 IDToItemControllerMap id_to_item_controller_map_; |
| 556 | 556 |
| 557 // Direct access to app_id for a web contents. | 557 // Direct access to app_id for a web contents. |
| 558 WebContentsToAppIDMap web_contents_to_app_id_; | 558 WebContentsToAppIDMap web_contents_to_app_id_; |
| 559 | 559 |
| 560 // Used to track app windows. | 560 // Used to track app windows. |
| 561 scoped_ptr<AppWindowLauncherController> app_window_controller_; | 561 std::vector<scoped_ptr<AppWindowLauncherController>> app_window_controllers_; |
| 562 | 562 |
| 563 // Used to get app info for tabs. | 563 // Used to get app info for tabs. |
| 564 scoped_ptr<AppTabHelper> app_tab_helper_; | 564 scoped_ptr<AppTabHelper> app_tab_helper_; |
| 565 | 565 |
| 566 // Used to load the image for an extension app item. | 566 // Used to load the image for an extension app item. |
| 567 std::vector<scoped_ptr<AppIconLoader>> app_icon_loaders_; | 567 std::vector<scoped_ptr<AppIconLoader>> app_icon_loaders_; |
| 568 | 568 |
| 569 // Used to handle app load/unload events. | 569 // Used to handle app load/unload events. |
| 570 std::vector<scoped_ptr<LauncherAppUpdater>> app_updaters_; | 570 std::vector<scoped_ptr<LauncherAppUpdater>> app_updaters_; |
| 571 | 571 |
| (...skipping 20 matching lines...) Expand all Loading... |
| 592 // The list of running & un-pinned applications for different users on hidden | 592 // The list of running & un-pinned applications for different users on hidden |
| 593 // desktops. | 593 // desktops. |
| 594 typedef std::vector<std::string> RunningAppListIds; | 594 typedef std::vector<std::string> RunningAppListIds; |
| 595 typedef std::map<std::string, RunningAppListIds> RunningAppListIdMap; | 595 typedef std::map<std::string, RunningAppListIds> RunningAppListIdMap; |
| 596 RunningAppListIdMap last_used_running_application_order_; | 596 RunningAppListIdMap last_used_running_application_order_; |
| 597 | 597 |
| 598 DISALLOW_COPY_AND_ASSIGN(ChromeLauncherController); | 598 DISALLOW_COPY_AND_ASSIGN(ChromeLauncherController); |
| 599 }; | 599 }; |
| 600 | 600 |
| 601 #endif // CHROME_BROWSER_UI_ASH_LAUNCHER_CHROME_LAUNCHER_CONTROLLER_H_ | 601 #endif // CHROME_BROWSER_UI_ASH_LAUNCHER_CHROME_LAUNCHER_CONTROLLER_H_ |
| OLD | NEW |