forked from openlp/openlp
Bibles do not loop
This commit is contained in:
parent
50691074b8
commit
0518f4987a
@ -96,6 +96,7 @@ class ServiceItem(object):
|
||||
self.themedata = None
|
||||
self.main = None
|
||||
self.footer = None
|
||||
self.bg_frame = None
|
||||
|
||||
def add_capability(self, capability):
|
||||
"""
|
||||
@ -135,12 +136,10 @@ class ServiceItem(object):
|
||||
"""
|
||||
log.debug(u'Render called')
|
||||
self._display_frames = []
|
||||
#self.clear_cache()
|
||||
self.bg_frame = None
|
||||
self.just_rendered = True
|
||||
if self.service_item_type == ServiceItemType.Text:
|
||||
log.debug(u'Formatting slides')
|
||||
theme = None;
|
||||
theme = None
|
||||
if not self.theme:
|
||||
theme = self.theme
|
||||
self.main, self.footer = \
|
||||
@ -150,11 +149,11 @@ class ServiceItem(object):
|
||||
for slide in self._raw_frames:
|
||||
before = time.time()
|
||||
formated = self.render_manager.format_slide(slide[u'raw_slide'])
|
||||
for format in formated:
|
||||
for page in formated:
|
||||
self._display_frames.append(
|
||||
{u'title': self.render_manager.clean(format),
|
||||
u'text': self.render_manager.clean(format.rstrip()),
|
||||
u'html': self.render_manager.expand(format.rstrip()),
|
||||
{u'title': self.render_manager.clean(page),
|
||||
u'text': self.render_manager.clean(page.rstrip()),
|
||||
u'html': self.render_manager.expand(page.rstrip()),
|
||||
u'verseTag': slide[u'verseTag'] })
|
||||
log.log(15, u'Formatting took %4s' % (time.time() - before))
|
||||
elif self.service_item_type == ServiceItemType.Image:
|
||||
|
@ -55,6 +55,6 @@ from mediadockmanager import MediaDockManager
|
||||
from servicemanager import ServiceManager
|
||||
from thememanager import ThemeManager
|
||||
|
||||
__all__ = ['SplashScreen', 'AboutForm', 'SettingsForm', 'MainWindow',
|
||||
__all__ = ['SplashScreen', 'AboutForm', 'SettingsForm',
|
||||
'MainDisplay', 'SlideController', 'ServiceManager', 'ThemeManager',
|
||||
'AmendThemeForm', 'MediaDockManager', 'ServiceItemEditForm']
|
||||
|
@ -548,13 +548,15 @@ class BibleMediaItem(MediaManagerItem):
|
||||
#Paragraph style force new line per verse
|
||||
if self.parent.settings_tab.layout_style == 1:
|
||||
text = text + u'\n\n'
|
||||
else:
|
||||
text = text + u'\n'
|
||||
bible_text = u'%s %s %s' % (bible_text, verse_text, text)
|
||||
#if we are verse per slide then create slide
|
||||
if self.parent.settings_tab.layout_style == 0:
|
||||
raw_slides.append(bible_text)
|
||||
bible_text = u''
|
||||
if not service_item.title:
|
||||
service_item.title = u'%s %s' % (book, verse_text)
|
||||
service_item.title = u'%s %s:%s' % (book, chapter, verse)
|
||||
elif service_item.title.find(
|
||||
translate('BiblesPlugin.MediaItem', 'etc')) == -1:
|
||||
service_item.title = u'%s, %s' % (service_item.title,
|
||||
|
Loading…
Reference in New Issue
Block a user