Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(287)

Unified Diff: chrome/browser/ui/webui/ntp/app_launcher_handler.cc

Issue 7920023: Fix crashes related to the extension uninstall dialog. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/webui/ntp/app_launcher_handler.cc
diff --git a/chrome/browser/ui/webui/ntp/app_launcher_handler.cc b/chrome/browser/ui/webui/ntp/app_launcher_handler.cc
index ada3dd98dada3836195fbd6e6e702ef4be1a987e..9e494e74e0904102ecf4a1e41ada6575bbcf62ae 100644
--- a/chrome/browser/ui/webui/ntp/app_launcher_handler.cc
+++ b/chrome/browser/ui/webui/ntp/app_launcher_handler.cc
@@ -641,9 +641,9 @@ void AppLauncherHandler::HandleUninstallApp(const ListValue* args) {
scoped_ptr<AutoReset<bool> > auto_reset;
if (NewTabUI::NTP4Enabled())
auto_reset.reset(new AutoReset<bool>(&ignore_changes_, true));
- ExtensionDialogAccepted();
+ ExtensionUninstallAccepted();
} else {
- GetExtensionUninstallDialog()->ConfirmUninstall(this, extension);
+ GetExtensionUninstallUI()->ConfirmUninstall(this, extension);
}
}
@@ -912,7 +912,7 @@ void AppLauncherHandler::PromptToEnableApp(const std::string& extension_id) {
GetExtensionInstallUI()->ConfirmReEnable(this, extension);
}
-void AppLauncherHandler::ExtensionDialogAccepted() {
+void AppLauncherHandler::ExtensionUninstallAccepted() {
// Do the uninstall work here.
DCHECK(!extension_id_prompting_.empty());
@@ -929,7 +929,7 @@ void AppLauncherHandler::ExtensionDialogAccepted() {
extension_id_prompting_ = "";
}
-void AppLauncherHandler::ExtensionDialogCanceled() {
+void AppLauncherHandler::ExtensionUninstallCanceled() {
extension_id_prompting_ = "";
}
@@ -957,7 +957,7 @@ void AppLauncherHandler::InstallUIProceed() {
}
void AppLauncherHandler::InstallUIAbort(bool user_initiated) {
- // We record the histograms here because ExtensionDialogCanceled is also
+ // We record the histograms here because ExtensionUninstallCanceled is also
// called when the extension uninstall dialog is canceled.
const Extension* extension =
extension_service_->GetExtensionById(extension_id_prompting_, true);
@@ -967,15 +967,15 @@ void AppLauncherHandler::InstallUIAbort(bool user_initiated) {
ExtensionService::RecordPermissionMessagesHistogram(
extension, histogram_name.c_str());
- ExtensionDialogCanceled();
+ ExtensionUninstallCanceled();
}
-ExtensionUninstallDialog* AppLauncherHandler::GetExtensionUninstallDialog() {
- if (!extension_uninstall_dialog_.get()) {
- extension_uninstall_dialog_.reset(
- new ExtensionUninstallDialog(Profile::FromWebUI(web_ui_)));
+ExtensionUninstallUI* AppLauncherHandler::GetExtensionUninstallUI() {
+ if (!extension_uninstall_ui_.get()) {
+ extension_uninstall_ui_.reset(
+ new ExtensionUninstallUI(Profile::FromWebUI(web_ui_)));
}
- return extension_uninstall_dialog_.get();
+ return extension_uninstall_ui_.get();
}
ExtensionInstallUI* AppLauncherHandler::GetExtensionInstallUI() {

Powered by Google App Engine
This is Rietveld 408576698