Fix broken cancel button on the login window (bug 373)
authorWuzzy <Wuzzy2@mail.ru>
Sun, 29 Oct 2017 19:56:35 +0100
changeset 12804 e6af1eb9e8ce
parent 12803 fdb3730aa0e2
child 12805 5bdb2f43641e
Fix broken cancel button on the login window (bug #373)
ChangeLog.txt
QTfrontend/hwform.cpp
--- a/ChangeLog.txt	Sun Oct 29 19:06:02 2017 +0100
+++ b/ChangeLog.txt	Sun Oct 29 19:56:35 2017 +0100
@@ -337,6 +337,7 @@
  * Weapons scheme editor: When leaving, it no longer flickers and the selection is not reset to Default
  * Team editor: Fix old team being retained when renaming a team
  * Team editor: Automatically rename team when leaving team editor page with an already used team name
+ * Fix broken cancel button in the login window
 
 Content Creation:
  + Theme objects can now have more than 1 in-land rect specified. You can specify the amount in theme.cfg by adding another number (and a comma) before the first rect
--- a/QTfrontend/hwform.cpp	Sun Oct 29 19:06:02 2017 +0100
+++ b/QTfrontend/hwform.cpp	Sun Oct 29 19:56:35 2017 +0100
@@ -1526,11 +1526,11 @@
                 pwDialog->lePassword->setFocus();
             }
 
-            //if dialog close, create an error message
+            //if dialog aborted, return failure
             if (pwDialog->exec() != QDialog::Accepted) {
                 delete pwDialog;
                 GoBack();
-                break;
+                return 1;
             }
 
             //set nick and pass from the dialog