Prompt before resetting keys

This commit is contained in:
Valere 2020-02-01 15:19:49 +01:00
parent 282be29247
commit 26400e6372

View File

@ -120,6 +120,12 @@ class CrossSigningSettingsFragment @Inject constructor(
}
override fun onResetCrossSigningKeys() {
viewModel.handle(CrossSigningAction.InitializeCrossSigning())
AlertDialog.Builder(requireContext())
.setTitle(R.string.dialog_title_confirmation)
.setMessage(R.string.are_you_sure)
.setPositiveButton(R.string.ok) { _, _ ->
viewModel.handle(CrossSigningAction.InitializeCrossSigning())
}
.show()
}
}