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

Unified Diff: chrome/browser/extensions/extension_sorting.h

Issue 9706017: Remove Ordinals Setters and Getters from ExtensionService (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 8 years, 9 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_sorting.h
diff --git a/chrome/browser/extensions/extension_sorting.h b/chrome/browser/extensions/extension_sorting.h
index 3542d51d2777a4c7d1d19d06679325426cfd843a..b0bf38a6079b5b7dbd76be2bab455b13a0d34a55 100644
--- a/chrome/browser/extensions/extension_sorting.h
+++ b/chrome/browser/extensions/extension_sorting.h
@@ -14,6 +14,7 @@
#include "chrome/common/string_ordinal.h"
class ExtensionScopedPrefs;
+class ExtensionServiceInterface;
class ExtensionSorting {
public:
@@ -21,6 +22,9 @@ class ExtensionSorting {
PrefService* pref_service);
~ExtensionSorting();
+ // Set up the ExtensionService to inform of changes that require syncing.
+ void SetExtensionService(ExtensionServiceInterface* extension_service);
+
// Properly initialize ExtensionSorting internal values that require
// |extension_ids|.
void Initialize(const ExtensionPrefs::ExtensionIdSet& extension_ids);
@@ -133,8 +137,13 @@ class ExtensionSorting {
const StringOrdinal& page_ordinal,
const StringOrdinal& app_launch_ordinal);
+ // Syncs the extension if needed. It is an error to call this if the
+ // extension is not an application.
+ void SyncIfNeeded(const std::string& extension_id);
+
ExtensionScopedPrefs* extension_scoped_prefs_; // Weak, owns this instance.
PrefService* pref_service_; // Weak.
+ ExtensionServiceInterface* extension_service_; // Weak.
// A map of all the StringOrdinal page ordinals mapping to the collections of
// app launch ordinals that exist on that page. This is used for mapping
« no previous file with comments | « chrome/browser/extensions/extension_service_unittest.cc ('k') | chrome/browser/extensions/extension_sorting.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698