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

Unified Diff: chrome/browser/profiles/profile_attributes_entry.cc

Issue 1794353003: Refactor ProfileInfoCache in c/b/profiles (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Reverting a few changes Created 4 years, 9 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: chrome/browser/profiles/profile_attributes_entry.cc
diff --git a/chrome/browser/profiles/profile_attributes_entry.cc b/chrome/browser/profiles/profile_attributes_entry.cc
index 3031322abfa146d812089c064c768bedf572a118..02096540f59df9585791f515f28c62f0361ece88 100644
--- a/chrome/browser/profiles/profile_attributes_entry.cc
+++ b/chrome/browser/profiles/profile_attributes_entry.cc
@@ -176,6 +176,10 @@ void ProfileAttributesEntry::SetShortcutName(const base::string16& name) {
profile_info_cache_->SetShortcutNameOfProfileAtIndex(profile_index(), name);
}
+void ProfileAttributesEntry::SetActiveTimeToNow() {
+ profile_info_cache_->SetProfileActiveTimeAtIndex(profile_index());
+}
+
void ProfileAttributesEntry::SetIsOmitted(bool is_omitted) {
profile_info_cache_->SetIsOmittedProfileAtIndex(profile_index(), is_omitted);
}
@@ -269,6 +273,12 @@ void ProfileAttributesEntry::SetAuthInfo(
profile_index(), gaia_id, user_name);
}
+void ProfileAttributesEntry::SaveAvatarImage(const gfx::Image* image,
+ const std::string& key, const base::FilePath& image_path) {
+ profile_info_cache_->SaveAvatarImageAtPath(image, key, image_path,
+ GetPath());
+}
+
size_t ProfileAttributesEntry::profile_index() const {
size_t index = profile_info_cache_->GetIndexOfProfileWithPath(profile_path_);
DCHECK(index < profile_info_cache_->GetNumberOfProfiles());

Powered by Google App Engine
This is Rietveld 408576698