forked from openlp/openlp
First time wizard improvements
bzr-revno: 1364
This commit is contained in:
commit
b79f4fcaa0
openlp/core/ui
@ -66,6 +66,9 @@ class FirstTimeForm(QtGui.QWizard, Ui_FirstTimeWizard):
|
||||
'Starting Updates')
|
||||
self.downloading = unicode(translate('OpenLP.FirstTimeWizard',
|
||||
'Downloading %s'))
|
||||
QtCore.QObject.connect(self,
|
||||
QtCore.SIGNAL(u'currentIdChanged(int)'),
|
||||
self.onCurrentIdChanged)
|
||||
|
||||
def exec_(self, edit=False):
|
||||
"""
|
||||
@ -116,12 +119,12 @@ class FirstTimeForm(QtGui.QWizard, Ui_FirstTimeWizard):
|
||||
child.setFlags(QtCore.Qt.ItemIsUserCheckable |
|
||||
QtCore.Qt.ItemIsSelectable | QtCore.Qt.ItemIsEnabled)
|
||||
|
||||
def initializePage(self, id):
|
||||
def onCurrentIdChanged(self, pageId):
|
||||
"""
|
||||
Set up the pages for Initial run through dialog
|
||||
Detects Page changes and updates as approprate.
|
||||
"""
|
||||
wizardPage = self.page(id)
|
||||
if wizardPage == self.DefaultsPage:
|
||||
if self.page(pageId) == self.DefaultsPage:
|
||||
self.themeSelectionComboBox.clear()
|
||||
listIterator = QtGui.QTreeWidgetItemIterator(
|
||||
self.selectionTreeWidget)
|
||||
while listIterator.value():
|
||||
@ -134,6 +137,7 @@ class FirstTimeForm(QtGui.QWizard, Ui_FirstTimeWizard):
|
||||
listIterator += 1
|
||||
|
||||
def accept(self):
|
||||
Receiver.send_message(u'cursor_busy')
|
||||
self._updateMessage(self.startUpdates)
|
||||
# Set up the Plugin status's
|
||||
self._pluginStatus(self.songsCheckBox, u'songs/status')
|
||||
@ -197,6 +201,7 @@ class FirstTimeForm(QtGui.QWizard, Ui_FirstTimeWizard):
|
||||
QtCore.QVariant(self.themeSelectionComboBox.currentText()))
|
||||
QtCore.QSettings().setValue(u'general/first time',
|
||||
QtCore.QVariant(False))
|
||||
Receiver.send_message(u'cursor_normal')
|
||||
return QtGui.QWizard.accept(self)
|
||||
|
||||
def _pluginStatus(self, field, tag):
|
||||
|
@ -224,4 +224,4 @@ class Ui_FirstTimeWizard(object):
|
||||
self.themeSelectionLabel.setText(translate('OpenLP.FirstTimeWizard',
|
||||
'Select the default Theme'))
|
||||
self.messageLabel.setText(translate('OpenLP.FirstTimeWizard',
|
||||
'Press Finish to apply all you changes and start OpenLP'))
|
||||
'Press finish to apply all your changes and start OpenLP'))
|
||||
|
Loading…
Reference in New Issue
Block a user