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

Unified Diff: ash/desktop_background/desktop_background_controller.h

Issue 236013002: Apply default wallpaper from customization manifest. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove wallpaper URL from ServicesCustomizationDocumentTest. Created 6 years, 8 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: ash/desktop_background/desktop_background_controller.h
diff --git a/ash/desktop_background/desktop_background_controller.h b/ash/desktop_background/desktop_background_controller.h
index b1099c619f75f30bf21b60536d9e5c552567f318..8d9f698b8f8e816e124e280961a6dc1db7ee6774 100644
--- a/ash/desktop_background/desktop_background_controller.h
+++ b/ash/desktop_background/desktop_background_controller.h
@@ -37,7 +37,7 @@ enum WallpaperLayout {
// desktop's size.
WALLPAPER_LAYOUT_STRETCH,
// Tile the wallpaper over the background without scaling it.
- WALLPAPER_LAYOUT_TILE,
+ WALLPAPER_LAYOUT_TILE
};
const SkColor kLoginWallpaperColor = 0xFEFEFE;
@@ -57,6 +57,10 @@ class ASH_EXPORT DesktopBackgroundController
BACKGROUND_IMAGE,
};
+ // This is used to initialize Resource ID variables and to denote "no
+ // resource ID" in parameters.
+ static const int kInvalidResourceID;
+
DesktopBackgroundController();
virtual ~DesktopBackgroundController();
@@ -110,18 +114,20 @@ class ASH_EXPORT DesktopBackgroundController
// maximum width of all displays, and the maximum height of all displays.
static gfx::Size GetMaxDisplaySizeInNative();
- private:
- friend class DesktopBackgroundControllerTest;
- // friend class chromeos::WallpaperManagerBrowserTestDefaultWallpaper;
- FRIEND_TEST_ALL_PREFIXES(DesktopBackgroundControllerTest, GetMaxDisplaySize);
-
// Returns true if the specified wallpaper is already stored
// in |current_wallpaper_|.
// If |image| is NULL, resource_id is compared.
+ // If |compare_layouts| is false, layout is ignored.
bool WallpaperIsAlreadyLoaded(const gfx::ImageSkia* image,
int resource_id,
+ bool compare_layouts,
WallpaperLayout layout) const;
+ private:
+ friend class DesktopBackgroundControllerTest;
+ // friend class chromeos::WallpaperManagerBrowserTestDefaultWallpaper;
+ FRIEND_TEST_ALL_PREFIXES(DesktopBackgroundControllerTest, GetMaxDisplaySize);
+
// Creates view for all root windows, or notifies them to repaint if they
// already exist.
void SetDesktopBackgroundImageMode();

Powered by Google App Engine
This is Rietveld 408576698