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

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

Issue 6250198: More out-of-lining of test code, along with a bunch of GMOCK objects. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Really fix the gyp files this time Created 9 years, 10 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/extensions/extension_service.h" 5 #include "chrome/browser/extensions/extension_service.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <set> 8 #include <set>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 1226 matching lines...) Expand 10 before | Expand all | Expand 10 after
1237 } 1237 }
1238 } 1238 }
1239 1239
1240 // UnloadExtension will change the extensions_ list. So, we should 1240 // UnloadExtension will change the extensions_ list. So, we should
1241 // call it outside the iterator loop. 1241 // call it outside the iterator loop.
1242 for (unsigned int i = 0; i < to_be_removed.size(); ++i) { 1242 for (unsigned int i = 0; i < to_be_removed.size(); ++i) {
1243 UnloadExtension(to_be_removed[i], UnloadedExtensionInfo::DISABLE); 1243 UnloadExtension(to_be_removed[i], UnloadedExtensionInfo::DISABLE);
1244 } 1244 }
1245 } 1245 }
1246 1246
1247 Profile* ExtensionService::profile() {
1248 return profile_;
1249 }
1250
1247 void ExtensionService::DestroyingProfile() { 1251 void ExtensionService::DestroyingProfile() {
1248 if (updater_.get()) { 1252 if (updater_.get()) {
1249 updater_->Stop(); 1253 updater_->Stop();
1250 } 1254 }
1251 browser_event_router_.reset(); 1255 browser_event_router_.reset();
1252 pref_change_registrar_.RemoveAll(); 1256 pref_change_registrar_.RemoveAll();
1253 profile_ = NULL; 1257 profile_ = NULL;
1254 toolbar_model_.DestroyingProfile(); 1258 toolbar_model_.DestroyingProfile();
1255 } 1259 }
1256 1260
(...skipping 728 matching lines...) Expand 10 before | Expand all | Expand 10 after
1985 } 1989 }
1986 1990
1987 void ExtensionService::SetBeingUpgraded(const Extension* extension, 1991 void ExtensionService::SetBeingUpgraded(const Extension* extension,
1988 bool value) { 1992 bool value) {
1989 extension_runtime_data_[extension->id()].being_upgraded = value; 1993 extension_runtime_data_[extension->id()].being_upgraded = value;
1990 } 1994 }
1991 1995
1992 PropertyBag* ExtensionService::GetPropertyBag(const Extension* extension) { 1996 PropertyBag* ExtensionService::GetPropertyBag(const Extension* extension) {
1993 return &extension_runtime_data_[extension->id()].property_bag; 1997 return &extension_runtime_data_[extension->id()].property_bag;
1994 } 1998 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698