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

Unified Diff: chrome/browser/profiles/profile_downloader.h

Issue 8742009: Cache GAIA profile picture URL (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 1 month 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/profiles/profile_downloader.h
diff --git a/chrome/browser/profiles/profile_downloader.h b/chrome/browser/profiles/profile_downloader.h
index 6f4d1ec5f6f264ac529e9e6edfa5a8bc3be09c87..424016001232f4a342782ca87bc0762c5ddf2e37 100644
--- a/chrome/browser/profiles/profile_downloader.h
+++ b/chrome/browser/profiles/profile_downloader.h
@@ -26,6 +26,13 @@ class ProfileDownloader : public content::URLFetcherDelegate,
public ImageDecoder::Delegate,
public content::NotificationObserver {
public:
+ enum PictureResult {
Ivan Korotkov 2011/11/30 14:35:44 [here and in other names] "picture result" sounds
sail 2011/11/30 19:00:23 Done. Changed to PictureStatus
+ PICTURE_SUCCESS,
+ PICTURE_FAILED,
+ PICTURE_DEFAULT,
+ PICTURE_CACHED,
+ };
+
explicit ProfileDownloader(ProfileDownloaderDelegate* delegate);
virtual ~ProfileDownloader();
@@ -43,6 +50,12 @@ class ProfileDownloader : public content::URLFetcherDelegate,
// profile picture) this will return an Null bitmap.
virtual SkBitmap GetProfilePicture() const;
+ // Gets the profile picture result.
+ virtual PictureResult GetProfilePictureResult() const;
+
+ // Gets the URL for the profile picture.
Ivan Korotkov 2011/11/30 14:35:44 Please document when (for which values of PictureR
sail 2011/11/30 19:00:23 Done.
+ virtual std::string GetProfilePictureURL() const;
+
private:
// Overriden from content::URLFetcherDelegate:
virtual void OnURLFetchComplete(const content::URLFetcher* source) OVERRIDE;
@@ -76,6 +89,8 @@ class ProfileDownloader : public content::URLFetcherDelegate,
content::NotificationRegistrar registrar_;
string16 profile_full_name_;
SkBitmap profile_picture_;
+ PictureResult picture_result_;
+ std::string picture_url_;
DISALLOW_COPY_AND_ASSIGN(ProfileDownloader);
};

Powered by Google App Engine
This is Rietveld 408576698