| Index: chrome/browser/extensions/extension_install_ui.cc
|
| diff --git a/chrome/browser/extensions/extension_install_ui.cc b/chrome/browser/extensions/extension_install_ui.cc
|
| index 17127919c985fb03bbc216d567b16e63156fcdb4..ae13fc5002a01571281be02b360029734720edac 100644
|
| --- a/chrome/browser/extensions/extension_install_ui.cc
|
| +++ b/chrome/browser/extensions/extension_install_ui.cc
|
| @@ -16,6 +16,9 @@
|
| #include "chrome/browser/extensions/theme_installed_infobar_delegate.h"
|
| #include "chrome/browser/profile.h"
|
| #include "chrome/browser/tab_contents/tab_contents.h"
|
| +#if defined(TOOLKIT_VIEWS) // TODO(port)
|
| +#include "chrome/browser/views/extensions/extension_installed_bubble.h"
|
| +#endif // TOOLKIT_VIEWS
|
| #include "chrome/common/extensions/extension.h"
|
| #include "chrome/common/notification_service.h"
|
| #include "grit/browser_resources.h"
|
| @@ -113,19 +116,35 @@ void ExtensionInstallUI::ConfirmInstall(Delegate* delegate,
|
| install_icon = ResourceBundle::GetSharedInstance().GetBitmapNamed(
|
| IDR_EXTENSIONS_SECTION);
|
| }
|
| + icon_ = *install_icon;
|
|
|
| NotificationService* service = NotificationService::current();
|
| service->Notify(NotificationType::EXTENSION_WILL_SHOW_CONFIRM_DIALOG,
|
| Source<ExtensionInstallUI>(this),
|
| NotificationService::NoDetails());
|
|
|
| - ShowExtensionInstallPrompt(profile_, delegate, extension, install_icon,
|
| + ShowExtensionInstallPrompt(profile_, delegate, extension, &icon_,
|
| GetInstallWarning(extension));
|
| -
|
| }
|
|
|
| void ExtensionInstallUI::OnInstallSuccess(Extension* extension) {
|
| - ShowThemeInfoBar(extension);
|
| + if (extension->IsTheme()) {
|
| + ShowThemeInfoBar(extension);
|
| + return;
|
| + }
|
| +
|
| +#if defined(TOOLKIT_VIEWS)
|
| + // GetLastActiveWithProfile will fail on the build bots. This needs to
|
| + // implemented differently if any test is created which depends on
|
| + // ExtensionInstalledBubble showing.
|
| + Browser* browser = BrowserList::GetLastActiveWithProfile(profile_);
|
| + if (!browser)
|
| + return;
|
| +
|
| + ExtensionInstalledBubble::Show(extension, browser, icon_);
|
| +#else
|
| +// TODO(port) crbug.com/26973 (linux) crbug.com/26974 (mac)
|
| +#endif // TOOLKIT_VIEWS
|
| }
|
|
|
| void ExtensionInstallUI::OnInstallFailure(const std::string& error) {
|
|
|