Index: chrome/browser/browser.cc |
=================================================================== |
--- chrome/browser/browser.cc (revision 10203) |
+++ chrome/browser/browser.cc (working copy) |
@@ -637,6 +637,9 @@ |
void Browser::NewProfileWindowByIndex(int index) { |
#if defined(OS_WIN) |
+ const CommandLine& command_line = *CommandLine::ForCurrentProcess(); |
+ if (!command_line.HasSwitch(switches::kEnableUserDataDirProfiles)) |
+ return; |
UserMetrics::RecordAction(L"NewProfileWindowByIndex", profile_); |
UserDataManager::Get()->LaunchChromeForProfile(index); |
#endif |
@@ -943,6 +946,9 @@ |
} |
void Browser::OpenNewProfileDialog() { |
+ const CommandLine& command_line = *CommandLine::ForCurrentProcess(); |
+ if (!command_line.HasSwitch(switches::kEnableUserDataDirProfiles)) |
+ return; |
UserMetrics::RecordAction(L"CreateProfile", profile_); |
window_->ShowNewProfileDialog(); |
} |