| Index: chrome/browser/ui/views/app_list/app_list_controller_win.cc
|
| diff --git a/chrome/browser/ui/views/app_list/app_list_controller_win.cc b/chrome/browser/ui/views/app_list/app_list_controller_win.cc
|
| index ecf13d706027b83058eee9e0a574392112a44ec0..4c490cfa4b43be97cd5c854c8e39cb0469345f7b 100644
|
| --- a/chrome/browser/ui/views/app_list/app_list_controller_win.cc
|
| +++ b/chrome/browser/ui/views/app_list/app_list_controller_win.cc
|
| @@ -191,6 +191,9 @@ class AppListController : public ProfileInfoCacheObserver {
|
| const std::string& extension_id,
|
| const std::string& extension_name,
|
| const gfx::ImageSkia& installing_icon);
|
| + void OnDownloadProgress(Profile* profile,
|
| + const std::string& extension_id,
|
| + int percent_downloaded);
|
|
|
| private:
|
| // Loads a profile asynchronously and calls OnProfileLoaded() when done.
|
| @@ -546,6 +549,18 @@ void AppListController::OnBeginExtensionInstall(
|
| installing_icon);
|
| }
|
|
|
| +void AppListController::OnDownloadProgress(Profile* profile,
|
| + const std::string& extension_id,
|
| + int percent_downloaded) {
|
| + // We only have a model for the current profile, so ignore events about
|
| + // others.
|
| + // TODO(koz): We should keep a model for each profile so we can record
|
| + // information like this.
|
| + if (profile != profile_)
|
| + return;
|
| + view_delegate_->OnDownloadProgress(extension_id, percent_downloaded);
|
| +}
|
| +
|
| // Attempts to find the bounds of the Windows taskbar. Returns true on success.
|
| // |rect| is in screen coordinates. If the taskbar is in autohide mode and is
|
| // not visible, |rect| will be outside the current monitor's bounds, except for
|
| @@ -859,4 +874,12 @@ void NotifyAppListOfBeginExtensionInstall(
|
| installing_icon);
|
| }
|
|
|
| +void NotifyAppListOfDownloadProgress(
|
| + Profile* profile,
|
| + const std::string& extension_id,
|
| + int percent_downloaded) {
|
| + g_app_list_controller.Get().OnDownloadProgress(profile, extension_id,
|
| + percent_downloaded);
|
| +}
|
| +
|
| } // namespace chrome
|
|
|