2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-31 14:38:15 +00:00

select wrong passcode / password when showing error message

This commit is contained in:
John Preston
2015-11-24 13:29:37 +03:00
parent e5c82fad21
commit 3cf4c7f2fc
4 changed files with 6 additions and 4 deletions

View File

@@ -55,13 +55,11 @@ void PasscodeWidget::onParentResize(const QSize &newSize) {
void PasscodeWidget::onSubmit() {
if (_passcode.text().isEmpty()) {
_passcode.setFocus();
_passcode.notaBene();
return;
}
if (!passcodeCanTry()) {
_error = lang(lng_flood_error);
_passcode.setFocus();
_passcode.notaBene();
update();
return;
@@ -100,7 +98,6 @@ void PasscodeWidget::onSubmit() {
void PasscodeWidget::onError() {
_error = lang(lng_passcode_wrong);
_passcode.selectAll();
_passcode.setFocus();
_passcode.notaBene();
update();
}