|
@@ -252,7 +252,27 @@ public class InviteRegisterActivity extends BaseMVPActivity {
|
|
|
})
|
|
})
|
|
|
.open();
|
|
.open();
|
|
|
} else if (android.R.id.home == item.getItemId()) {
|
|
} else if (android.R.id.home == item.getItemId()) {
|
|
|
- onBackPressed();
|
|
|
|
|
|
|
+ int visibility = mSuccessLinearLayout.getVisibility();
|
|
|
|
|
+ if (visibility == View.GONE) {
|
|
|
|
|
+ new MaterialDialog.Builder(this).title(R.string.common_notice)
|
|
|
|
|
+ .content(R.string.register_unsuccessed_sure_to_exit)
|
|
|
|
|
+ .negativeText(R.string.cancel)
|
|
|
|
|
+ .onNegative(new MaterialDialog.SingleButtonCallback() {
|
|
|
|
|
+ @Override
|
|
|
|
|
+ public void onClick(@NonNull MaterialDialog materialDialog, @NonNull DialogAction dialogAction) {
|
|
|
|
|
+ materialDialog.dismiss();
|
|
|
|
|
+ }
|
|
|
|
|
+ })
|
|
|
|
|
+ .positiveText(R.string.sure)
|
|
|
|
|
+ .onPositive(new MaterialDialog.SingleButtonCallback() {
|
|
|
|
|
+ @Override
|
|
|
|
|
+ public void onClick(@NonNull MaterialDialog materialDialog, @NonNull DialogAction dialogAction) {
|
|
|
|
|
+ InviteRegisterActivity.this.finish();
|
|
|
|
|
+ }
|
|
|
|
|
+ }).build().show();
|
|
|
|
|
+ } else {
|
|
|
|
|
+ onBackPressed();
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
return true;
|
|
return true;
|
|
|
}
|
|
}
|