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

Side by Side Diff: chrome/browser/sync/test/integration/sync_app_helper.cc

Issue 102103005: Move c/c/e/extension_set to top-level extensions/ (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Move ExtensionSet to extensions namespace Created 7 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/sync/test/integration/sync_app_helper.h" 5 #include "chrome/browser/sync/test/integration/sync_app_helper.h"
6 6
7 #include "chrome/browser/extensions/extension_service.h" 7 #include "chrome/browser/extensions/extension_service.h"
8 #include "chrome/browser/extensions/extension_system.h" 8 #include "chrome/browser/extensions/extension_system.h"
9 #include "chrome/browser/profiles/profile.h" 9 #include "chrome/browser/profiles/profile.h"
10 #include "chrome/browser/sync/test/integration/extensions_helper.h" 10 #include "chrome/browser/sync/test/integration/extensions_helper.h"
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 app_state->page_ordinal = extension_service->extension_prefs()-> 50 app_state->page_ordinal = extension_service->extension_prefs()->
51 app_sorting()->GetPageOrdinal(id); 51 app_sorting()->GetPageOrdinal(id);
52 } 52 }
53 53
54 // Returns a map from |profile|'s installed extensions to their state. 54 // Returns a map from |profile|'s installed extensions to their state.
55 AppStateMap GetAppStates(Profile* profile) { 55 AppStateMap GetAppStates(Profile* profile) {
56 AppStateMap app_state_map; 56 AppStateMap app_state_map;
57 57
58 ExtensionService* extension_service = profile->GetExtensionService(); 58 ExtensionService* extension_service = profile->GetExtensionService();
59 59
60 scoped_ptr<const ExtensionSet> extensions( 60 scoped_ptr<const extensions::ExtensionSet> extensions(
61 extension_service->GenerateInstalledExtensionsSet()); 61 extension_service->GenerateInstalledExtensionsSet());
62 for (ExtensionSet::const_iterator it = extensions->begin(); 62 for (extensions::ExtensionSet::const_iterator it = extensions->begin();
63 it != extensions->end(); ++it) { 63 it != extensions->end(); ++it) {
64 if (extensions::sync_helper::IsSyncableApp(it->get())) { 64 if (extensions::sync_helper::IsSyncableApp(it->get())) {
65 const std::string& id = (*it)->id(); 65 const std::string& id = (*it)->id();
66 LoadApp(extension_service, id, &(app_state_map[id])); 66 LoadApp(extension_service, id, &(app_state_map[id]));
67 } 67 }
68 } 68 }
69 69
70 const extensions::PendingExtensionManager* pending_extension_manager = 70 const extensions::PendingExtensionManager* pending_extension_manager =
71 extension_service->pending_extension_manager(); 71 extension_service->pending_extension_manager();
72 72
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
175 } 175 }
176 176
177 void SyncAppHelper::FixNTPOrdinalCollisions(Profile* profile) { 177 void SyncAppHelper::FixNTPOrdinalCollisions(Profile* profile) {
178 profile->GetExtensionService()->extension_prefs()->app_sorting()-> 178 profile->GetExtensionService()->extension_prefs()->app_sorting()->
179 FixNTPOrdinalCollisions(); 179 FixNTPOrdinalCollisions();
180 } 180 }
181 181
182 SyncAppHelper::SyncAppHelper() : setup_completed_(false) {} 182 SyncAppHelper::SyncAppHelper() : setup_completed_(false) {}
183 183
184 SyncAppHelper::~SyncAppHelper() {} 184 SyncAppHelper::~SyncAppHelper() {}
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698