OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 CHROME_BROWSER_EXTENSIONS_API_SETTINGS_OVERRIDES_SETTINGS_OVERRIDES_API_
H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_API_SETTINGS_OVERRIDES_SETTINGS_OVERRIDES_API_
H_ |
6 #define CHROME_BROWSER_EXTENSIONS_API_SETTINGS_OVERRIDES_SETTINGS_OVERRIDES_API_
H_ | 6 #define CHROME_BROWSER_EXTENSIONS_API_SETTINGS_OVERRIDES_SETTINGS_OVERRIDES_API_
H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 #include <set> | 9 #include <set> |
10 #include <string> | 10 #include <string> |
(...skipping 27 matching lines...) Expand all Loading... |
38 const std::string& pref_key, | 38 const std::string& pref_key, |
39 std::unique_ptr<base::Value> value) const; | 39 std::unique_ptr<base::Value> value) const; |
40 void UnsetPref(const std::string& extension_id, | 40 void UnsetPref(const std::string& extension_id, |
41 const std::string& pref_key) const; | 41 const std::string& pref_key) const; |
42 | 42 |
43 // ExtensionRegistryObserver implementation. | 43 // ExtensionRegistryObserver implementation. |
44 void OnExtensionLoaded(content::BrowserContext* browser_context, | 44 void OnExtensionLoaded(content::BrowserContext* browser_context, |
45 const Extension* extension) override; | 45 const Extension* extension) override; |
46 void OnExtensionUnloaded(content::BrowserContext* browser_context, | 46 void OnExtensionUnloaded(content::BrowserContext* browser_context, |
47 const Extension* extension, | 47 const Extension* extension, |
48 UnloadedExtensionInfo::Reason reason) override; | 48 UnloadedExtensionReason reason) override; |
49 | 49 |
50 void RegisterSearchProvider(const Extension* extension) const; | 50 void RegisterSearchProvider(const Extension* extension) const; |
51 // BrowserContextKeyedAPI implementation. | 51 // BrowserContextKeyedAPI implementation. |
52 static const char* service_name() { return "SettingsOverridesAPI"; } | 52 static const char* service_name() { return "SettingsOverridesAPI"; } |
53 | 53 |
54 Profile* profile_; | 54 Profile* profile_; |
55 TemplateURLService* url_service_; | 55 TemplateURLService* url_service_; |
56 | 56 |
57 // Listen to extension load, unloaded notifications. | 57 // Listen to extension load, unloaded notifications. |
58 ScopedObserver<ExtensionRegistry, ExtensionRegistryObserver> | 58 ScopedObserver<ExtensionRegistry, ExtensionRegistryObserver> |
59 extension_registry_observer_; | 59 extension_registry_observer_; |
60 | 60 |
61 DISALLOW_COPY_AND_ASSIGN(SettingsOverridesAPI); | 61 DISALLOW_COPY_AND_ASSIGN(SettingsOverridesAPI); |
62 }; | 62 }; |
63 | 63 |
64 template <> | 64 template <> |
65 void BrowserContextKeyedAPIFactory< | 65 void BrowserContextKeyedAPIFactory< |
66 SettingsOverridesAPI>::DeclareFactoryDependencies(); | 66 SettingsOverridesAPI>::DeclareFactoryDependencies(); |
67 | 67 |
68 } // namespace extensions | 68 } // namespace extensions |
69 | 69 |
70 #endif // CHROME_BROWSER_EXTENSIONS_API_SETTINGS_OVERRIDES_SETTINGS_OVERRIDES_A
PI_H_ | 70 #endif // CHROME_BROWSER_EXTENSIONS_API_SETTINGS_OVERRIDES_SETTINGS_OVERRIDES_A
PI_H_ |
OLD | NEW |