← Back to team overview

openlp-core team mailing list archive

[Merge] lp:~googol/openlp/fixes3 into lp:openlp

 

Andreas Preikschat has proposed merging lp:~googol/openlp/fixes3 into lp:openlp.

Requested reviews:
  OpenLP Core (openlp-core)

For more details, see:
https://code.launchpad.net/~googol/openlp/fixes3/+merge/147511

Hello,

- fixed regression in trunk
-- 
https://code.launchpad.net/~googol/openlp/fixes3/+merge/147511
Your team OpenLP Core is requested to review the proposed merge of lp:~googol/openlp/fixes3 into lp:openlp.
=== modified file 'openlp/core/ui/firsttimeform.py'
--- openlp/core/ui/firsttimeform.py	2013-02-05 08:05:28 +0000
+++ openlp/core/ui/firsttimeform.py	2013-02-09 14:17:20 +0000
@@ -61,7 +61,7 @@
         config = self.parent().config
         for theme in themes:
             # Stop if the wizard has been cancelled.
-            if self.parent().downloadCancelled:
+            if self.parent().was_download_cancelled:
                 return
             title = config.get(u'theme_%s' % theme, u'title')
             filename = config.get(u'theme_%s' % theme, u'filename')
@@ -91,9 +91,9 @@
         # check to see if we have web access
         self.web = u'http://openlp.org/files/frw/'
         self.config = SafeConfigParser()
-        self.webAccess = get_web_page(u'%s%s' % (self.web, u'download.cfg'))
-        if self.webAccess:
-            files = self.webAccess.read()
+        self.web_access = get_web_page(u'%s%s' % (self.web, u'download.cfg'))
+        if self.web_access:
+            files = self.web_access.read()
             self.config.readfp(io.BytesIO(files))
         self.updateScreenListCombo()
         self.was_download_cancelled = False
@@ -118,13 +118,12 @@
         Set up display at start of theme edit.
         """
         self.restart()
-        check_directory_exists(os.path.join(
-            unicode(gettempdir(), get_filesystem_encoding()), u'openlp'))
+        check_directory_exists(os.path.join(unicode(gettempdir(), get_filesystem_encoding()), u'openlp'))
         self.noInternetFinishButton.setVisible(False)
         # Check if this is a re-run of the wizard.
         self.hasRunWizard = Settings().value(u'general/has run wizard')
         # Sort out internet access for downloads
-        if self.webAccess:
+        if self.web_access:
             songs = self.config.get(u'songs', u'languages')
             songs = songs.split(u',')
             for song in songs:
@@ -160,7 +159,7 @@
         """
         self.application.process_events()
         if self.currentId() == FirstTimePage.Plugins:
-            if not self.webAccess:
+            if not self.web_access:
                 return FirstTimePage.NoInternet
             else:
                 return FirstTimePage.Songs
@@ -169,6 +168,7 @@
         elif self.currentId() == FirstTimePage.NoInternet:
             return FirstTimePage.Progress
         elif self.currentId() == FirstTimePage.Themes:
+            self.application.process_events()
             self.application.set_busy_cursor()
             while not self.themeScreenshotThread.isFinished():
                 time.sleep(0.1)
@@ -241,8 +241,7 @@
         """
         Process the triggering of the cancel button.
         """
-        if self.lastId == FirstTimePage.NoInternet or \
-                (self.lastId <= FirstTimePage.Plugins and not self.hasRunWizard):
+        if self.lastId == FirstTimePage.NoInternet or (self.lastId <= FirstTimePage.Plugins and not self.hasRunWizard):
             QtCore.QCoreApplication.exit()
             sys.exit()
         self.was_download_cancelled = True
@@ -428,7 +427,7 @@
         self._setPluginStatus(self.customCheckBox, u'custom/status')
         self._setPluginStatus(self.songUsageCheckBox, u'songusage/status')
         self._setPluginStatus(self.alertCheckBox, u'alerts/status')
-        if self.webAccess:
+        if self.web_access:
             # Build directories for downloads
             songs_destination = os.path.join(
                 unicode(gettempdir(), get_filesystem_encoding()), u'openlp')


Follow ups