openlp-core team mailing list archive
-
openlp-core team
-
Mailing list archive
-
Message #22481
[Merge] lp:~raoul-snyman/openlp/bug-1216234-2.0 into lp:openlp/2.0
Raoul Snyman has proposed merging lp:~raoul-snyman/openlp/bug-1216234-2.0 into lp:openlp/2.0.
Requested reviews:
OpenLP Core (openlp-core)
Related bugs:
Bug #1216234 in OpenLP: "Layout style has not effect when using a second bible"
https://bugs.launchpad.net/openlp/+bug/1216234
For more details, see:
https://code.launchpad.net/~raoul-snyman/openlp/bug-1216234-2.0/+merge/200255
Fix bug #1216234 by disabling the layout combobox when a second Bible is selected.
--
https://code.launchpad.net/~raoul-snyman/openlp/bug-1216234-2.0/+merge/200255
Your team OpenLP Core is requested to review the proposed merge of lp:~raoul-snyman/openlp/bug-1216234-2.0 into lp:openlp/2.0.
=== modified file 'openlp/plugins/bibles/lib/biblestab.py'
--- openlp/plugins/bibles/lib/biblestab.py 2013-11-20 19:31:35 +0000
+++ openlp/plugins/bibles/lib/biblestab.py 2014-01-01 16:05:53 +0000
@@ -39,6 +39,7 @@
log = logging.getLogger(__name__)
+
class BiblesTab(SettingsTab):
"""
BiblesTab is the Bibles settings tab in the settings dialog.
=== modified file 'openlp/plugins/bibles/lib/mediaitem.py'
--- openlp/plugins/bibles/lib/mediaitem.py 2012-12-30 19:41:24 +0000
+++ openlp/plugins/bibles/lib/mediaitem.py 2014-01-01 16:05:53 +0000
@@ -47,6 +47,7 @@
log = logging.getLogger(__name__)
+
class BibleSearch(object):
"""
Enumeration class for the different search methods for the "quick search".
@@ -62,7 +63,6 @@
log.info(u'Bible Media Item loaded')
def __init__(self, parent, plugin, icon):
- self.IconPath = u'songs/song'
self.lockIcon = build_icon(u':/bibles/bibles_search_lock.png')
self.unlockIcon = build_icon(u':/bibles/bibles_search_unlock.png')
MediaManagerItem.__init__(self, parent, plugin, icon)
@@ -180,6 +180,8 @@
tab.setVisible(False)
QtCore.QObject.connect(lockButton, QtCore.SIGNAL(u'toggled(bool)'),
self.onLockButtonToggled)
+ QtCore.QObject.connect(secondComboBox, QtCore.SIGNAL(u'currentIndexChanged(QString)'),
+ self.onSecondBibleComboBoxCurrentIndexChanged)
setattr(self, prefix + u'VersionLabel', versionLabel)
setattr(self, prefix + u'VersionComboBox', versionComboBox)
setattr(self, prefix + u'SecondLabel', secondLabel)
@@ -299,15 +301,15 @@
log.debug(u'configUpdated')
if Settings().value(self.settingsSection + u'/second bibles',
QtCore.QVariant(True)).toBool():
+ self.quickSecondLabel.setVisible(True)
+ self.quickSecondComboBox.setVisible(True)
self.advancedSecondLabel.setVisible(True)
self.advancedSecondComboBox.setVisible(True)
- self.quickSecondLabel.setVisible(True)
- self.quickSecondComboBox.setVisible(True)
else:
+ self.quickSecondLabel.setVisible(False)
+ self.quickSecondComboBox.setVisible(False)
self.advancedSecondLabel.setVisible(False)
self.advancedSecondComboBox.setVisible(False)
- self.quickSecondLabel.setVisible(False)
- self.quickSecondComboBox.setVisible(False)
self.quickStyleComboBox.setCurrentIndex(self.settings.layout_style)
self.advancedStyleComboBox.setCurrentIndex(self.settings.layout_style)
@@ -542,6 +544,14 @@
books.sort(cmp=locale_compare)
set_case_insensitive_completer(books, self.quickSearchEdit)
+ def onSecondBibleComboBoxCurrentIndexChanged(self, text):
+ if text is None or not unicode(text):
+ self.quickStyleComboBox.setEnabled(True)
+ self.advancedStyleComboBox.setEnabled(True)
+ else:
+ self.quickStyleComboBox.setEnabled(False)
+ self.advancedStyleComboBox.setEnabled(False)
+
def onImportClick(self):
if not hasattr(self, u'import_wizard'):
self.import_wizard = BibleImportForm(self, self.plugin.manager,
Follow ups