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

Side by Side Diff: chrome/browser/profiles/profile_impl.cc

Issue 7349020: Don't show a prompt when loading an extension with NPAPI plugins via (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: unit test fix Created 9 years, 5 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/profiles/profile_impl.h" 5 #include "chrome/browser/profiles/profile_impl.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "base/environment.h" 9 #include "base/environment.h"
10 #include "base/file_path.h" 10 #include "base/file_path.h"
(...skipping 452 matching lines...) Expand 10 before | Expand all | Expand 10 after
463 extensions_enabled)); 463 extensions_enabled));
464 464
465 RegisterComponentExtensions(); 465 RegisterComponentExtensions();
466 extension_service_->Init(); 466 extension_service_->Init();
467 467
468 if (extensions_enabled) { 468 if (extensions_enabled) {
469 // Load any extensions specified with --load-extension. 469 // Load any extensions specified with --load-extension.
470 if (command_line->HasSwitch(switches::kLoadExtension)) { 470 if (command_line->HasSwitch(switches::kLoadExtension)) {
471 FilePath path = command_line->GetSwitchValuePath( 471 FilePath path = command_line->GetSwitchValuePath(
472 switches::kLoadExtension); 472 switches::kLoadExtension);
473 extension_service_->LoadExtension(path); 473 extension_service_->LoadExtensionFromCommandLine(path);
474 } 474 }
475 } 475 }
476 476
477 // Make the chrome://extension-icon/ resource available. 477 // Make the chrome://extension-icon/ resource available.
478 GetChromeURLDataManager()->AddDataSource(new ExtensionIconSource(this)); 478 GetChromeURLDataManager()->AddDataSource(new ExtensionIconSource(this));
479 } 479 }
480 480
481 void ProfileImpl::RegisterComponentExtensions() { 481 void ProfileImpl::RegisterComponentExtensions() {
482 // Register the component extensions. 482 // Register the component extensions.
483 // 483 //
(...skipping 1168 matching lines...) Expand 10 before | Expand all | Expand 10 after
1652 if (!prerender::PrerenderManager::IsPrerenderingPossible()) 1652 if (!prerender::PrerenderManager::IsPrerenderingPossible())
1653 return NULL; 1653 return NULL;
1654 if (!prerender_manager_.get()) { 1654 if (!prerender_manager_.get()) {
1655 CHECK(g_browser_process->prerender_tracker()); 1655 CHECK(g_browser_process->prerender_tracker());
1656 prerender_manager_.reset( 1656 prerender_manager_.reset(
1657 new prerender::PrerenderManager( 1657 new prerender::PrerenderManager(
1658 this, g_browser_process->prerender_tracker())); 1658 this, g_browser_process->prerender_tracker()));
1659 } 1659 }
1660 return prerender_manager_.get(); 1660 return prerender_manager_.get();
1661 } 1661 }
OLDNEW
« no previous file with comments | « chrome/browser/extensions/extension_service.cc ('k') | chrome/browser/ui/panels/panel_browser_view_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698