Chromium Code Reviews| 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 ASH_COMMON_SHELF_SHELF_DELEGATE_H_ | 5 #ifndef ASH_COMMON_SHELF_SHELF_DELEGATE_H_ |
| 6 #define ASH_COMMON_SHELF_SHELF_DELEGATE_H_ | 6 #define ASH_COMMON_SHELF_SHELF_DELEGATE_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "ash/ash_export.h" | 10 #include "ash/ash_export.h" |
| (...skipping 22 matching lines...) Expand all Loading... | |
| 33 const std::string& launch_id) = 0; | 33 const std::string& launch_id) = 0; |
| 34 | 34 |
| 35 // Checks whether a mapping exists from the ShelfID |id| to an app id. | 35 // Checks whether a mapping exists from the ShelfID |id| to an app id. |
| 36 virtual bool HasShelfIDToAppIDMapping(ShelfID id) const = 0; | 36 virtual bool HasShelfIDToAppIDMapping(ShelfID id) const = 0; |
| 37 | 37 |
| 38 // Get the application ID for a given shelf ID. | 38 // Get the application ID for a given shelf ID. |
| 39 // |HasShelfIDToAppIDMapping(ShelfID)| should be called first to ensure the | 39 // |HasShelfIDToAppIDMapping(ShelfID)| should be called first to ensure the |
| 40 // ShelfID can be successfully mapped to an app id. | 40 // ShelfID can be successfully mapped to an app id. |
| 41 virtual const std::string& GetAppIDForShelfID(ShelfID id) = 0; | 41 virtual const std::string& GetAppIDForShelfID(ShelfID id) = 0; |
| 42 | 42 |
| 43 // Get the launch ID for a given shelf ID. | |
| 44 virtual const std::string& GetLaunchIDForShelfID(ShelfID id) = 0; | |
|
James Cook
2016/10/21 15:11:03
I don't see any calls to this inside //ash. If it
Andra Paraschiv
2016/10/24 08:26:16
Thank you, James, for the explanation, I moved thi
| |
| 45 | |
| 43 // Pins an app with |app_id| to shelf. A running instance will get pinned. | 46 // Pins an app with |app_id| to shelf. A running instance will get pinned. |
| 44 // In case there is no running instance a new shelf item is created and | 47 // In case there is no running instance a new shelf item is created and |
| 45 // pinned. | 48 // pinned. |
| 46 virtual void PinAppWithID(const std::string& app_id) = 0; | 49 virtual void PinAppWithID(const std::string& app_id) = 0; |
| 47 | 50 |
| 48 // Check if the app with |app_id_| is pinned to the shelf. | 51 // Check if the app with |app_id_| is pinned to the shelf. |
| 49 virtual bool IsAppPinned(const std::string& app_id) = 0; | 52 virtual bool IsAppPinned(const std::string& app_id) = 0; |
| 50 | 53 |
| 51 // Unpins app item with |app_id|. | 54 // Unpins app item with |app_id|. |
| 52 virtual void UnpinAppWithID(const std::string& app_id) = 0; | 55 virtual void UnpinAppWithID(const std::string& app_id) = 0; |
| 53 }; | 56 }; |
| 54 | 57 |
| 55 } // namespace ash | 58 } // namespace ash |
| 56 | 59 |
| 57 #endif // ASH_COMMON_SHELF_SHELF_DELEGATE_H_ | 60 #endif // ASH_COMMON_SHELF_SHELF_DELEGATE_H_ |
| OLD | NEW |