OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_UI_WEBUI_EXTENSIONS_EXTENSION_SETTINGS_HANDLER_H_ | 5 #ifndef CHROME_BROWSER_UI_WEBUI_EXTENSIONS_EXTENSION_SETTINGS_HANDLER_H_ |
6 #define CHROME_BROWSER_UI_WEBUI_EXTENSIONS_EXTENSION_SETTINGS_HANDLER_H_ | 6 #define CHROME_BROWSER_UI_WEBUI_EXTENSIONS_EXTENSION_SETTINGS_HANDLER_H_ |
7 | 7 |
8 #include <set> | 8 #include <set> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
11 | 11 |
12 #include "base/memory/scoped_ptr.h" | 12 #include "base/memory/scoped_ptr.h" |
13 #include "base/scoped_observer.h" | 13 #include "base/scoped_observer.h" |
14 #include "chrome/browser/extensions/error_console/error_console.h" | 14 #include "chrome/browser/extensions/error_console/error_console.h" |
15 #include "chrome/browser/extensions/extension_install_prompt.h" | 15 #include "chrome/browser/extensions/extension_install_prompt.h" |
16 #include "chrome/browser/extensions/extension_install_ui.h" | 16 #include "chrome/browser/extensions/extension_install_ui.h" |
17 #include "chrome/browser/extensions/extension_management.h" | 17 #include "chrome/browser/extensions/extension_management.h" |
18 #include "chrome/browser/extensions/extension_uninstall_dialog.h" | 18 #include "chrome/browser/extensions/extension_uninstall_dialog.h" |
19 #include "chrome/browser/extensions/requirements_checker.h" | 19 #include "chrome/browser/extensions/requirements_checker.h" |
| 20 #include "chrome/common/extensions/webstore_install_result.h" |
20 #include "content/public/browser/navigation_controller.h" | 21 #include "content/public/browser/navigation_controller.h" |
21 #include "content/public/browser/notification_observer.h" | 22 #include "content/public/browser/notification_observer.h" |
22 #include "content/public/browser/notification_registrar.h" | 23 #include "content/public/browser/notification_registrar.h" |
23 #include "content/public/browser/web_contents_observer.h" | 24 #include "content/public/browser/web_contents_observer.h" |
24 #include "content/public/browser/web_ui_message_handler.h" | 25 #include "content/public/browser/web_ui_message_handler.h" |
25 #include "extensions/browser/extension_prefs.h" | 26 #include "extensions/browser/extension_prefs.h" |
26 #include "extensions/browser/extension_prefs_observer.h" | 27 #include "extensions/browser/extension_prefs_observer.h" |
27 #include "extensions/browser/extension_registry_observer.h" | 28 #include "extensions/browser/extension_registry_observer.h" |
28 #include "extensions/browser/warning_service.h" | 29 #include "extensions/browser/warning_service.h" |
29 #include "url/gurl.h" | 30 #include "url/gurl.h" |
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
161 | 162 |
162 // Callback for "inspect" message. | 163 // Callback for "inspect" message. |
163 void HandleInspectMessage(const base::ListValue* args); | 164 void HandleInspectMessage(const base::ListValue* args); |
164 | 165 |
165 // Callback for "launch" message. | 166 // Callback for "launch" message. |
166 void HandleLaunchMessage(const base::ListValue* args); | 167 void HandleLaunchMessage(const base::ListValue* args); |
167 | 168 |
168 // Callback for "reload" message. | 169 // Callback for "reload" message. |
169 void HandleReloadMessage(const base::ListValue* args); | 170 void HandleReloadMessage(const base::ListValue* args); |
170 | 171 |
| 172 // Callback for "repair" message. |
| 173 void HandleRepairMessage(const base::ListValue* args); |
| 174 |
171 // Callback for "enable" message. | 175 // Callback for "enable" message. |
172 void HandleEnableMessage(const base::ListValue* args); | 176 void HandleEnableMessage(const base::ListValue* args); |
173 | 177 |
174 // Callback for "enableIncognito" message. | 178 // Callback for "enableIncognito" message. |
175 void HandleEnableIncognitoMessage(const base::ListValue* args); | 179 void HandleEnableIncognitoMessage(const base::ListValue* args); |
176 | 180 |
177 // Callback for "enableErrorCollection" message. | 181 // Callback for "enableErrorCollection" message. |
178 void HandleEnableErrorCollectionMessage(const base::ListValue* args); | 182 void HandleEnableErrorCollectionMessage(const base::ListValue* args); |
179 | 183 |
180 // Callback for "allowFileAcces" message. | 184 // Callback for "allowFileAcces" message. |
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
225 const std::set<content::RenderViewHost*>& views, | 229 const std::set<content::RenderViewHost*>& views, |
226 std::vector<ExtensionPage>* result); | 230 std::vector<ExtensionPage>* result); |
227 void GetAppWindowPagesForExtensionProfile(const Extension* extension, | 231 void GetAppWindowPagesForExtensionProfile(const Extension* extension, |
228 Profile* profile, | 232 Profile* profile, |
229 std::vector<ExtensionPage>* result); | 233 std::vector<ExtensionPage>* result); |
230 | 234 |
231 // Returns the ExtensionUninstallDialog object for this class, creating it if | 235 // Returns the ExtensionUninstallDialog object for this class, creating it if |
232 // needed. | 236 // needed. |
233 ExtensionUninstallDialog* GetExtensionUninstallDialog(); | 237 ExtensionUninstallDialog* GetExtensionUninstallDialog(); |
234 | 238 |
| 239 // Called when the reinstallation is complete. |
| 240 void OnReinstallComplete(bool success, |
| 241 const std::string& error, |
| 242 webstore_install::Result result); |
| 243 |
235 // Callback for RequirementsChecker. | 244 // Callback for RequirementsChecker. |
236 void OnRequirementsChecked(std::string extension_id, | 245 void OnRequirementsChecked(std::string extension_id, |
237 std::vector<std::string> requirement_errors); | 246 std::vector<std::string> requirement_errors); |
238 | 247 |
239 // Handles the load retry notification sent from | 248 // Handles the load retry notification sent from |
240 // ExtensionService::ReportExtensionLoadError. Attempts to retry loading | 249 // ExtensionService::ReportExtensionLoadError. Attempts to retry loading |
241 // extension from |path| if retry is true, otherwise removes |path| from the | 250 // extension from |path| if retry is true, otherwise removes |path| from the |
242 // vector of currently loading extensions. | 251 // vector of currently loading extensions. |
243 // | 252 // |
244 // Does nothing if |path| is not a currently loading extension this object is | 253 // Does nothing if |path| is not a currently loading extension this object is |
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
308 // Whether we found any DISABLE_NOT_VERIFIED extensions and want to kick off | 317 // Whether we found any DISABLE_NOT_VERIFIED extensions and want to kick off |
309 // a verification check to try and rescue them. | 318 // a verification check to try and rescue them. |
310 bool should_do_verification_check_; | 319 bool should_do_verification_check_; |
311 | 320 |
312 DISALLOW_COPY_AND_ASSIGN(ExtensionSettingsHandler); | 321 DISALLOW_COPY_AND_ASSIGN(ExtensionSettingsHandler); |
313 }; | 322 }; |
314 | 323 |
315 } // namespace extensions | 324 } // namespace extensions |
316 | 325 |
317 #endif // CHROME_BROWSER_UI_WEBUI_EXTENSIONS_EXTENSION_SETTINGS_HANDLER_H_ | 326 #endif // CHROME_BROWSER_UI_WEBUI_EXTENSIONS_EXTENSION_SETTINGS_HANDLER_H_ |
OLD | NEW |