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

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

Issue 8898025: Extend --load-extension commandline to accept multiple (comma-separated) extensions. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years 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/profiles/profile_impl.cc
diff --git a/chrome/browser/profiles/profile_impl.cc b/chrome/browser/profiles/profile_impl.cc
index 6574cd7c78e7b50247fd641e1eff7f01cf7a2209..a5f3701ea03993762d6453aad563a328bc54fdb3 100644
--- a/chrome/browser/profiles/profile_impl.cc
+++ b/chrome/browser/profiles/profile_impl.cc
@@ -463,10 +463,15 @@ void ProfileImpl::InitExtensions(bool extensions_enabled) {
// Load any extensions specified with --load-extension.
// TODO(yoz): Seems like this should move into ExtensionService::Init.
if (command_line->HasSwitch(switches::kLoadExtension)) {
- FilePath path = command_line->GetSwitchValuePath(
+ CommandLine::StringType path_list = command_line->GetSwitchValueNative(
switches::kLoadExtension);
- extensions::UnpackedInstaller::Create(extension_service_.get())->
- LoadFromCommandLine(path);
+ StringTokenizerT<CommandLine::StringType,
+ CommandLine::StringType::const_iterator> t(path_list,
+ FILE_PATH_LITERAL(","));
asargent_no_longer_on_chrome 2011/12/14 00:37:45 I guess if people have commas in their filenames t
jvoung - send to chromium... 2011/12/14 03:00:43 Yeah, I'm not sure what would be a better characte
+ while (t.GetNext()) {
+ extensions::UnpackedInstaller::Create(extension_service_.get())->
Aaron Boodman 2011/12/14 00:30:44 You could create one instance above the beginning
jvoung - send to chromium... 2011/12/14 03:00:43 Done.
+ LoadFromCommandLine(FilePath(t.token()));
+ }
}
}
« 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