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

Unified Diff: chrome/browser/ui/startup/startup_browser_creator.cc

Issue 500333002: Respect --profile-directory flag when used with --show-app-list flag. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 4 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/startup/startup_browser_creator.cc
diff --git a/chrome/browser/ui/startup/startup_browser_creator.cc b/chrome/browser/ui/startup/startup_browser_creator.cc
index 63de3347cb20e9bb34581ce37fe02de43e796c9f..d9f9712d1ac858118cac442e748c3b5268627fec 100644
--- a/chrome/browser/ui/startup/startup_browser_creator.cc
+++ b/chrome/browser/ui/startup/startup_browser_creator.cc
@@ -728,6 +728,11 @@ bool HasPendingUncleanExit(Profile* profile) {
base::FilePath GetStartupProfilePath(const base::FilePath& user_data_dir,
const CommandLine& command_line) {
+ if (command_line.HasSwitch(switches::kProfileDirectory)) {
+ return user_data_dir.Append(
+ command_line.GetSwitchValuePath(switches::kProfileDirectory));
+ }
+
// If we are showing the app list then chrome isn't shown so load the app
// list's profile rather than chrome's.
if (command_line.HasSwitch(switches::kShowAppList)) {
@@ -735,11 +740,6 @@ base::FilePath GetStartupProfilePath(const base::FilePath& user_data_dir,
GetProfilePath(user_data_dir);
}
- if (command_line.HasSwitch(switches::kProfileDirectory)) {
- return user_data_dir.Append(
- command_line.GetSwitchValuePath(switches::kProfileDirectory));
- }
-
return g_browser_process->profile_manager()->GetLastUsedProfileDir(
user_data_dir);
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698