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

Side by Side Diff: extensions/browser/extension_system.h

Issue 1254363004: Move ownership of AppSorting from ExtensionPrefs to ExtensionSystem (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix extensions_unittests Created 5 years, 4 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 #ifndef EXTENSIONS_BROWSER_EXTENSION_SYSTEM_H_ 5 #ifndef EXTENSIONS_BROWSER_EXTENSION_SYSTEM_H_
6 #define EXTENSIONS_BROWSER_EXTENSION_SYSTEM_H_ 6 #define EXTENSIONS_BROWSER_EXTENSION_SYSTEM_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/callback_forward.h" 10 #include "base/callback_forward.h"
(...skipping 12 matching lines...) Expand all
23 class DeviceLocalAccountManagementPolicyProvider; 23 class DeviceLocalAccountManagementPolicyProvider;
24 } 24 }
25 #endif // defined(OS_CHROMEOS) 25 #endif // defined(OS_CHROMEOS)
26 26
27 namespace content { 27 namespace content {
28 class BrowserContext; 28 class BrowserContext;
29 } 29 }
30 30
31 namespace extensions { 31 namespace extensions {
32 32
33 class AppSorting;
33 class ContentVerifier; 34 class ContentVerifier;
34 class Extension; 35 class Extension;
35 class ExtensionSet; 36 class ExtensionSet;
36 class InfoMap; 37 class InfoMap;
37 class ManagementPolicy; 38 class ManagementPolicy;
38 class OneShotEvent; 39 class OneShotEvent;
39 class QuotaService; 40 class QuotaService;
40 class RuntimeData; 41 class RuntimeData;
41 class SharedUserScriptMaster; 42 class SharedUserScriptMaster;
42 class StateStore; 43 class StateStore;
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
79 // The rules store is created at startup. 80 // The rules store is created at startup.
80 virtual StateStore* rules_store() = 0; 81 virtual StateStore* rules_store() = 0;
81 82
82 // Returns the IO-thread-accessible extension data. 83 // Returns the IO-thread-accessible extension data.
83 virtual InfoMap* info_map() = 0; 84 virtual InfoMap* info_map() = 0;
84 85
85 // Returns the QuotaService that limits calls to certain extension functions. 86 // Returns the QuotaService that limits calls to certain extension functions.
86 // Lives on the UI thread. Created at startup. 87 // Lives on the UI thread. Created at startup.
87 virtual QuotaService* quota_service() = 0; 88 virtual QuotaService* quota_service() = 0;
88 89
90 // Returns the AppSorting which provides an ordering for all installed apps.
91 virtual AppSorting* app_sorting() = 0;
92
89 // Called by the ExtensionService that lives in this system. Gives the 93 // Called by the ExtensionService that lives in this system. Gives the
90 // info map a chance to react to the load event before the EXTENSION_LOADED 94 // info map a chance to react to the load event before the EXTENSION_LOADED
91 // notification has fired. The purpose for handling this event first is to 95 // notification has fired. The purpose for handling this event first is to
92 // avoid race conditions by making sure URLRequestContexts learn about new 96 // avoid race conditions by making sure URLRequestContexts learn about new
93 // extensions before anything else needs them to know. This operation happens 97 // extensions before anything else needs them to know. This operation happens
94 // asynchronously. |callback| is run on the calling thread once completed. 98 // asynchronously. |callback| is run on the calling thread once completed.
95 virtual void RegisterExtensionWithRequestContexts( 99 virtual void RegisterExtensionWithRequestContexts(
96 const Extension* extension, 100 const Extension* extension,
97 const base::Closure& callback) {} 101 const base::Closure& callback) {}
98 102
(...skipping 13 matching lines...) Expand all
112 // Get a set of extensions that depend on the given extension. 116 // Get a set of extensions that depend on the given extension.
113 // TODO(elijahtaylor): Move SharedModuleService out of chrome/browser 117 // TODO(elijahtaylor): Move SharedModuleService out of chrome/browser
114 // so it can be retrieved from ExtensionSystem directly. 118 // so it can be retrieved from ExtensionSystem directly.
115 virtual scoped_ptr<ExtensionSet> GetDependentExtensions( 119 virtual scoped_ptr<ExtensionSet> GetDependentExtensions(
116 const Extension* extension) = 0; 120 const Extension* extension) = 0;
117 }; 121 };
118 122
119 } // namespace extensions 123 } // namespace extensions
120 124
121 #endif // EXTENSIONS_BROWSER_EXTENSION_SYSTEM_H_ 125 #endif // EXTENSIONS_BROWSER_EXTENSION_SYSTEM_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698