return;
}
}
EnDecryptDialog dialog = new EnDecryptDialog();
dialog.setHint(hint);
while (plainText == null || !dialog.okPressed()) {
dialog.exec();
if (!dialog.okPressed()) {
return;
}
plainText = crypt.decrypt(text, dialog.getPassword().trim(), 64);
if (plainText == null) {
QMessageBox.warning(this, tr("Incorrect Password"), tr("The password entered is not correct"));
}
}
Pair<String,String> passwordPair = new Pair<String,String>();
passwordPair.setFirst(dialog.getPassword());
passwordPair.setSecond(dialog.getHint());
Global.passwordSafe.put(slot, passwordPair);
// removeEncryption(id, plainText.replaceAll("\n", "<br/>"), dialog.permanentlyDecrypt(), slot);
removeEncryption(id, plainText, dialog.permanentlyDecrypt(), slot);
if (dialog.rememberPassword()) {
Pair<String, String> pair = new Pair<String,String>();
pair.setFirst(dialog.getPassword());
pair.setSecond(dialog.getHint());
Global.passwordRemember.add(pair);
}
}