OSDN Git Service

ProgressDialog: Require user to explicitly use the cancel button.
authorStephen Bird <sbird@cyngn.com>
Wed, 15 Jul 2015 19:32:23 +0000 (12:32 -0700)
committerStephen Bird <sbird@cyngn.com>
Thu, 16 Jul 2015 17:44:35 +0000 (10:44 -0700)
This prevents accidental touches outside of the dialog during long operations

Change-Id: I5d903a56aa8e72963967629bd4d844d19e3922dc

src/com/cyanogenmod/filemanager/ui/dialogs/MessageProgressDialog.java

index 9ddc300..4fb0fba 100644 (file)
@@ -118,6 +118,7 @@ public class MessageProgressDialog implements DialogInterface.OnClickListener {
                                         titleResourceId,
                                         layout);
         this.mDialog.setCancelable(cancellable);
+        this.mDialog.setCanceledOnTouchOutside(false);
         if (cancellable) {
             this.mDialog.setButton(
                     DialogInterface.BUTTON_NEUTRAL, context.getString(android.R.string.cancel), this);