Beispiel #1
0
class CaptureConfigWidget(QtGui.QWidget):
    def __init__(self, parent=None):
        super(CaptureConfigWidget, self).__init__(parent)
        self.ui = Ui_CaptureConfig()
        self.ui.setupUi(self)
        self.ui.chooseDirectoryButton.clicked.connect(self._chooseDirCallback)
        #self.ui.baseLPFileBrowseButton.clicked.connect(self._baseLPFileBrowseCallback)

    def setDoCaptureCallback(self, callback):
        self.ui.beginCaptureButton.clicked.connect(callback)

    def setSaveDir(self, chooseDir):
        self.ui.saveDirectoryLineEdit.setText(chooseDir)

    def _chooseDirCallback(self):
        self.ui.saveDirectoryLineEdit.setText(
            QtGui.QFileDialog.getExistingDirectory(self,
                                                   "Open Save Directory"))

    def getSaveDir(self):
        return self.ui.saveDirectoryLineEdit.text()

    #def _baseLPFileBrowseCallback(self):
    #    self.ui.baseLPFileLineEdit.setText(QtGui.QFileDialog.getOpenFileName(self, "Select Base LP File"))

    #def getLPGenSelected(self):
    #    return self.ui.generateLPFileGroupBox.isChecked()

    #def getBaseLPFilePath(self):
    #    return self.ui.baseLPFileLineEdit.text()

    def getAttemptAutofocus(self):
        return self.ui.autofocusGroupBox.isChecked()
Beispiel #2
0
 def __init__(self, parent=None):
     super(CaptureConfigWidget, self).__init__(parent)
     self.ui = Ui_CaptureConfig()
     self.ui.setupUi(self)
     self.ui.chooseDirectoryButton.clicked.connect(self._chooseDirCallback)