1
0
mirror of https://github.com/SKCraft/Launcher.git synced 2024-11-24 12:16:28 +01:00

Add confirmation dialog for forgetting accounts

This commit is contained in:
Henry Le Grys 2021-02-09 01:41:49 +00:00
parent 3effa7d674
commit 2ec8180d2a
2 changed files with 8 additions and 1 deletions

View File

@ -111,7 +111,12 @@ public class AccountSelectDialog extends JDialog {
removeSelected.addActionListener(ev -> {
if (accountList.getSelectedValue() != null) {
launcher.getAccounts().remove(accountList.getSelectedValue());
boolean confirmed = SwingHelper.confirmDialog(this, SharedLocale.tr("accounts.confirmForget"),
SharedLocale.tr("accounts.confirmForgetTitle"));
if (confirmed) {
launcher.getAccounts().remove(accountList.getSelectedValue());
}
}
});

View File

@ -93,6 +93,8 @@ accounts.refreshingStatus=Refreshing login session...
accounts.addMojang=Add Mojang account
accounts.addMicrosoft=Add Microsoft account
accounts.removeSelected=Forget selected account
accounts.confirmForgetTitle=Forget account
accounts.confirmForget=Are you sure that you want to forget that account?
login.login=Login...
login.recoverAccount=Forgot your login?