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: chrome/browser/chromeos/login/user_image.h

Issue 236013002: Apply default wallpaper from customization manifest. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: After-review. 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 CHROME_BROWSER_CHROMEOS_LOGIN_USER_IMAGE_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_USER_IMAGE_H_
6 #define CHROME_BROWSER_CHROMEOS_LOGIN_USER_IMAGE_H_ 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_USER_IMAGE_H_
7 7
8 #include <string>
8 #include <vector> 9 #include <vector>
9 10
10 #include "ui/gfx/image/image_skia.h" 11 #include "ui/gfx/image/image_skia.h"
11 #include "url/gurl.h" 12 #include "url/gurl.h"
12 13
13 namespace chromeos { 14 namespace chromeos {
14 15
15 // Wrapper class storing a still image and it's raw representation. Could be 16 // Wrapper class storing a still image and it's raw representation. Could be
16 // used for storing profile images (including animated profile images) and user 17 // used for storing profile images (including animated profile images) and user
17 // wallpapers. 18 // wallpapers.
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
54 55
55 // URL from which this image was originally downloaded, if any. 56 // URL from which this image was originally downloaded, if any.
56 void set_url(const GURL& url) { url_ = url; } 57 void set_url(const GURL& url) { url_ = url; }
57 GURL url() const { return url_; } 58 GURL url() const { return url_; }
58 59
59 // Whether |raw_image| contains data in format that is considered safe to 60 // Whether |raw_image| contains data in format that is considered safe to
60 // decode in sensitive environment (on Login screen). 61 // decode in sensitive environment (on Login screen).
61 bool is_safe_format() const { return is_safe_format_; } 62 bool is_safe_format() const { return is_safe_format_; }
62 void MarkAsSafe(); 63 void MarkAsSafe();
63 64
65 // If image was loaded from local file, file path is stored here.
Daniel Erat 2014/04/14 15:26:15 move this comment down to the member definition in
Alexander Alekseev 2014/04/15 01:57:16 Done.
66 const std::string& file_path() const { return file_path_; }
67 void set_file_path(const std::string& file_path) { file_path_ = file_path; }
68
64 private: 69 private:
65 gfx::ImageSkia image_; 70 gfx::ImageSkia image_;
66 bool has_raw_image_; 71 bool has_raw_image_;
67 RawImage raw_image_; 72 RawImage raw_image_;
68 bool has_animated_image_; 73 bool has_animated_image_;
69 RawImage animated_image_; 74 RawImage animated_image_;
70 GURL url_; 75 GURL url_;
76 std::string file_path_;
71 bool is_safe_format_; 77 bool is_safe_format_;
72 }; 78 };
73 79
74 } // namespace chromeos 80 } // namespace chromeos
75 81
76 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_USER_IMAGE_H_ 82 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_USER_IMAGE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698