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

Side by Side Diff: components/wallpaper/wallpaper_manager_base.h

Issue 1794323003: Make user_manager::UserImage non-copyable (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: just rebase Created 4 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 unified diff | Download patch
OLDNEW
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 458 matching lines...) Expand 10 before | Expand all | Expand 10 after
469 WallpaperInfo* info) const = 0; 469 WallpaperInfo* info) const = 0;
470 470
471 // Sets wallpaper to the decoded wallpaper if |update_wallpaper| is true. 471 // Sets wallpaper to the decoded wallpaper if |update_wallpaper| is true.
472 // Otherwise, cache wallpaper to memory if not logged in. (Takes a UserImage 472 // Otherwise, cache wallpaper to memory if not logged in. (Takes a UserImage
473 // because that's the callback interface provided by UserImageLoader.) 473 // because that's the callback interface provided by UserImageLoader.)
474 virtual void OnWallpaperDecoded( 474 virtual void OnWallpaperDecoded(
475 const AccountId& account_id, 475 const AccountId& account_id,
476 WallpaperLayout layout, 476 WallpaperLayout layout,
477 bool update_wallpaper, 477 bool update_wallpaper,
478 MovableOnDestroyCallbackHolder on_finish, 478 MovableOnDestroyCallbackHolder on_finish,
479 const user_manager::UserImage& user_image) = 0; 479 scoped_ptr<user_manager::UserImage> user_image) = 0;
480 480
481 // Creates new PendingWallpaper request (or updates currently pending). 481 // Creates new PendingWallpaper request (or updates currently pending).
482 virtual void ScheduleSetUserWallpaper(const AccountId& account_id, 482 virtual void ScheduleSetUserWallpaper(const AccountId& account_id,
483 bool delayed) = 0; 483 bool delayed) = 0;
484 484
485 // Sets wallpaper to default. 485 // Sets wallpaper to default.
486 virtual void DoSetDefaultWallpaper( 486 virtual void DoSetDefaultWallpaper(
487 const AccountId& account_id, 487 const AccountId& account_id,
488 MovableOnDestroyCallbackHolder on_finish) = 0; 488 MovableOnDestroyCallbackHolder on_finish) = 0;
489 489
(...skipping 21 matching lines...) Expand all
511 // This is called after we check that supplied default wallpaper files exist. 511 // This is called after we check that supplied default wallpaper files exist.
512 virtual void SetCustomizedDefaultWallpaperAfterCheck( 512 virtual void SetCustomizedDefaultWallpaperAfterCheck(
513 const GURL& wallpaper_url, 513 const GURL& wallpaper_url,
514 const base::FilePath& downloaded_file, 514 const base::FilePath& downloaded_file,
515 scoped_ptr<CustomizedWallpaperRescaledFiles> rescaled_files) = 0; 515 scoped_ptr<CustomizedWallpaperRescaledFiles> rescaled_files) = 0;
516 516
517 // Starts rescaling of customized wallpaper. 517 // Starts rescaling of customized wallpaper.
518 virtual void OnCustomizedDefaultWallpaperDecoded( 518 virtual void OnCustomizedDefaultWallpaperDecoded(
519 const GURL& wallpaper_url, 519 const GURL& wallpaper_url,
520 scoped_ptr<CustomizedWallpaperRescaledFiles> rescaled_files, 520 scoped_ptr<CustomizedWallpaperRescaledFiles> rescaled_files,
521 const user_manager::UserImage& user_image); 521 scoped_ptr<user_manager::UserImage> user_image);
522 522
523 // Check the result of ResizeCustomizedDefaultWallpaper and finally 523 // Check the result of ResizeCustomizedDefaultWallpaper and finally
524 // apply Customized Default Wallpaper. 524 // apply Customized Default Wallpaper.
525 virtual void OnCustomizedDefaultWallpaperResized( 525 virtual void OnCustomizedDefaultWallpaperResized(
526 const GURL& wallpaper_url, 526 const GURL& wallpaper_url,
527 scoped_ptr<CustomizedWallpaperRescaledFiles> rescaled_files, 527 scoped_ptr<CustomizedWallpaperRescaledFiles> rescaled_files,
528 scoped_ptr<bool> success, 528 scoped_ptr<bool> success,
529 scoped_ptr<gfx::ImageSkia> small_wallpaper_image, 529 scoped_ptr<gfx::ImageSkia> small_wallpaper_image,
530 scoped_ptr<gfx::ImageSkia> large_wallpaper_image) = 0; 530 scoped_ptr<gfx::ImageSkia> large_wallpaper_image) = 0;
531 531
532 // Init |*default_*_wallpaper_file_| from given command line and 532 // Init |*default_*_wallpaper_file_| from given command line and
533 // clear |default_wallpaper_image_|. 533 // clear |default_wallpaper_image_|.
534 virtual void SetDefaultWallpaperPathsFromCommandLine( 534 virtual void SetDefaultWallpaperPathsFromCommandLine(
535 base::CommandLine* command_line) = 0; 535 base::CommandLine* command_line) = 0;
536 536
537 // Sets wallpaper to decoded default. 537 // Sets wallpaper to decoded default.
538 virtual void OnDefaultWallpaperDecoded( 538 virtual void OnDefaultWallpaperDecoded(
539 const base::FilePath& path, 539 const base::FilePath& path,
540 const WallpaperLayout layout, 540 const WallpaperLayout layout,
541 scoped_ptr<user_manager::UserImage>* result, 541 scoped_ptr<user_manager::UserImage>* result,
542 MovableOnDestroyCallbackHolder on_finish, 542 MovableOnDestroyCallbackHolder on_finish,
543 const user_manager::UserImage& user_image) = 0; 543 scoped_ptr<user_manager::UserImage> user_image) = 0;
544 544
545 // Start decoding given default wallpaper. 545 // Start decoding given default wallpaper.
546 virtual void StartLoadAndSetDefaultWallpaper( 546 virtual void StartLoadAndSetDefaultWallpaper(
547 const base::FilePath& path, 547 const base::FilePath& path,
548 const WallpaperLayout layout, 548 const WallpaperLayout layout,
549 MovableOnDestroyCallbackHolder on_finish, 549 MovableOnDestroyCallbackHolder on_finish,
550 scoped_ptr<user_manager::UserImage>* result_out) = 0; 550 scoped_ptr<user_manager::UserImage>* result_out) = 0;
551 551
552 // Returns wallpaper subdirectory name for current resolution. 552 // Returns wallpaper subdirectory name for current resolution.
553 virtual const char* GetCustomWallpaperSubdirForCurrentResolution(); 553 virtual const char* GetCustomWallpaperSubdirForCurrentResolution();
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
604 604
605 base::WeakPtrFactory<WallpaperManagerBase> weak_factory_; 605 base::WeakPtrFactory<WallpaperManagerBase> weak_factory_;
606 606
607 private: 607 private:
608 DISALLOW_COPY_AND_ASSIGN(WallpaperManagerBase); 608 DISALLOW_COPY_AND_ASSIGN(WallpaperManagerBase);
609 }; 609 };
610 610
611 } // namespace wallpaper 611 } // namespace wallpaper
612 612
613 #endif // COMPONENTS_WALLPAPER_WALLPAPER_MANAGER_BASE_H_ 613 #endif // COMPONENTS_WALLPAPER_WALLPAPER_MANAGER_BASE_H_
OLDNEW
« no previous file with comments | « components/user_manager/user_image/user_image.cc ('k') | components/wallpaper/wallpaper_manager_base.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698