| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_VIEWS_ASH_LAUNCHER_CHROME_LAUNCHER_CONTROLLER_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_ASH_LAUNCHER_CHROME_LAUNCHER_CONTROLLER_H_ |
| 6 #define CHROME_BROWSER_UI_VIEWS_ASH_LAUNCHER_CHROME_LAUNCHER_CONTROLLER_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_ASH_LAUNCHER_CHROME_LAUNCHER_CONTROLLER_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <list> | 9 #include <list> |
| 10 #include <map> | 10 #include <map> |
| (...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 146 // Returns the launch type of app for the specified id. | 146 // Returns the launch type of app for the specified id. |
| 147 ExtensionPrefs::LaunchType GetLaunchType(ash::LauncherID id); | 147 ExtensionPrefs::LaunchType GetLaunchType(ash::LauncherID id); |
| 148 | 148 |
| 149 // Returns the id of the app for the specified tab. | 149 // Returns the id of the app for the specified tab. |
| 150 std::string GetAppID(TabContents* tab); | 150 std::string GetAppID(TabContents* tab); |
| 151 | 151 |
| 152 ash::LauncherID GetLauncherIDForAppID(const std::string& app_id); | 152 ash::LauncherID GetLauncherIDForAppID(const std::string& app_id); |
| 153 | 153 |
| 154 // Sets the image for an app tab. This is intended to be invoked from the | 154 // Sets the image for an app tab. This is intended to be invoked from the |
| 155 // AppIconLoader. | 155 // AppIconLoader. |
| 156 void SetAppImage(const std::string& app_id, const SkBitmap* image); | 156 void SetAppImage(const std::string& app_id, const gfx::ImageSkia& image); |
| 157 | 157 |
| 158 // Returns true if a pinned launcher item with given |app_id| could be found. | 158 // Returns true if a pinned launcher item with given |app_id| could be found. |
| 159 bool IsAppPinned(const std::string& app_id); | 159 bool IsAppPinned(const std::string& app_id); |
| 160 | 160 |
| 161 // Pins an app with |app_id| to launcher. If there is a running instance in | 161 // Pins an app with |app_id| to launcher. If there is a running instance in |
| 162 // launcher, the running instance is pinned. If there is no running instance, | 162 // launcher, the running instance is pinned. If there is no running instance, |
| 163 // a new launcher item is created and pinned. | 163 // a new launcher item is created and pinned. |
| 164 void PinAppWithID(const std::string& app_id); | 164 void PinAppWithID(const std::string& app_id); |
| 165 | 165 |
| 166 // Updates the launche type of the app for the specified id to |launch_type|. | 166 // Updates the launche type of the app for the specified id to |launch_type|. |
| (...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 330 | 330 |
| 331 content::NotificationRegistrar notification_registrar_; | 331 content::NotificationRegistrar notification_registrar_; |
| 332 | 332 |
| 333 PrefChangeRegistrar pref_change_registrar_; | 333 PrefChangeRegistrar pref_change_registrar_; |
| 334 aura::client::ActivationClient* activation_client_; | 334 aura::client::ActivationClient* activation_client_; |
| 335 | 335 |
| 336 DISALLOW_COPY_AND_ASSIGN(ChromeLauncherController); | 336 DISALLOW_COPY_AND_ASSIGN(ChromeLauncherController); |
| 337 }; | 337 }; |
| 338 | 338 |
| 339 #endif // CHROME_BROWSER_UI_VIEWS_ASH_LAUNCHER_CHROME_LAUNCHER_CONTROLLER_H_ | 339 #endif // CHROME_BROWSER_UI_VIEWS_ASH_LAUNCHER_CHROME_LAUNCHER_CONTROLLER_H_ |
| OLD | NEW |