Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 9a4d5020 authored by Roman Birg's avatar Roman Birg
Browse files

Settings: make FRP wipe dialog not cancelable



User should not be able to interact with the screen after the process
has started. Otherwise we can get in a bad state and never perform the
factory reset.

Ref: CYNGNOS-427
Change-Id: I197a6ca70487a33b0ce402fda7a2d58828e8e1bb
Signed-off-by: default avatarRoman Birg <roman@cyngn.com>
(cherry picked from commit 1f6f2874)
parent 4107ea08
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -83,6 +83,7 @@ public class MasterClearConfirm extends DialogFragment {
        public void onCreate(Bundle savedInstanceState) {
            super.onCreate(savedInstanceState);
            setShowsDialog(true);
            setCancelable(false);
        }

        @Override
@@ -115,10 +116,10 @@ public class MasterClearConfirm extends DialogFragment {

                @Override
                protected void onPostExecute(Void aVoid) {
                    FrpDialog.this.dismiss();
                    doMasterClear(getActivity(),
                            getArguments().getBoolean(MasterClear.EXTRA_WIPE_MEDIA),
                            getArguments().getBoolean(MasterClear.EXTRA_WIPE_SDCARD));
                    FrpDialog.this.dismiss();
                }
            }.execute();
        }