diff options
author | André Glüpker <git@wgmd.de> | 2016-03-19 13:24:35 +0100 |
---|---|---|
committer | André Glüpker <git@wgmd.de> | 2016-03-19 13:24:35 +0100 |
commit | 2e51508ac4ae567438c42f2e73dc33f4a0323f11 (patch) | |
tree | 2acd11f510bab1da45d4b714315d2e519037f516 | |
parent | f17bb3bddb0e5774e78bb4b30a2f136e31f29a20 (diff) | |
download | 9kwpyqt-2e51508ac4ae567438c42f2e73dc33f4a0323f11.tar.gz 9kwpyqt-2e51508ac4ae567438c42f2e73dc33f4a0323f11.tar.bz2 9kwpyqt-2e51508ac4ae567438c42f2e73dc33f4a0323f11.zip |
little bugfixes
- startstopButton Focus
- Committing/Skipping while paused
-rwxr-xr-x | 9kwpyqt.py | 7 |
1 files changed, 6 insertions, 1 deletions
@@ -115,6 +115,8 @@ class CaptchaGUI(QWidget): self.timer.timeout.connect(self.onTimeout) self.timer.setSingleShot(True) + self.startstopButton.setFocus() + ################################################## # Handle gui ################################################## @@ -140,6 +142,8 @@ class CaptchaGUI(QWidget): elif key == Qt.Key_Enter or key == Qt.Key_Return: if self.skipButton.hasFocus(): self.skipCaptcha() + elif self.startstopButton.hasFocus(): + self.toggleRunning() else: self.submitCaptcha() @@ -302,9 +306,10 @@ class CaptchaGUI(QWidget): if not answer: skip = True self.timer.stop() - self.setCaptchaAnswer(answer, skip) self.captchaInputLine.setText("") self.removeCaptchaImage() + if self.currentCaptchaID: + self.setCaptchaAnswer(answer, skip) def onTimeout(self): self.running = False |