| Index: chrome/browser/ui/ash/launcher/chrome_mash_shelf_controller.h
|
| diff --git a/chrome/browser/ui/ash/launcher/chrome_mash_shelf_controller.h b/chrome/browser/ui/ash/launcher/chrome_mash_shelf_controller.h
|
| index b458fa369f8cd021941b7a46f622b98fba340182..198f63d8f513162aedc6fcd247c69654cdcb789b 100644
|
| --- a/chrome/browser/ui/ash/launcher/chrome_mash_shelf_controller.h
|
| +++ b/chrome/browser/ui/ash/launcher/chrome_mash_shelf_controller.h
|
| @@ -8,14 +8,17 @@
|
| #include <map>
|
| #include <memory>
|
| #include <string>
|
| +#include <vector>
|
|
|
| +#include "chrome/browser/ui/app_icon_loader.h"
|
| #include "mash/shelf/public/interfaces/shelf.mojom.h"
|
| #include "mojo/public/cpp/bindings/associated_binding.h"
|
|
|
| class ChromeShelfItemDelegate;
|
|
|
| // ChromeMashShelfController manages chrome's interaction with the mash shelf.
|
| -class ChromeMashShelfController : public mash::shelf::mojom::ShelfObserver {
|
| +class ChromeMashShelfController : public mash::shelf::mojom::ShelfObserver,
|
| + public AppIconLoaderDelegate {
|
| public:
|
| ~ChromeMashShelfController() override;
|
|
|
| @@ -30,11 +33,19 @@ class ChromeMashShelfController : public mash::shelf::mojom::ShelfObserver {
|
|
|
| void Init();
|
|
|
| + void PinAppsFromPrefs();
|
| +
|
| + AppIconLoader* GetAppIconLoaderForApp(const std::string& app_id);
|
| +
|
| // mash::shelf::mojom::ShelfObserver:
|
| void OnAlignmentChanged(mash::shelf::mojom::Alignment alignment) override;
|
| void OnAutoHideBehaviorChanged(
|
| mash::shelf::mojom::AutoHideBehavior auto_hide) override;
|
|
|
| + // AppIconLoaderDelegate:
|
| + void OnAppImageUpdated(const std::string& app_id,
|
| + const gfx::ImageSkia& image) override;
|
| +
|
| static ChromeMashShelfController* instance_;
|
|
|
| mash::shelf::mojom::ShelfControllerPtr shelf_controller_;
|
| @@ -42,6 +53,9 @@ class ChromeMashShelfController : public mash::shelf::mojom::ShelfObserver {
|
| std::map<std::string, std::unique_ptr<ChromeShelfItemDelegate>>
|
| app_id_to_item_delegate_;
|
|
|
| + // Used to load the images for app items.
|
| + std::vector<std::unique_ptr<AppIconLoader>> app_icon_loaders_;
|
| +
|
| DISALLOW_COPY_AND_ASSIGN(ChromeMashShelfController);
|
| };
|
|
|
|
|