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

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

Issue 8789018: Revert 113047 - Make ExtensionService use ExtensionSet. (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 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 "base/bind.h" 5 #include "base/bind.h"
6 #include "base/command_line.h" 6 #include "base/command_line.h"
7 #include "chrome/browser/extensions/extension_process_manager.h" 7 #include "chrome/browser/extensions/extension_process_manager.h"
8 8
9 #include "chrome/browser/ui/browser_window.h" 9 #include "chrome/browser/ui/browser_window.h"
10 #include "content/browser/browsing_instance.h" 10 #include "content/browser/browsing_instance.h"
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
67 static void CreateBackgroundHostForExtensionLoad( 67 static void CreateBackgroundHostForExtensionLoad(
68 ExtensionProcessManager* manager, const Extension* extension) { 68 ExtensionProcessManager* manager, const Extension* extension) {
69 // Start the process for the master page, if it exists and we're not lazy. 69 // Start the process for the master page, if it exists and we're not lazy.
70 if (!CommandLine::ForCurrentProcess()->HasSwitch( 70 if (!CommandLine::ForCurrentProcess()->HasSwitch(
71 switches::kEnableLazyBackgroundPages) && 71 switches::kEnableLazyBackgroundPages) &&
72 extension->background_url().is_valid()) 72 extension->background_url().is_valid())
73 manager->CreateBackgroundHost(extension, extension->background_url()); 73 manager->CreateBackgroundHost(extension, extension->background_url());
74 } 74 }
75 75
76 static void CreateBackgroundHostsForProfileStartup( 76 static void CreateBackgroundHostsForProfileStartup(
77 ExtensionProcessManager* manager, const ExtensionSet* extensions) { 77 ExtensionProcessManager* manager, const ExtensionList* extensions) {
78 for (ExtensionSet::const_iterator extension = extensions->begin(); 78 for (ExtensionList::const_iterator extension = extensions->begin();
79 extension != extensions->end(); ++extension) { 79 extension != extensions->end(); ++extension) {
80 CreateBackgroundHostForExtensionLoad(manager, *extension); 80 CreateBackgroundHostForExtensionLoad(manager, *extension);
81 } 81 }
82 } 82 }
83 83
84 } // namespace 84 } // namespace
85 85
86 // 86 //
87 // ExtensionProcessManager 87 // ExtensionProcessManager
88 // 88 //
(...skipping 401 matching lines...) Expand 10 before | Expand all | Expand 10 after
490 if (service && service->is_ready()) 490 if (service && service->is_ready())
491 CreateBackgroundHostsForProfileStartup(this, service->extensions()); 491 CreateBackgroundHostsForProfileStartup(this, service->extensions());
492 } 492 }
493 break; 493 break;
494 } 494 }
495 default: 495 default:
496 ExtensionProcessManager::Observe(type, source, details); 496 ExtensionProcessManager::Observe(type, source, details);
497 break; 497 break;
498 } 498 }
499 } 499 }
OLDNEW
« no previous file with comments | « chrome/browser/extensions/extension_preference_api.cc ('k') | chrome/browser/extensions/extension_service.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698