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 EXTENSIONS_BROWSER_EXTENSION_REGISTRY_H_ | 5 #ifndef EXTENSIONS_BROWSER_EXTENSION_REGISTRY_H_ |
6 #define EXTENSIONS_BROWSER_EXTENSION_REGISTRY_H_ | 6 #define EXTENSIONS_BROWSER_EXTENSION_REGISTRY_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
67 | 67 |
68 // Invokes the observer method OnExtensionLoaded(). The extension must be | 68 // Invokes the observer method OnExtensionLoaded(). The extension must be |
69 // enabled at the time of the call. | 69 // enabled at the time of the call. |
70 void TriggerOnLoaded(const Extension* extension); | 70 void TriggerOnLoaded(const Extension* extension); |
71 | 71 |
72 // Invokes the observer method OnExtensionUnloaded(). The extension must not | 72 // Invokes the observer method OnExtensionUnloaded(). The extension must not |
73 // be enabled at the time of the call. | 73 // be enabled at the time of the call. |
74 void TriggerOnUnloaded(const Extension* extension, | 74 void TriggerOnUnloaded(const Extension* extension, |
75 UnloadedExtensionInfo::Reason reason); | 75 UnloadedExtensionInfo::Reason reason); |
76 | 76 |
77 // Invokes the observer method OnExtensionInstalled(). The extension will be | |
not at google - send to devlin
2014/05/16 23:03:35
OnWillBeInstalled
limasdf
2014/05/17 06:16:19
Done.
| |
78 // installed at the time of the call. | |
not at google - send to devlin
2014/05/16 23:03:35
second sentence still not quite right? should be "
limasdf
2014/05/17 06:16:19
Done.
| |
79 void TriggerOnInstalled(const Extension* extension, | |
not at google - send to devlin
2014/05/16 23:03:35
TriggerOnWillBeInstalled
limasdf
2014/05/17 06:16:19
Done.
| |
80 bool is_update, | |
81 const std::string& old_name); | |
82 | |
77 // Find an extension by ID using |include_mask| to pick the sets to search: | 83 // Find an extension by ID using |include_mask| to pick the sets to search: |
78 // * enabled_extensions() --> ExtensionRegistry::ENABLED | 84 // * enabled_extensions() --> ExtensionRegistry::ENABLED |
79 // * disabled_extensions() --> ExtensionRegistry::DISABLED | 85 // * disabled_extensions() --> ExtensionRegistry::DISABLED |
80 // * terminated_extensions() --> ExtensionRegistry::TERMINATED | 86 // * terminated_extensions() --> ExtensionRegistry::TERMINATED |
81 // * blacklisted_extensions() --> ExtensionRegistry::BLACKLISTED | 87 // * blacklisted_extensions() --> ExtensionRegistry::BLACKLISTED |
82 // Returns NULL if the extension is not found in the selected sets. | 88 // Returns NULL if the extension is not found in the selected sets. |
83 const Extension* GetExtensionById(const std::string& id, | 89 const Extension* GetExtensionById(const std::string& id, |
84 int include_mask) const; | 90 int include_mask) const; |
85 | 91 |
86 // Adds the specified extension to the enabled set. The registry becomes an | 92 // Adds the specified extension to the enabled set. The registry becomes an |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
139 ObserverList<ExtensionRegistryObserver> observers_; | 145 ObserverList<ExtensionRegistryObserver> observers_; |
140 | 146 |
141 content::BrowserContext* const browser_context_; | 147 content::BrowserContext* const browser_context_; |
142 | 148 |
143 DISALLOW_COPY_AND_ASSIGN(ExtensionRegistry); | 149 DISALLOW_COPY_AND_ASSIGN(ExtensionRegistry); |
144 }; | 150 }; |
145 | 151 |
146 } // namespace extensions | 152 } // namespace extensions |
147 | 153 |
148 #endif // EXTENSIONS_BROWSER_EXTENSION_REGISTRY_H_ | 154 #endif // EXTENSIONS_BROWSER_EXTENSION_REGISTRY_H_ |
OLD | NEW |