~mahfiaz/openlp/author-delete-button-not-active-in-edit-dialog

« back to all changes in this revision

Viewing changes to openlp/core/ui/themeform.py

  • Committer: Tim Bentley
  • Date: 2013-07-15 19:33:50 UTC
  • mfrom: (2250.1.24 general)
  • Revision ID: tim.bentley@gmail.com-20130715193350-npygrmen3xxbhphh
rename new url from live to main
fix display constraints
fix missing image test
add tests.

Show diffs side-by-side

added added

removed removed

Lines of Context:
38
38
from openlp.core.lib.theme import BackgroundType, BackgroundGradientType
39
39
from openlp.core.lib.ui import critical_error_message_box
40
40
from openlp.core.ui import ThemeLayoutForm
41
 
from openlp.core.utils import get_images_filter
 
41
from openlp.core.utils import get_images_filter, is_not_image_file
42
42
from themewizard import Ui_ThemeWizard
43
43
 
44
44
log = logging.getLogger(__name__)
178
178
        """
179
179
        background_image = BackgroundType.to_string(BackgroundType.Image)
180
180
        if self.page(self.currentId()) == self.backgroundPage and \
181
 
                self.theme.background_type == background_image and not self.imageFileEdit.text():
 
181
                self.theme.background_type == background_image and is_not_image_file(self.imageFileEdit.text()):
182
182
            QtGui.QMessageBox.critical(self, translate('OpenLP.ThemeWizard', 'Background Image Empty'),
183
183
                translate('OpenLP.ThemeWizard', 'You have not selected a '
184
184
                    'background image. Please select one before continuing.'))