diff options
author | André Glüpker <git@wgmd.de> | 2016-03-22 16:35:59 +0100 |
---|---|---|
committer | André Glüpker <git@wgmd.de> | 2016-03-22 16:35:59 +0100 |
commit | c1108bfad7919d2cd0df1cfeef0ef720110210db (patch) | |
tree | 88a6249f5669a3de7305c35f8b88632fea955a88 | |
parent | 52b0ada6565e7ca76db2ba0b6b36596cd3500cb8 (diff) | |
download | 9kwpyqt-c1108bfad7919d2cd0df1cfeef0ef720110210db.tar.gz 9kwpyqt-c1108bfad7919d2cd0df1cfeef0ef720110210db.tar.bz2 9kwpyqt-c1108bfad7919d2cd0df1cfeef0ef720110210db.zip |
Debugfunction to save current image (commented out)
-rwxr-xr-x | 9kwpyqt.py | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -71,15 +71,18 @@ class CaptchaGUI(QWidget): self.captchaInputLine = QLineEdit() self.startstopButton = QPushButton("Start") self.startstopButton.setCheckable(True) + # self.saveImageButton = QPushButton("Sa&ve Image") self.submitButton = QPushButton("&Submit") self.skipButton = QPushButton("S&kip") self.startstopButton.clicked.connect(self.toggleRunning) + # self.saveImageButton.clicked.connect(self.saveImage) self.submitButton.clicked.connect(self.submitCaptcha) self.skipButton.clicked.connect(self.skipCaptcha) self.LayoutSubmitLine = QHBoxLayout() self.LayoutSubmitLine.addWidget(self.startstopButton) self.LayoutSubmitLine.addWidget(self.captchaInputLine) + # self.LayoutSubmitLine.addWidget(self.saveImageButton) self.LayoutSubmitButtons = QHBoxLayout() self.LayoutSubmitButtons.addWidget(self.submitButton) @@ -174,6 +177,10 @@ class CaptchaGUI(QWidget): self.startstopButton.setText(self.running and "Stop" or "Start") self.startstopButton.setChecked(self.running) + def saveImage(self): + if self.image: + self.image.save("captcha-"+str(time.time())+".jpg") + ################################################## # Handle network ################################################## |