| 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 CHROME_BROWSER_EXTENSIONS_EXTERNAL_INSTALL_MANAGER_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTERNAL_INSTALL_MANAGER_H_ |
| 6 #define CHROME_BROWSER_EXTENSIONS_EXTERNAL_INSTALL_MANAGER_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_EXTERNAL_INSTALL_MANAGER_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <memory> | 9 #include <memory> |
| 10 | 10 |
| (...skipping 16 matching lines...) Expand all Loading... |
| 27 class ExtensionPrefs; | 27 class ExtensionPrefs; |
| 28 class ExternalInstallError; | 28 class ExternalInstallError; |
| 29 | 29 |
| 30 class ExternalInstallManager : public ExtensionRegistryObserver, | 30 class ExternalInstallManager : public ExtensionRegistryObserver, |
| 31 public content::NotificationObserver { | 31 public content::NotificationObserver { |
| 32 public: | 32 public: |
| 33 ExternalInstallManager(content::BrowserContext* browser_context, | 33 ExternalInstallManager(content::BrowserContext* browser_context, |
| 34 bool is_first_run); | 34 bool is_first_run); |
| 35 ~ExternalInstallManager() override; | 35 ~ExternalInstallManager() override; |
| 36 | 36 |
| 37 // Returns true if prompting for external extensions is enabled. |
| 38 static bool IsPromptingEnabled(); |
| 39 |
| 37 // Removes the error associated with a given extension. | 40 // Removes the error associated with a given extension. |
| 38 void RemoveExternalInstallError(const std::string& extension_id); | 41 void RemoveExternalInstallError(const std::string& extension_id); |
| 39 | 42 |
| 40 // Checks if there are any new external extensions to notify the user about. | 43 // Checks if there are any new external extensions to notify the user about. |
| 41 void UpdateExternalExtensionAlert(); | 44 void UpdateExternalExtensionAlert(); |
| 42 | 45 |
| 43 // Given a (presumably just-installed) extension id, mark that extension as | 46 // Given a (presumably just-installed) extension id, mark that extension as |
| 44 // acknowledged. | 47 // acknowledged. |
| 45 void AcknowledgeExternalExtension(const std::string& extension_id); | 48 void AcknowledgeExternalExtension(const std::string& extension_id); |
| 46 | 49 |
| (...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 113 | 116 |
| 114 ScopedObserver<ExtensionRegistry, ExtensionRegistryObserver> | 117 ScopedObserver<ExtensionRegistry, ExtensionRegistryObserver> |
| 115 extension_registry_observer_; | 118 extension_registry_observer_; |
| 116 | 119 |
| 117 DISALLOW_COPY_AND_ASSIGN(ExternalInstallManager); | 120 DISALLOW_COPY_AND_ASSIGN(ExternalInstallManager); |
| 118 }; | 121 }; |
| 119 | 122 |
| 120 } // namespace extensions | 123 } // namespace extensions |
| 121 | 124 |
| 122 #endif // CHROME_BROWSER_EXTENSIONS_EXTERNAL_INSTALL_MANAGER_H_ | 125 #endif // CHROME_BROWSER_EXTENSIONS_EXTERNAL_INSTALL_MANAGER_H_ |
| OLD | NEW |