From 3187632e0acd426b8be9576e149bdfd427956c25 Mon Sep 17 00:00:00 2001 From: Adam Powell Date: Thu, 23 Jun 2011 12:02:27 -0700 Subject: [PATCH] Fix bug 4904520 - Swap force close/report buttons Make the force close dialogs consistent with both the new rules for wizardy-button bar UI flows and the previous arrangement that people are used to. Force close = negative/back/cancel, Report = positive/next/ok. Change-Id: I212ba172f8076238a1833100b025b6e25a538a65 --- services/java/com/android/server/am/AppErrorDialog.java | 4 ++-- .../java/com/android/server/am/AppNotRespondingDialog.java | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/services/java/com/android/server/am/AppErrorDialog.java b/services/java/com/android/server/am/AppErrorDialog.java index a769c05c16486..917259acf1b55 100644 --- a/services/java/com/android/server/am/AppErrorDialog.java +++ b/services/java/com/android/server/am/AppErrorDialog.java @@ -60,12 +60,12 @@ class AppErrorDialog extends BaseErrorDialog { setCancelable(false); - setButton(DialogInterface.BUTTON_POSITIVE, + setButton(DialogInterface.BUTTON_NEGATIVE, res.getText(com.android.internal.R.string.force_close), mHandler.obtainMessage(FORCE_QUIT)); if (app.errorReportReceiver != null) { - setButton(DialogInterface.BUTTON_NEGATIVE, + setButton(DialogInterface.BUTTON_POSITIVE, res.getText(com.android.internal.R.string.report), mHandler.obtainMessage(FORCE_QUIT_AND_REPORT)); } diff --git a/services/java/com/android/server/am/AppNotRespondingDialog.java b/services/java/com/android/server/am/AppNotRespondingDialog.java index b2737dcd23aab..b40f87a90edbf 100644 --- a/services/java/com/android/server/am/AppNotRespondingDialog.java +++ b/services/java/com/android/server/am/AppNotRespondingDialog.java @@ -77,7 +77,7 @@ class AppNotRespondingDialog extends BaseErrorDialog { ? res.getString(resid, name1.toString(), name2.toString()) : res.getString(resid, name1.toString())); - setButton(DialogInterface.BUTTON_POSITIVE, + setButton(DialogInterface.BUTTON_NEGATIVE, res.getText(com.android.internal.R.string.force_close), mHandler.obtainMessage(FORCE_CLOSE)); setButton(DialogInterface.BUTTON_NEUTRAL, @@ -85,7 +85,7 @@ class AppNotRespondingDialog extends BaseErrorDialog { mHandler.obtainMessage(WAIT)); if (app.errorReportReceiver != null) { - setButton(DialogInterface.BUTTON_NEGATIVE, + setButton(DialogInterface.BUTTON_POSITIVE, res.getText(com.android.internal.R.string.report), mHandler.obtainMessage(WAIT_AND_REPORT)); }