| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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_BROWSER_SHORTCUT_LAUNCHER_ITEM_CONTROLLER
_H_ | 5 #ifndef CHROME_BROWSER_UI_ASH_LAUNCHER_BROWSER_SHORTCUT_LAUNCHER_ITEM_CONTROLLER
_H_ |
| 6 #define CHROME_BROWSER_UI_ASH_LAUNCHER_BROWSER_SHORTCUT_LAUNCHER_ITEM_CONTROLLER
_H_ | 6 #define CHROME_BROWSER_UI_ASH_LAUNCHER_BROWSER_SHORTCUT_LAUNCHER_ITEM_CONTROLLER
_H_ |
| 7 | 7 |
| 8 #include "ash/public/cpp/shelf_item_delegate.h" | 8 #include "ash/public/cpp/shelf_item_delegate.h" |
| 9 #include "base/macros.h" | 9 #include "base/macros.h" |
| 10 #include "chrome/browser/ui/browser_list.h" | 10 #include "chrome/browser/ui/browser_list.h" |
| (...skipping 25 matching lines...) Expand all Loading... |
| 36 void SetShelfIDForBrowserWindowContents(Browser* browser, | 36 void SetShelfIDForBrowserWindowContents(Browser* browser, |
| 37 content::WebContents* web_contents); | 37 content::WebContents* web_contents); |
| 38 | 38 |
| 39 // Check if there is any active browsers windows. | 39 // Check if there is any active browsers windows. |
| 40 bool IsListOfActiveBrowserEmpty(); | 40 bool IsListOfActiveBrowserEmpty(); |
| 41 | 41 |
| 42 // ash::ShelfItemDelegate overrides: | 42 // ash::ShelfItemDelegate overrides: |
| 43 void ItemSelected(std::unique_ptr<ui::Event> event, | 43 void ItemSelected(std::unique_ptr<ui::Event> event, |
| 44 int64_t display_id, | 44 int64_t display_id, |
| 45 ash::ShelfLaunchSource source, | 45 ash::ShelfLaunchSource source, |
| 46 const ItemSelectedCallback& callback) override; | 46 ItemSelectedCallback callback) override; |
| 47 ash::MenuItemList GetAppMenuItems(int event_flags) override; | 47 ash::MenuItemList GetAppMenuItems(int event_flags) override; |
| 48 void ExecuteCommand(uint32_t command_id, int32_t event_flags) override; | 48 void ExecuteCommand(uint32_t command_id, int32_t event_flags) override; |
| 49 void Close() override; | 49 void Close() override; |
| 50 | 50 |
| 51 private: | 51 private: |
| 52 // Activate a browser - or advance to the next one on the list. | 52 // Activate a browser - or advance to the next one on the list. |
| 53 // Returns the action performed. Should be one of SHELF_ACTION_NONE, | 53 // Returns the action performed. Should be one of SHELF_ACTION_NONE, |
| 54 // SHELF_ACTION_WINDOW_ACTIVATED, or SHELF_ACTION_NEW_WINDOW_CREATED. | 54 // SHELF_ACTION_WINDOW_ACTIVATED, or SHELF_ACTION_NEW_WINDOW_CREATED. |
| 55 ash::ShelfAction ActivateOrAdvanceToNextBrowser(); | 55 ash::ShelfAction ActivateOrAdvanceToNextBrowser(); |
| 56 | 56 |
| (...skipping 14 matching lines...) Expand all Loading... |
| 71 // The cached list of open browser windows shown in an application menu. | 71 // The cached list of open browser windows shown in an application menu. |
| 72 BrowserList::BrowserVector browser_menu_items_; | 72 BrowserList::BrowserVector browser_menu_items_; |
| 73 | 73 |
| 74 // Registers for notifications of closing browser windows. | 74 // Registers for notifications of closing browser windows. |
| 75 content::NotificationRegistrar registrar_; | 75 content::NotificationRegistrar registrar_; |
| 76 | 76 |
| 77 DISALLOW_COPY_AND_ASSIGN(BrowserShortcutLauncherItemController); | 77 DISALLOW_COPY_AND_ASSIGN(BrowserShortcutLauncherItemController); |
| 78 }; | 78 }; |
| 79 | 79 |
| 80 #endif // CHROME_BROWSER_UI_ASH_LAUNCHER_BROWSER_SHORTCUT_LAUNCHER_ITEM_CONTROL
LER_H_ | 80 #endif // CHROME_BROWSER_UI_ASH_LAUNCHER_BROWSER_SHORTCUT_LAUNCHER_ITEM_CONTROL
LER_H_ |
| OLD | NEW |