This commit is contained in:
Tim Bentley 2011-03-07 19:58:51 +00:00
parent 3eb8ca476b
commit c3c4e85590
1 changed files with 8 additions and 4 deletions

View File

@ -66,6 +66,9 @@ class FirstTimeForm(QtGui.QWizard, Ui_FirstTimeWizard):
'Starting Updates') 'Starting Updates')
self.downloading = unicode(translate('OpenLP.FirstTimeWizard', self.downloading = unicode(translate('OpenLP.FirstTimeWizard',
'Downloading %s')) 'Downloading %s'))
QtCore.QObject.connect(self,
QtCore.SIGNAL(u'currentIdChanged(int)'),
self.onCurrentIdChanged)
def exec_(self, edit=False): def exec_(self, edit=False):
""" """
@ -116,12 +119,11 @@ class FirstTimeForm(QtGui.QWizard, Ui_FirstTimeWizard):
child.setFlags(QtCore.Qt.ItemIsUserCheckable | child.setFlags(QtCore.Qt.ItemIsUserCheckable |
QtCore.Qt.ItemIsSelectable | QtCore.Qt.ItemIsEnabled) 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 self.page(pageId) == self.DefaultsPage:
if wizardPage == self.DefaultsPage:
listIterator = QtGui.QTreeWidgetItemIterator( listIterator = QtGui.QTreeWidgetItemIterator(
self.selectionTreeWidget) self.selectionTreeWidget)
while listIterator.value(): while listIterator.value():
@ -134,6 +136,7 @@ class FirstTimeForm(QtGui.QWizard, Ui_FirstTimeWizard):
listIterator += 1 listIterator += 1
def accept(self): def accept(self):
Receiver.send_message(u'cursor_busy')
self._updateMessage(self.startUpdates) self._updateMessage(self.startUpdates)
# Set up the Plugin status's # Set up the Plugin status's
self._pluginStatus(self.songsCheckBox, u'songs/status') self._pluginStatus(self.songsCheckBox, u'songs/status')
@ -197,6 +200,7 @@ class FirstTimeForm(QtGui.QWizard, Ui_FirstTimeWizard):
QtCore.QVariant(self.themeSelectionComboBox.currentText())) QtCore.QVariant(self.themeSelectionComboBox.currentText()))
QtCore.QSettings().setValue(u'general/first time', QtCore.QSettings().setValue(u'general/first time',
QtCore.QVariant(False)) QtCore.QVariant(False))
Receiver.send_message(u'cursor_normal')
return QtGui.QWizard.accept(self) return QtGui.QWizard.accept(self)
def _pluginStatus(self, field, tag): def _pluginStatus(self, field, tag):