Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(408)

Unified Diff: chrome/browser/chromeos/arc/arc_wallpaper_service.h

Issue 2345153002: cheets: add wallpaper observer to arc_wallpaper_service. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: change null check in ~ArcWallpaperService(), modified instance version check / null check to follow… Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/chromeos/arc/arc_wallpaper_service.h
diff --git a/chrome/browser/chromeos/arc/arc_wallpaper_service.h b/chrome/browser/chromeos/arc/arc_wallpaper_service.h
index 4cf806d6b8622e9fd5a467cc9bb0e7f924a56c25..d05d4193921d2eccdc55f1a5b7d796321f7a6158 100644
--- a/chrome/browser/chromeos/arc/arc_wallpaper_service.h
+++ b/chrome/browser/chromeos/arc/arc_wallpaper_service.h
@@ -11,6 +11,7 @@
#include <set>
#include <vector>
+#include "ash/common/wallpaper/wallpaper_controller_observer.h"
#include "base/macros.h"
#include "chrome/browser/image_decoder.h"
#include "components/arc/arc_service.h"
@@ -25,6 +26,7 @@ namespace arc {
// Lives on the UI thread.
class ArcWallpaperService
: public ArcService,
+ public ash::WallpaperControllerObserver,
public ImageDecoder::ImageRequest,
public InstanceHolder<mojom::WallpaperInstance>::Observer,
public mojom::WallpaperHost {
@@ -45,7 +47,12 @@ class ArcWallpaperService
void OnImageDecoded(const SkBitmap& bitmap) override;
void OnDecodeImageFailed() override;
+ // WallpaperControllerObserver implementation.
+ void OnWallpaperDataChanged() override;
+
private:
+ mojom::WallpaperInstance* GetWallpaperInstance(uint32_t min_version);
+
mojo::Binding<mojom::WallpaperHost> binding_;
DISALLOW_COPY_AND_ASSIGN(ArcWallpaperService);
};

Powered by Google App Engine
This is Rietveld 408576698