| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 COMPONENTS_WALLPAPER_WALLPAPER_MANAGER_BASE_H_ | 5 #ifndef COMPONENTS_WALLPAPER_WALLPAPER_MANAGER_BASE_H_ |
| 6 #define COMPONENTS_WALLPAPER_WALLPAPER_MANAGER_BASE_H_ | 6 #define COMPONENTS_WALLPAPER_WALLPAPER_MANAGER_BASE_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 | 9 |
| 10 #include <deque> | 10 #include <deque> |
| (...skipping 341 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 352 const GURL& wallpaper_url, | 352 const GURL& wallpaper_url, |
| 353 const base::FilePath& downloaded_file, | 353 const base::FilePath& downloaded_file, |
| 354 const base::FilePath& resized_directory); | 354 const base::FilePath& resized_directory); |
| 355 | 355 |
| 356 // Returns queue size. | 356 // Returns queue size. |
| 357 virtual size_t GetPendingListSizeForTesting() const = 0; | 357 virtual size_t GetPendingListSizeForTesting() const = 0; |
| 358 | 358 |
| 359 // Ruturns files identifier for the |account_id|. | 359 // Ruturns files identifier for the |account_id|. |
| 360 virtual WallpaperFilesId GetFilesId(const AccountId& account_id) const = 0; | 360 virtual WallpaperFilesId GetFilesId(const AccountId& account_id) const = 0; |
| 361 | 361 |
| 362 // If the device is enterprise managed and we're at the login screen, set the | 362 // If the device is enterprise managed and the device wallpaper policy exists, |
| 363 // device wallpaper as the login screen wallpaper. If the device is enterprise | 363 // set the device wallpaper as the login screen wallpaper. |
| 364 // managed and we're in a user session, only set the device wallpaper if there | |
| 365 // is no user policy wallpaper and the user hasn't changed the default or the | |
| 366 // device wallpaper. Returns true if the device wallpaper should be set as the | |
| 367 // wallpaper, otherwise returns false. | |
| 368 virtual bool SetDeviceWallpaperIfApplicable(const AccountId& account_id) = 0; | 364 virtual bool SetDeviceWallpaperIfApplicable(const AccountId& account_id) = 0; |
| 369 | 365 |
| 370 protected: | 366 protected: |
| 371 friend class TestApi; | 367 friend class TestApi; |
| 372 friend class WallpaperManagerBrowserTest; | 368 friend class WallpaperManagerBrowserTest; |
| 373 friend class WallpaperManagerBrowserTestDefaultWallpaper; | 369 friend class WallpaperManagerBrowserTestDefaultWallpaper; |
| 374 friend class WallpaperManagerPolicyTest; | 370 friend class WallpaperManagerPolicyTest; |
| 375 | 371 |
| 376 // The |CustomWallpaperElement| contains |first| the path of the image which | 372 // The |CustomWallpaperElement| contains |first| the path of the image which |
| 377 // is currently being loaded and or in progress of being loaded and |second| | 373 // is currently being loaded and or in progress of being loaded and |second| |
| (...skipping 258 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 636 | 632 |
| 637 base::WeakPtrFactory<WallpaperManagerBase> weak_factory_; | 633 base::WeakPtrFactory<WallpaperManagerBase> weak_factory_; |
| 638 | 634 |
| 639 private: | 635 private: |
| 640 DISALLOW_COPY_AND_ASSIGN(WallpaperManagerBase); | 636 DISALLOW_COPY_AND_ASSIGN(WallpaperManagerBase); |
| 641 }; | 637 }; |
| 642 | 638 |
| 643 } // namespace wallpaper | 639 } // namespace wallpaper |
| 644 | 640 |
| 645 #endif // COMPONENTS_WALLPAPER_WALLPAPER_MANAGER_BASE_H_ | 641 #endif // COMPONENTS_WALLPAPER_WALLPAPER_MANAGER_BASE_H_ |
| OLD | NEW |