forked from openlp/openlp
Fixes and cleanups
This commit is contained in:
parent
bfb47e2d76
commit
16924808bd
@ -92,12 +92,12 @@ class DisplayManager(QtGui.QWidget):
|
|||||||
self.videoDisplay.mediaHide(message)
|
self.videoDisplay.mediaHide(message)
|
||||||
self.mainDisplay.hideDisplay(message)
|
self.mainDisplay.hideDisplay(message)
|
||||||
|
|
||||||
def showDisplay(self, message):
|
def showDisplay(self):
|
||||||
"""
|
"""
|
||||||
Hide the output displays
|
Hide the output displays
|
||||||
"""
|
"""
|
||||||
self.videoDisplay.mediaShow(message)
|
self.videoDisplay.mediaShow()
|
||||||
self.mainDisplay.showDisplay(message)
|
self.mainDisplay.showDisplay()
|
||||||
|
|
||||||
def addAlert(self, alertMessage, location):
|
def addAlert(self, alertMessage, location):
|
||||||
"""
|
"""
|
||||||
@ -623,7 +623,7 @@ class VideoDisplay(Phonon.VideoWidget):
|
|||||||
self.hidden = True
|
self.hidden = True
|
||||||
self.setVisible(False)
|
self.setVisible(False)
|
||||||
|
|
||||||
def mediaShow(self, message=''):
|
def mediaShow(self):
|
||||||
"""
|
"""
|
||||||
Show the video display if it was already hidden
|
Show the video display if it was already hidden
|
||||||
"""
|
"""
|
||||||
|
@ -64,7 +64,7 @@ def parse_reference(reference):
|
|||||||
to_verse = match.group(5)
|
to_verse = match.group(5)
|
||||||
if int(match.group(2)) == int(match.group(4)):
|
if int(match.group(2)) == int(match.group(4)):
|
||||||
reference_list.append(
|
reference_list.append(
|
||||||
(match.group(1), int(match.group(2)), from_verse, to_verse)
|
(book, int(match.group(2)), from_verse, to_verse)
|
||||||
)
|
)
|
||||||
else:
|
else:
|
||||||
if int(match.group(2)) > int(match.group(4)):
|
if int(match.group(2)) > int(match.group(4)):
|
||||||
@ -75,17 +75,11 @@ def parse_reference(reference):
|
|||||||
to_chapter = int(match.group(4))
|
to_chapter = int(match.group(4))
|
||||||
for chapter in xrange(from_chapter, to_chapter + 1):
|
for chapter in xrange(from_chapter, to_chapter + 1):
|
||||||
if chapter == from_chapter:
|
if chapter == from_chapter:
|
||||||
reference_list.append(
|
reference_list.append((book, chapter, from_verse, -1))
|
||||||
(match.group(1), chapter, from_verse, -1)
|
|
||||||
)
|
|
||||||
elif chapter == to_chapter:
|
elif chapter == to_chapter:
|
||||||
reference_list.append(
|
reference_list.append((book, chapter, 1, to_verse))
|
||||||
(match.group(1), chapter, 1, to_verse)
|
|
||||||
)
|
|
||||||
else:
|
else:
|
||||||
reference_list.append(
|
reference_list.append((book, chapter, 1, -1))
|
||||||
(match.group(1), chapter, 1, -1)
|
|
||||||
)
|
|
||||||
else:
|
else:
|
||||||
match = only_verses.match(reference)
|
match = only_verses.match(reference)
|
||||||
if match:
|
if match:
|
||||||
|
Loading…
Reference in New Issue
Block a user