| Index: chrome/browser/extensions/unpacked_installer.h
|
| diff --git a/chrome/browser/extensions/unpacked_installer.h b/chrome/browser/extensions/unpacked_installer.h
|
| index 6b48857aecdb039279a992d392c49f8c72063755..a45eec10ec557b3408deb874868132c3e60a78a7 100644
|
| --- a/chrome/browser/extensions/unpacked_installer.h
|
| +++ b/chrome/browser/extensions/unpacked_installer.h
|
| @@ -12,6 +12,7 @@
|
| #include "base/memory/ref_counted.h"
|
| #include "base/memory/scoped_ptr.h"
|
| #include "base/memory/weak_ptr.h"
|
| +#include "chrome/browser/extensions/app_host_installer.h"
|
|
|
| class ExtensionService;
|
|
|
| @@ -70,11 +71,11 @@ class UnpackedInstaller
|
| // Verifies if loading unpacked extensions is allowed.
|
| bool IsLoadingUnpackedAllowed() const;
|
|
|
| - // We change the input extension path to an absolute path, on the file thread.
|
| + // We change the input extension path to an absolute path, on the FILE thread.
|
| // Then we need to check the file access preference, which needs
|
| // to happen back on the UI thread, so it posts CheckExtensionFileAccess on
|
| // the UI thread. In turn, once that gets the pref, it goes back to the
|
| - // file thread with LoadWithFileAccess.
|
| + // FILE thread with LoadWithFileAccess.
|
| // TODO(yoz): It would be nice to remove this ping-pong, but we need to know
|
| // what file access flags to pass to extension_file_util::LoadExtension.
|
| void GetAbsolutePath();
|
| @@ -87,6 +88,19 @@ class UnpackedInstaller
|
| // Called when an unpacked extension has been loaded and installed.
|
| void OnLoaded();
|
|
|
| + // Runs on UI thread. If App Host is not installed, calls installer and
|
| + // posts OnAppHostInstallationComplete() as call back. Else proceeds to
|
| + // CompleteInstall().
|
| + void BeginInstall();
|
| +
|
| + // Runs on UI thread. Callback function for AppHostInstaller.
|
| + // If not |success|, shows error message. Else proceeds to CompleteInstall().
|
| + void OnAppHostInstallation(bool success);
|
| +
|
| + // Runs on UI thread. Installs the unpacked extension into the profile and
|
| + // notifies the frontend.
|
| + void CompleteInstall();
|
| +
|
| // Helper to get the Extension::CreateFlags for the installing extension.
|
| int GetFlags();
|
|
|
| @@ -108,6 +122,9 @@ class UnpackedInstaller
|
| // version.
|
| bool require_modern_manifest_version_;
|
|
|
| + // Helper to install App Host.
|
| + AppHostInstaller app_host_installer_;
|
| +
|
| DISALLOW_COPY_AND_ASSIGN(UnpackedInstaller);
|
| };
|
|
|
|
|