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

Unified Diff: chrome/browser/extensions/extension_service.cc

Issue 7775008: Enable sync for the settings from the Extension Settings API. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Review #2 against correct branch Created 9 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/extensions/extension_service.cc
diff --git a/chrome/browser/extensions/extension_service.cc b/chrome/browser/extensions/extension_service.cc
index dc4d403fdcc1b66339a973c7eeefc9a547942a91..0d95c3e017e26ef36347e1180de396612e9fc501 100644
--- a/chrome/browser/extensions/extension_service.cc
+++ b/chrome/browser/extensions/extension_service.cc
@@ -650,6 +650,21 @@ ExtensionService::ExtensionService(Profile* profile,
install_directory_.value().length(), 0, 500, 100);
}
+static void AddAllExtensionIds(
Ben Olmstead 2011/09/16 18:21:43 Wrap in anonymous namespace.
not at google - send to devlin 2011/09/19 07:10:47 No longer needed.
+ std::vector<std::string>* dst, const ExtensionList& src) {
akalin 2011/09/17 08:44:47 i think output args are usually put last
not at google - send to devlin 2011/09/19 07:10:47 No longer needed.
+ for (ExtensionList::const_iterator it = src.begin(); it != src.end(); ++it) {
+ dst->push_back((*it)->id());
+ }
+}
+
+const std::vector<std::string> ExtensionService::GetAllExtensionIds() const {
+ std::vector<std::string> all_extension_ids;
+ AddAllExtensionIds(&all_extension_ids, extensions_);
+ AddAllExtensionIds(&all_extension_ids, disabled_extensions_);
+ AddAllExtensionIds(&all_extension_ids, terminated_extensions_);
+ return all_extension_ids;
+}
+
const ExtensionList* ExtensionService::extensions() const {
return &extensions_;
}

Powered by Google App Engine
This is Rietveld 408576698