diff options
author | davemoore@chromium.org <davemoore@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-11-30 21:18:51 +0000 |
---|---|---|
committer | davemoore@chromium.org <davemoore@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-11-30 21:18:51 +0000 |
commit | 9acc48601ea4aff4e5ec977c0dd089e887ba5ffd (patch) | |
tree | 9c0ef6715ab756b6c8eafb5f4385eaab73a3a8ab /chrome/browser/profile.cc | |
parent | 8d7690b29c0572c62bbe72817ac3b5195bf38e42 (diff) | |
download | chromium_src-9acc48601ea4aff4e5ec977c0dd089e887ba5ffd.zip chromium_src-9acc48601ea4aff4e5ec977c0dd089e887ba5ffd.tar.gz chromium_src-9acc48601ea4aff4e5ec977c0dd089e887ba5ffd.tar.bz2 |
Add -profile command line switch
Review URL: http://codereview.chromium.org/384062
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@33335 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/profile.cc')
-rw-r--r-- | chrome/browser/profile.cc | 43 |
1 files changed, 2 insertions, 41 deletions
diff --git a/chrome/browser/profile.cc b/chrome/browser/profile.cc index 7f6c3f0..2db89ac 100644 --- a/chrome/browser/profile.cc +++ b/chrome/browser/profile.cc @@ -14,6 +14,7 @@ #include "chrome/browser/autofill/personal_data_manager.h" #include "chrome/browser/bookmarks/bookmark_model.h" #include "chrome/browser/browser_list.h" +#include "chrome/browser/browser_prefs.h" #include "chrome/browser/browser_process.h" #include "chrome/browser/browser_theme_provider.h" #include "chrome/browser/chrome_thread.h" @@ -63,10 +64,6 @@ #include "chrome/browser/gtk/gtk_theme_provider.h" #endif -#if defined(OS_CHROMEOS) -#include "chrome/browser/chromeos/preferences.h" -#endif - using base::Time; using base::TimeDelta; @@ -423,22 +420,6 @@ class OffTheRecordProfileImpl : public Profile, return false; } - virtual std::wstring GetName() { - return profile_->GetName(); - } - - virtual void SetName(const std::wstring& name) { - profile_->SetName(name); - } - - virtual std::wstring GetID() { - return profile_->GetID(); - } - - virtual void SetID(const std::wstring& id) { - profile_->SetID(id); - } - virtual bool DidLastSessionExitCleanly() { return profile_->DidLastSessionExitCleanly(); } @@ -861,13 +842,7 @@ PrefService* ProfileImpl::GetPrefs() { // The Profile class and ProfileManager class may read some prefs so // register known prefs as soon as possible. Profile::RegisterUserPrefs(prefs_.get()); - ProfileManager::RegisterUserPrefs(prefs_.get()); -#if defined(OS_CHROMEOS) - // Register Touchpad prefs here instead of in browser_prefs because these - // prefs are used in the constructor of ProfileImpl which happens before - // browser_prefs' RegisterAllPrefs is called. - chromeos::Preferences::RegisterUserPrefs(prefs_.get()); -#endif + browser::RegisterUserPrefs(prefs_.get()); // The last session exited cleanly if there is no pref for // kSessionExitedCleanly or the value for kSessionExitedCleanly is true. @@ -1160,20 +1135,6 @@ bool ProfileImpl::HasSessionService() const { return (session_service_.get() != NULL); } -std::wstring ProfileImpl::GetName() { - return GetPrefs()->GetString(prefs::kProfileName); -} -void ProfileImpl::SetName(const std::wstring& name) { - GetPrefs()->SetString(prefs::kProfileName, name); -} - -std::wstring ProfileImpl::GetID() { - return GetPrefs()->GetString(prefs::kProfileID); -} -void ProfileImpl::SetID(const std::wstring& id) { - GetPrefs()->SetString(prefs::kProfileID, id); -} - bool ProfileImpl::DidLastSessionExitCleanly() { // last_session_exited_cleanly_ is set when the preferences are loaded. Force // it to be set by asking for the prefs. |