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_EXTENSIONS_CRX_INSTALLER_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_CRX_INSTALLER_H_ |
6 #define CHROME_BROWSER_EXTENSIONS_CRX_INSTALLER_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_CRX_INSTALLER_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
(...skipping 216 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
227 const SkBitmap& install_icon) OVERRIDE; | 227 const SkBitmap& install_icon) OVERRIDE; |
228 | 228 |
229 // Called on the UI thread to start the requirements check on the extension. | 229 // Called on the UI thread to start the requirements check on the extension. |
230 void CheckImportsAndRequirements(); | 230 void CheckImportsAndRequirements(); |
231 | 231 |
232 // Runs on the UI thread. Callback from RequirementsChecker. | 232 // Runs on the UI thread. Callback from RequirementsChecker. |
233 void OnRequirementsChecked(std::vector<std::string> requirement_errors); | 233 void OnRequirementsChecked(std::vector<std::string> requirement_errors); |
234 | 234 |
235 // Runs on the UI thread. Callback from Blacklist. | 235 // Runs on the UI thread. Callback from Blacklist. |
236 void OnBlacklistChecked( | 236 void OnBlacklistChecked( |
237 extensions::Blacklist::BlacklistState blacklist_state); | 237 extensions::BlacklistState blacklist_state); |
238 | 238 |
239 // Runs on the UI thread. Confirms the installation to the ExtensionService. | 239 // Runs on the UI thread. Confirms the installation to the ExtensionService. |
240 void ConfirmInstall(); | 240 void ConfirmInstall(); |
241 | 241 |
242 // Runs on File thread. Install the unpacked extension into the profile and | 242 // Runs on File thread. Install the unpacked extension into the profile and |
243 // notify the frontend. | 243 // notify the frontend. |
244 void CompleteInstall(); | 244 void CompleteInstall(); |
245 | 245 |
246 // Result reporting. | 246 // Result reporting. |
247 void ReportFailureFromFileThread(const CrxInstallerError& error); | 247 void ReportFailureFromFileThread(const CrxInstallerError& error); |
(...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
383 // still consider the installation 'handled'. | 383 // still consider the installation 'handled'. |
384 bool did_handle_successfully_; | 384 bool did_handle_successfully_; |
385 | 385 |
386 // Whether we should produce an error if the manifest declares requirements | 386 // Whether we should produce an error if the manifest declares requirements |
387 // that are not met. If false and there is an unmet requirement, the install | 387 // that are not met. If false and there is an unmet requirement, the install |
388 // will continue but the extension will be distabled. | 388 // will continue but the extension will be distabled. |
389 bool error_on_unsupported_requirements_; | 389 bool error_on_unsupported_requirements_; |
390 | 390 |
391 bool has_requirement_errors_; | 391 bool has_requirement_errors_; |
392 | 392 |
393 extensions::Blacklist::BlacklistState blacklist_state_; | 393 extensions::BlacklistState blacklist_state_; |
394 | 394 |
395 bool install_wait_for_idle_; | 395 bool install_wait_for_idle_; |
396 | 396 |
397 // Sequenced task runner where file I/O operations will be performed. | 397 // Sequenced task runner where file I/O operations will be performed. |
398 scoped_refptr<base::SequencedTaskRunner> installer_task_runner_; | 398 scoped_refptr<base::SequencedTaskRunner> installer_task_runner_; |
399 | 399 |
400 // Used to show the install dialog. | 400 // Used to show the install dialog. |
401 ExtensionInstallPrompt::ShowDialogCallback show_dialog_callback_; | 401 ExtensionInstallPrompt::ShowDialogCallback show_dialog_callback_; |
402 | 402 |
403 // Whether the update is initiated by the user from the extension settings | 403 // Whether the update is initiated by the user from the extension settings |
404 // page. | 404 // page. |
405 bool update_from_settings_page_; | 405 bool update_from_settings_page_; |
406 | 406 |
407 // Gives access to common methods and data of an extension installer. | 407 // Gives access to common methods and data of an extension installer. |
408 ExtensionInstaller installer_; | 408 ExtensionInstaller installer_; |
409 | 409 |
410 DISALLOW_COPY_AND_ASSIGN(CrxInstaller); | 410 DISALLOW_COPY_AND_ASSIGN(CrxInstaller); |
411 }; | 411 }; |
412 | 412 |
413 } // namespace extensions | 413 } // namespace extensions |
414 | 414 |
415 #endif // CHROME_BROWSER_EXTENSIONS_CRX_INSTALLER_H_ | 415 #endif // CHROME_BROWSER_EXTENSIONS_CRX_INSTALLER_H_ |
OLD | NEW |