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 ASH_LAUNCHER_LAUNCHER_DELEGATE_H_ | 5 #ifndef ASH_LAUNCHER_LAUNCHER_DELEGATE_H_ |
6 #define ASH_LAUNCHER_LAUNCHER_DELEGATE_H_ | 6 #define ASH_LAUNCHER_LAUNCHER_DELEGATE_H_ |
7 | 7 |
8 #include "ash/ash_export.h" | 8 #include "ash/ash_export.h" |
9 #include "ash/launcher/launcher_types.h" | 9 #include "ash/launcher/launcher_types.h" |
10 | 10 |
(...skipping 27 matching lines...) Expand all Loading... |
38 virtual const std::string& GetAppIDForLauncherID(LauncherID id) = 0; | 38 virtual const std::string& GetAppIDForLauncherID(LauncherID id) = 0; |
39 | 39 |
40 // Pins an app with |app_id| to launcher. A running instance will get pinned. | 40 // Pins an app with |app_id| to launcher. A running instance will get pinned. |
41 // In case there is no running instance a new launcher item is created and | 41 // In case there is no running instance a new launcher item is created and |
42 // pinned. | 42 // pinned. |
43 virtual void PinAppWithID(const std::string& app_id) = 0; | 43 virtual void PinAppWithID(const std::string& app_id) = 0; |
44 | 44 |
45 // Check if the app with |app_id_| is pinned to the launcher. | 45 // Check if the app with |app_id_| is pinned to the launcher. |
46 virtual bool IsAppPinned(const std::string& app_id) = 0; | 46 virtual bool IsAppPinned(const std::string& app_id) = 0; |
47 | 47 |
| 48 // Checks whether the user is allowed to pin/unpin apps. Pinning may be |
| 49 // disallowed by policy in case there is a pre-defined set of pinned apps. |
| 50 virtual bool CanPin() const = 0; |
| 51 |
48 // Unpins app item with |app_id|. | 52 // Unpins app item with |app_id|. |
49 virtual void UnpinAppWithID(const std::string& app_id) = 0; | 53 virtual void UnpinAppWithID(const std::string& app_id) = 0; |
50 }; | 54 }; |
51 | 55 |
52 } // namespace ash | 56 } // namespace ash |
53 | 57 |
54 #endif // ASH_LAUNCHER_LAUNCHER_DELEGATE_H_ | 58 #endif // ASH_LAUNCHER_LAUNCHER_DELEGATE_H_ |
OLD | NEW |