コード例 #1
0
    def __init__(self):
        super(FirstRunWizardWindow, self).__init__()
        self.ui = Ui_FirstRunWizard()
        self.ui.setupUi(self)
        self.populateConfig()

        # Slots
        self.finished.connect(self.saveConfig)
コード例 #2
0
	def __init__(self):
		super(FirstRunWizardWindow, self).__init__()
		self.ui = Ui_FirstRunWizard()
		self.ui.setupUi(self)
		self.populateConfig()

		# Slots
		self.finished.connect(self.saveConfig)
コード例 #3
0
class FirstRunWizardWindow(QWizard):
	def __init__(self):
		super(FirstRunWizardWindow, self).__init__()
		self.ui = Ui_FirstRunWizard()
		self.ui.setupUi(self)
		self.populateConfig()

		# Slots
		self.finished.connect(self.saveConfig)

	def populateConfig(self):
		# General group
		self.ui.themeDirLineEdit.setText(generate_data_dir())

	def saveConfig(self):
		# Directories group
		config.set('Directories', 'data', os.path.normpath(self.ui.themeDirLineEdit.text()))

		# Wizard group
		config.set('Wizard', 'firstrun', 'False')

		config.save()
コード例 #4
0
class FirstRunWizardWindow(QWizard):
    def __init__(self):
        super(FirstRunWizardWindow, self).__init__()
        self.ui = Ui_FirstRunWizard()
        self.ui.setupUi(self)
        self.populateConfig()

        # Slots
        self.finished.connect(self.saveConfig)

    def populateConfig(self):
        # General group
        self.ui.themeDirLineEdit.setText(generate_data_dir())

    def saveConfig(self):
        # Directories group
        config.set('Directories', 'data',
                   os.path.normpath(self.ui.themeDirLineEdit.text()))

        # Wizard group
        config.set('Wizard', 'firstrun', 'False')

        config.save()