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

Unified Diff: chrome/browser/profile.cc

Issue 255087: Adding a unique runtime Id to Profile objects, that can be used as the key... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 11 years, 2 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
« no previous file with comments | « chrome/browser/profile.h ('k') | chrome/test/testing_profile.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/profile.cc
===================================================================
--- chrome/browser/profile.cc (revision 28102)
+++ chrome/browser/profile.cc (working copy)
@@ -147,6 +147,9 @@
}
// static
+const ProfileId Profile::InvalidProfileId = static_cast<ProfileId>(0);
+
+// static
void Profile::RegisterUserPrefs(PrefService* prefs) {
prefs->RegisterBooleanPref(prefs::kSearchSuggestEnabled, true);
prefs->RegisterBooleanPref(prefs::kSessionExitedCleanly, true);
@@ -227,6 +230,10 @@
CleanupAppCacheService(appcache_service_);
}
+ virtual ProfileId GetRuntimeId() {
+ return reinterpret_cast<ProfileId>(this);
+ }
+
virtual FilePath GetPath() { return profile_->GetPath(); }
virtual bool IsOffTheRecord() {
@@ -798,6 +805,10 @@
MarkAsCleanShutdown();
}
+ProfileId ProfileImpl::GetRuntimeId() {
+ return reinterpret_cast<ProfileId>(this);
+}
+
FilePath ProfileImpl::GetPath() {
return path_;
}
« no previous file with comments | « chrome/browser/profile.h ('k') | chrome/test/testing_profile.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698