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

Side by Side Diff: chrome/browser/extensions/extension_system_impl.cc

Issue 2181393002: Revert of Restrict use of two app-launching command line flags (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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 unified diff | Download patch
« no previous file with comments | « apps/load_and_launch_browsertest.cc ('k') | chrome/browser/extensions/unpacked_installer.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/extensions/extension_system_impl.h" 5 #include "chrome/browser/extensions/extension_system_impl.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/base_switches.h" 9 #include "base/base_switches.h"
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 257 matching lines...) Expand 10 before | Expand all | Expand 10 after
268 // TODO(yoz): Seems like this should move into ExtensionService::Init. 268 // TODO(yoz): Seems like this should move into ExtensionService::Init.
269 // But maybe it's no longer important. 269 // But maybe it's no longer important.
270 if (command_line->HasSwitch(switches::kLoadExtension)) { 270 if (command_line->HasSwitch(switches::kLoadExtension)) {
271 base::CommandLine::StringType path_list = 271 base::CommandLine::StringType path_list =
272 command_line->GetSwitchValueNative(switches::kLoadExtension); 272 command_line->GetSwitchValueNative(switches::kLoadExtension);
273 base::StringTokenizerT<base::CommandLine::StringType, 273 base::StringTokenizerT<base::CommandLine::StringType,
274 base::CommandLine::StringType::const_iterator> 274 base::CommandLine::StringType::const_iterator>
275 t(path_list, FILE_PATH_LITERAL(",")); 275 t(path_list, FILE_PATH_LITERAL(","));
276 while (t.GetNext()) { 276 while (t.GetNext()) {
277 std::string extension_id; 277 std::string extension_id;
278 UnpackedInstaller::Create(extension_service_.get()) 278 UnpackedInstaller::Create(extension_service_.get())->
279 ->LoadFromCommandLine(base::FilePath(t.token()), &extension_id, 279 LoadFromCommandLine(base::FilePath(t.token()), &extension_id);
280 false /* only_allow_apps */);
281 } 280 }
282 } 281 }
283 } 282 }
284 } 283 }
285 284
286 void ExtensionSystemImpl::Shared::Shutdown() { 285 void ExtensionSystemImpl::Shared::Shutdown() {
287 if (content_verifier_.get()) 286 if (content_verifier_.get())
288 content_verifier_->Shutdown(); 287 content_verifier_->Shutdown();
289 if (extension_service_) 288 if (extension_service_)
290 extension_service_->Shutdown(); 289 extension_service_->Shutdown();
(...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after
467 void ExtensionSystemImpl::UnregisterExtensionWithRequestContexts( 466 void ExtensionSystemImpl::UnregisterExtensionWithRequestContexts(
468 const std::string& extension_id, 467 const std::string& extension_id,
469 const UnloadedExtensionInfo::Reason reason) { 468 const UnloadedExtensionInfo::Reason reason) {
470 BrowserThread::PostTask( 469 BrowserThread::PostTask(
471 BrowserThread::IO, 470 BrowserThread::IO,
472 FROM_HERE, 471 FROM_HERE,
473 base::Bind(&InfoMap::RemoveExtension, info_map(), extension_id, reason)); 472 base::Bind(&InfoMap::RemoveExtension, info_map(), extension_id, reason));
474 } 473 }
475 474
476 } // namespace extensions 475 } // namespace extensions
OLDNEW
« no previous file with comments | « apps/load_and_launch_browsertest.cc ('k') | chrome/browser/extensions/unpacked_installer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698