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/extensions/shared_module_service.cc

Issue 1549233002: Convert Pass()→std::move() in //chrome/browser/extensions (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 years, 12 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
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/shared_module_service.h" 5 #include "chrome/browser/extensions/shared_module_service.h"
6 6
7 #include <set> 7 #include <set>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after
124 124
125 for (ExtensionSet::const_iterator iter = set_to_check.begin(); 125 for (ExtensionSet::const_iterator iter = set_to_check.begin();
126 iter != set_to_check.end(); 126 iter != set_to_check.end();
127 ++iter) { 127 ++iter) {
128 if (SharedModuleInfo::ImportsExtensionById(iter->get(), 128 if (SharedModuleInfo::ImportsExtensionById(iter->get(),
129 extension->id())) { 129 extension->id())) {
130 dependents->Insert(*iter); 130 dependents->Insert(*iter);
131 } 131 }
132 } 132 }
133 } 133 }
134 return dependents.Pass(); 134 return dependents;
135 } 135 }
136 136
137 void SharedModuleService::PruneSharedModules() { 137 void SharedModuleService::PruneSharedModules() {
138 ExtensionRegistry* registry = ExtensionRegistry::Get(browser_context_); 138 ExtensionRegistry* registry = ExtensionRegistry::Get(browser_context_);
139 ExtensionService* service = 139 ExtensionService* service =
140 ExtensionSystem::Get(browser_context_)->extension_service(); 140 ExtensionSystem::Get(browser_context_)->extension_service();
141 141
142 ExtensionSet set_to_check; 142 ExtensionSet set_to_check;
143 set_to_check.InsertAll(registry->enabled_extensions()); 143 set_to_check.InsertAll(registry->enabled_extensions());
144 set_to_check.InsertAll(registry->disabled_extensions()); 144 set_to_check.InsertAll(registry->disabled_extensions());
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
184 } 184 }
185 185
186 void SharedModuleService::OnExtensionUninstalled( 186 void SharedModuleService::OnExtensionUninstalled(
187 content::BrowserContext* browser_context, 187 content::BrowserContext* browser_context,
188 const Extension* extension, 188 const Extension* extension,
189 extensions::UninstallReason reason) { 189 extensions::UninstallReason reason) {
190 PruneSharedModules(); 190 PruneSharedModules();
191 } 191 }
192 192
193 } // namespace extensions 193 } // namespace extensions
OLDNEW
« no previous file with comments | « chrome/browser/extensions/process_manager_browsertest.cc ('k') | chrome/browser/extensions/shared_module_service_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698