| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_APP_WINDOW_LAUNCHER_ITEM_CONTROLLER_H_ | 5 #ifndef CHROME_BROWSER_UI_ASH_LAUNCHER_APP_WINDOW_LAUNCHER_ITEM_CONTROLLER_H_ |
| 6 #define CHROME_BROWSER_UI_ASH_LAUNCHER_APP_WINDOW_LAUNCHER_ITEM_CONTROLLER_H_ | 6 #define CHROME_BROWSER_UI_ASH_LAUNCHER_APP_WINDOW_LAUNCHER_ITEM_CONTROLLER_H_ |
| 7 | 7 |
| 8 #include <list> | 8 #include <list> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 66 | 66 |
| 67 // Activates the window at position |index|. | 67 // Activates the window at position |index|. |
| 68 void ActivateIndexedApp(size_t index); | 68 void ActivateIndexedApp(size_t index); |
| 69 | 69 |
| 70 const WindowList& windows() const { return windows_; } | 70 const WindowList& windows() const { return windows_; } |
| 71 | 71 |
| 72 protected: | 72 protected: |
| 73 AppWindowLauncherItemController(Type type, | 73 AppWindowLauncherItemController(Type type, |
| 74 const std::string& app_id, | 74 const std::string& app_id, |
| 75 const std::string& launch_id, | 75 const std::string& launch_id, |
| 76 const std::string& title, |
| 76 ChromeLauncherController* controller); | 77 ChromeLauncherController* controller); |
| 77 | 78 |
| 78 // Called when app window is removed from controller. | 79 // Called when app window is removed from controller. |
| 79 virtual void OnWindowRemoved(ui::BaseWindow* window) {} | 80 virtual void OnWindowRemoved(ui::BaseWindow* window) {} |
| 80 | 81 |
| 81 // Returns the action performed. Should be one of kNoAction, | 82 // Returns the action performed. Should be one of kNoAction, |
| 82 // kExistingWindowActivated, or kExistingWindowMinimized. | 83 // kExistingWindowActivated, or kExistingWindowMinimized. |
| 83 ash::ShelfItemDelegate::PerformedAction ShowAndActivateOrMinimize( | 84 ash::ShelfItemDelegate::PerformedAction ShowAndActivateOrMinimize( |
| 84 ui::BaseWindow* window); | 85 ui::BaseWindow* window); |
| 85 | 86 |
| (...skipping 13 matching lines...) Expand all Loading... |
| 99 // Pointer to the most recently active app window | 100 // Pointer to the most recently active app window |
| 100 ui::BaseWindow* last_active_window_ = nullptr; | 101 ui::BaseWindow* last_active_window_ = nullptr; |
| 101 | 102 |
| 102 // Scoped list of observed windows (for removal on destruction) | 103 // Scoped list of observed windows (for removal on destruction) |
| 103 ScopedObserver<aura::Window, aura::WindowObserver> observed_windows_; | 104 ScopedObserver<aura::Window, aura::WindowObserver> observed_windows_; |
| 104 | 105 |
| 105 DISALLOW_COPY_AND_ASSIGN(AppWindowLauncherItemController); | 106 DISALLOW_COPY_AND_ASSIGN(AppWindowLauncherItemController); |
| 106 }; | 107 }; |
| 107 | 108 |
| 108 #endif // CHROME_BROWSER_UI_ASH_LAUNCHER_APP_WINDOW_LAUNCHER_ITEM_CONTROLLER_H_ | 109 #endif // CHROME_BROWSER_UI_ASH_LAUNCHER_APP_WINDOW_LAUNCHER_ITEM_CONTROLLER_H_ |
| OLD | NEW |