chrome::ScopedTabbedBrowserDisplayer displayer(
profile(), chrome::GetHostDesktopTypeForNativeWindow(parent_window_));
chrome::NavigateParams params(
- displayer.browser(), launch_url, content::PAGE_TRANSITION_AUTO_TOPLEVEL);
+ displayer.browser(), launch_url, ui::PAGE_TRANSITION_AUTO_TOPLEVEL);
params.disposition = NEW_FOREGROUND_TAB;
chrome::Navigate(¶ms);
return true;
}
void EphemeralAppLauncher::OnManifestParsed() {
- const Extension* extension = GetLocalizedExtensionForDisplay();
- if (!extension) {
+ scoped_refptr<const Extension> extension = GetLocalizedExtensionForDisplay();
+ if (!extension.get()) {
AbortLaunch(webstore_install::INVALID_MANIFEST, kInvalidManifestError);
return;
}
webstore_install::Result result = webstore_install::OTHER_ERROR;
std::string error;
- if (!CheckCommonLaunchCriteria(profile(), extension, &result, &error)) {
+ if (!CheckCommonLaunchCriteria(profile(), extension.get(), &result, &error)) {
AbortLaunch(result, error);
return;
}
if (extension->is_hosted_app()) {
// Hosted apps do not need to be installed ephemerally. Just navigate to
// their launch url.
- if (LaunchHostedApp(extension))
+ if (LaunchHostedApp(extension.get()))
AbortLaunch(webstore_install::SUCCESS, std::string());
else
AbortLaunch(webstore_install::INVALID_MANIFEST, kInvalidManifestError);