Chromium Code Reviews| OLD | NEW |
|---|---|
| 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_REGISTRY_OBSERVER_H_ | 5 #ifndef EXTENSIONS_BROWSER_EXTENSION_REGISTRY_OBSERVER_H_ |
| 6 #define EXTENSIONS_BROWSER_EXTENSION_REGISTRY_OBSERVER_H_ | 6 #define EXTENSIONS_BROWSER_EXTENSION_REGISTRY_OBSERVER_H_ |
| 7 | 7 |
| 8 #include "extensions/common/extension.h" | 8 #include "extensions/common/extension.h" |
| 9 | 9 |
| 10 namespace content { | 10 namespace content { |
| (...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 52 // TODO(tmdiep): We should stash the state of the previous extension version | 52 // TODO(tmdiep): We should stash the state of the previous extension version |
| 53 // somewhere and have observers retrieve it. |is_update|, |from_ephemeral| | 53 // somewhere and have observers retrieve it. |is_update|, |from_ephemeral| |
| 54 // and |old_name| can be removed when this is done. | 54 // and |old_name| can be removed when this is done. |
| 55 virtual void OnExtensionWillBeInstalled( | 55 virtual void OnExtensionWillBeInstalled( |
| 56 content::BrowserContext* browser_context, | 56 content::BrowserContext* browser_context, |
| 57 const Extension* extension, | 57 const Extension* extension, |
| 58 bool is_update, | 58 bool is_update, |
| 59 bool from_ephemeral, | 59 bool from_ephemeral, |
| 60 const std::string& old_name) {} | 60 const std::string& old_name) {} |
| 61 | 61 |
| 62 // Called after an extension is uninstalled. The extension no longer exsit in | 62 // Called when the installation of |extension| is complete. At this point the |
| 63 // extension is tracked in one of the ExtensionRegistry sets, but is not | |
| 64 // necessarily enabled. | |
|
asargent_no_longer_on_chrome
2014/06/11 18:27:54
Would it be helpful to pass the enabled/disabled s
tmdiep
2014/06/11 22:56:18
I think maybe not for this notification - it's for
| |
| 65 virtual void OnExtensionInstalled(content::BrowserContext* browser_context, | |
| 66 const Extension* extension) {} | |
| 67 | |
| 68 // Called after an extension is uninstalled. The extension no longer exists in | |
| 63 // any of the ExtensionRegistry sets (enabled, disabled, etc.). | 69 // any of the ExtensionRegistry sets (enabled, disabled, etc.). |
| 64 virtual void OnExtensionUninstalled(content::BrowserContext* browser_context, | 70 virtual void OnExtensionUninstalled(content::BrowserContext* browser_context, |
| 65 const Extension* extension) {} | 71 const Extension* extension) {} |
| 66 | 72 |
| 67 // Notifies observers that the observed object is going away. | 73 // Notifies observers that the observed object is going away. |
| 68 virtual void OnShutdown(ExtensionRegistry* registry) {} | 74 virtual void OnShutdown(ExtensionRegistry* registry) {} |
| 69 }; | 75 }; |
| 70 | 76 |
| 71 } // namespace extensions | 77 } // namespace extensions |
| 72 | 78 |
| 73 #endif // EXTENSIONS_BROWSER_EXTENSION_REGISTRY_OBSERVER_H_ | 79 #endif // EXTENSIONS_BROWSER_EXTENSION_REGISTRY_OBSERVER_H_ |
| OLD | NEW |