Merge lp:~trb143/openlp/audit into lp:openlp

Proposed by Tim Bentley
Status: Merged
Merged at revision: not available
Proposed branch: lp:~trb143/openlp/audit
Merge into: lp:openlp
Diff against target: 552 lines
21 files modified
openlp/core/lib/plugin.py (+1/-2)
openlp/core/lib/serviceitem.py (+18/-5)
openlp/core/lib/settingsmanager.py (+3/-3)
openlp/core/lib/xmlrootclass.py (+2/-2)
openlp/core/ui/about.py (+1/-0)
openlp/core/ui/maindisplay.py (+1/-1)
openlp/plugins/audit/auditplugin.py (+1/-1)
openlp/plugins/audit/lib/manager.py (+1/-1)
openlp/plugins/bibles/bibleplugin.py (+1/-1)
openlp/plugins/bibles/lib/bibleCSVimpl.py (+1/-1)
openlp/plugins/bibles/lib/bibleHTTPimpl.py (+14/-15)
openlp/plugins/bibles/lib/bibleOSISimpl.py (+6/-4)
openlp/plugins/bibles/lib/common.py (+3/-3)
openlp/plugins/bibles/lib/manager.py (+7/-9)
openlp/plugins/bibles/lib/mediaitem.py (+10/-13)
openlp/plugins/custom/customplugin.py (+1/-1)
openlp/plugins/custom/lib/mediaitem.py (+1/-1)
openlp/plugins/presentations/lib/mediaitem.py (+1/-1)
openlp/plugins/presentations/lib/messagelistener.py (+1/-1)
openlp/plugins/presentations/presentationplugin.py (+2/-2)
openlp/plugins/remotes/remoteplugin.py (+1/-1)
To merge this branch: bzr merge lp:~trb143/openlp/audit
Reviewer Review Type Date Requested Status
Jon Tibble (community) Approve
Review via email: mp+12602@code.launchpad.net

This proposal supersedes a proposal from 2009-09-29.

To post a comment you must log in.
Revision history for this message
Tim Bentley (trb143) wrote : Posted in a previous version of this proposal

Caught Jon's bug and done some cleanups.
Added Jon About screen so he gets some well aimed blame!
Next request may do something useful

Revision history for this message
Jonathan Corwin (j-corwin) wrote : Posted in a previous version of this proposal

Given the list of developers appears to be in alphabetical order, shouldn't Jon appear a few lines further down?

Revision history for this message
Jon Tibble (meths) wrote :

Looks good

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'openlp/core/lib/plugin.py'
--- openlp/core/lib/plugin.py 2009-09-29 12:51:38 +0000
+++ openlp/core/lib/plugin.py 2009-09-29 17:25:26 +0000
@@ -200,8 +200,7 @@
200200
201 def process_add_service_event(self):201 def process_add_service_event(self):
202 """202 """
203 Proxy method as method is not defined early enough203 Generic Drag and drop handler triggered from service_manager.
204 in the processing
205 """204 """
206 log.debug(u'process_add_service_event event called for plugin %s' % self.name)205 log.debug(u'process_add_service_event event called for plugin %s' % self.name)
207 self.media_item.onAddClick()206 self.media_item.onAddClick()
208207
=== modified file 'openlp/core/lib/serviceitem.py'
--- openlp/core/lib/serviceitem.py 2009-09-25 23:06:54 +0000
+++ openlp/core/lib/serviceitem.py 2009-09-29 17:25:26 +0000
@@ -24,12 +24,16 @@
2424
25import logging25import logging
26import os26import os
27import time
2728
28from PyQt4 import QtGui29from PyQt4 import QtGui
2930
30from openlp.core.lib import buildIcon31from openlp.core.lib import buildIcon
3132
32class ServiceType(object):33class ServiceType(object):
34 """
35 Defines the type of service item
36 """
33 Text = 137 Text = 1
34 Image = 238 Image = 2
35 Command = 339 Command = 3
@@ -82,7 +86,7 @@
8286
83 def render(self):87 def render(self):
84 """88 """
85 The render method is what renders the frames for the screen.89 The render method is what generates the frames for the screen.
86 """90 """
87 log.debug(u'Render called')91 log.debug(u'Render called')
88 self.frames = []92 self.frames = []
@@ -93,6 +97,7 @@
93 else:97 else:
94 self.RenderManager.set_override_theme(self.theme)98 self.RenderManager.set_override_theme(self.theme)
95 for slide in self.service_frames:99 for slide in self.service_frames:
100 before = time.time()
96 formated = self.RenderManager.format_slide(slide[u'raw_slide'])101 formated = self.RenderManager.format_slide(slide[u'raw_slide'])
97 for format in formated:102 for format in formated:
98 frame = None103 frame = None
@@ -102,6 +107,7 @@
102 title = lines.split(u'\n')[0]107 title = lines.split(u'\n')[0]
103 self.frames.append({u'title': title, u'text': lines,108 self.frames.append({u'title': title, u'text': lines,
104 u'image': frame})109 u'image': frame})
110 log.info(u'Formatting took %4s' % (time.time() - before))
105 elif self.service_item_type == ServiceType.Command:111 elif self.service_item_type == ServiceType.Command:
106 self.frames = self.service_frames112 self.frames = self.service_frames
107 elif self.service_item_type == ServiceType.Image:113 elif self.service_item_type == ServiceType.Image:
@@ -113,6 +119,11 @@
113 log.error(u'Invalid value renderer :%s' % self.service_item_type)119 log.error(u'Invalid value renderer :%s' % self.service_item_type)
114120
115 def render_individual(self, row):121 def render_individual(self, row):
122 """
123 Takes an array of text and geneates an Image from the
124 theme. It assumes the text will fit on the screen as it
125 has generated by the render method above.
126 """
116 log.debug(u'render individual')127 log.debug(u'render individual')
117 if self.theme is None:128 if self.theme is None:
118 self.RenderManager.set_override_theme(None)129 self.RenderManager.set_override_theme(None)
@@ -138,7 +149,8 @@
138 """149 """
139 self.service_item_type = ServiceType.Image150 self.service_item_type = ServiceType.Image
140 self.service_item_path = path151 self.service_item_path = path
141 self.service_frames.append({u'title': frame_title, u'text':None, u'image': image})152 self.service_frames.append(
153 {u'title': frame_title, u'text':None, u'image': image})
142154
143 def add_from_text(self, frame_title, raw_slide):155 def add_from_text(self, frame_title, raw_slide):
144 """156 """
@@ -152,8 +164,8 @@
152 """164 """
153 self.service_item_type = ServiceType.Text165 self.service_item_type = ServiceType.Text
154 frame_title = frame_title.split(u'\n')[0]166 frame_title = frame_title.split(u'\n')[0]
155 self.service_frames.append({u'title': frame_title,167 self.service_frames.append(
156 u'raw_slide': raw_slide})168 {u'title': frame_title, u'raw_slide': raw_slide})
157169
158 def add_from_command(self, path, frame_title):170 def add_from_command(self, path, frame_title):
159 """171 """
@@ -167,7 +179,8 @@
167 """179 """
168 self.service_item_type = ServiceType.Command180 self.service_item_type = ServiceType.Command
169 self.service_item_path = path181 self.service_item_path = path
170 self.service_frames.append({u'title': frame_title, u'command': None})182 self.service_frames.append(
183 {u'title': frame_title, u'command': None})
171184
172 def get_service_repr(self):185 def get_service_repr(self):
173 """186 """
174187
=== modified file 'openlp/core/lib/settingsmanager.py'
--- openlp/core/lib/settingsmanager.py 2009-09-29 02:54:32 +0000
+++ openlp/core/lib/settingsmanager.py 2009-09-29 17:25:26 +0000
@@ -67,13 +67,13 @@
67 def setUIItemVisibility(self, item=u'', isVisible=True):67 def setUIItemVisibility(self, item=u'', isVisible=True):
68 if item != u'':68 if item != u'':
69 if item == u'ThemeManagerDock':69 if item == u'ThemeManagerDock':
70 ConfigHelper.set_config('user interface',70 ConfigHelper.set_config(u'user interface',
71 u'display thememanager', isVisible)71 u'display thememanager', isVisible)
72 elif item == u'ServiceManagerDock':72 elif item == u'ServiceManagerDock':
73 ConfigHelper.set_config('user interface',73 ConfigHelper.set_config(u'user interface',
74 u'display servicemanager', isVisible)74 u'display servicemanager', isVisible)
75 elif item == u'MediaManagerDock':75 elif item == u'MediaManagerDock':
76 ConfigHelper.set_config('user interface',76 ConfigHelper.set_config(u'user interface',
77 u'display mediamanager', isVisible)77 u'display mediamanager', isVisible)
7878
79 def togglePreviewPanel(self, isVisible):79 def togglePreviewPanel(self, isVisible):
8080
=== modified file 'openlp/core/lib/xmlrootclass.py'
--- openlp/core/lib/xmlrootclass.py 2009-09-25 00:43:42 +0000
+++ openlp/core/lib/xmlrootclass.py 2009-09-29 17:25:26 +0000
@@ -28,7 +28,7 @@
2828
29from xml.etree.ElementTree import ElementTree, XML29from xml.etree.ElementTree import ElementTree, XML
3030
31sys.path.append(os.path.abspath(os.path.join('.', '..', '..')))31sys.path.append(os.path.abspath(os.path.join(u'.', u'..', u'..')))
3232
33class XmlRootClass(object):33class XmlRootClass(object):
34 """34 """
@@ -61,7 +61,7 @@
61 val = text61 val = text
62 elif type(text) is StringType:62 elif type(text) is StringType:
63 # Strings need special handling to sort the colours out63 # Strings need special handling to sort the colours out
64 if text[0] == '$':64 if text[0] == u'$':
65 # This might be a hex number, let's try to convert it.65 # This might be a hex number, let's try to convert it.
66 try:66 try:
67 val = int(text[1:], 16)67 val = int(text[1:], 16)
6868
=== modified file 'openlp/core/ui/about.py'
--- openlp/core/ui/about.py 2009-09-29 02:54:32 +0000
+++ openlp/core/ui/about.py 2009-09-29 17:25:26 +0000
@@ -162,6 +162,7 @@
162 u' Scott \"sguerrieri\" Guerrieri\n'162 u' Scott \"sguerrieri\" Guerrieri\n'
163 u' Raoul \"superfly\" Snyman\n'163 u' Raoul \"superfly\" Snyman\n'
164 u' Martin \"mijiti\" Thompson\n'164 u' Martin \"mijiti\" Thompson\n'
165 u' Jon \"Meths\" Tibble\n'
165 u' Carsten \"catini\" Tingaard'))166 u' Carsten \"catini\" Tingaard'))
166 self.AboutNotebook.setTabText(167 self.AboutNotebook.setTabText(
167 self.AboutNotebook.indexOf(self.CreditsTab),168 self.AboutNotebook.indexOf(self.CreditsTab),
168169
=== modified file 'openlp/core/ui/maindisplay.py'
--- openlp/core/ui/maindisplay.py 2009-09-25 00:43:42 +0000
+++ openlp/core/ui/maindisplay.py 2009-09-29 17:25:26 +0000
@@ -32,7 +32,7 @@
32 This is the form that is used to display things on the projector.32 This is the form that is used to display things on the projector.
33 """33 """
34 global log34 global log
35 log=logging.getLogger(u'MainDisplay')35 log = logging.getLogger(u'MainDisplay')
36 log.info(u'MainDisplay Loaded')36 log.info(u'MainDisplay Loaded')
3737
38 def __init__(self, parent, screens):38 def __init__(self, parent, screens):
3939
=== modified file 'openlp/plugins/audit/auditplugin.py'
--- openlp/plugins/audit/auditplugin.py 2009-09-29 02:54:32 +0000
+++ openlp/plugins/audit/auditplugin.py 2009-09-29 17:25:26 +0000
@@ -49,7 +49,7 @@
49 """49 """
50 Check to see if auditing is required50 Check to see if auditing is required
51 """51 """
52 log.debug('check_pre_conditions')52 log.debug(u'check_pre_conditions')
53 #Lets see if audit is required53 #Lets see if audit is required
54 if int(self.config.get_config(u'startup', 0)) == QtCore.Qt.Checked:54 if int(self.config.get_config(u'startup', 0)) == QtCore.Qt.Checked:
55 return True55 return True
5656
=== modified file 'openlp/plugins/audit/lib/manager.py'
--- openlp/plugins/audit/lib/manager.py 2009-09-26 06:46:26 +0000
+++ openlp/plugins/audit/lib/manager.py 2009-09-29 17:25:26 +0000
@@ -33,7 +33,7 @@
33 """33 """
3434
35 global log35 global log
36 log=logging.getLogger(u'AuditManager')36 log = logging.getLogger(u'AuditManager')
37 log.info(u'Audit manager loaded')37 log.info(u'Audit manager loaded')
3838
39 def __init__(self, config):39 def __init__(self, config):
4040
=== modified file 'openlp/plugins/bibles/bibleplugin.py'
--- openlp/plugins/bibles/bibleplugin.py 2009-09-29 02:54:32 +0000
+++ openlp/plugins/bibles/bibleplugin.py 2009-09-29 17:25:26 +0000
@@ -31,7 +31,7 @@
3131
32class BiblePlugin(Plugin):32class BiblePlugin(Plugin):
33 global log33 global log
34 log=logging.getLogger(u'BiblePlugin')34 log = logging.getLogger(u'BiblePlugin')
35 log.info(u'Bible Plugin loaded')35 log.info(u'Bible Plugin loaded')
3636
37 def __init__(self, plugin_helpers):37 def __init__(self, plugin_helpers):
3838
=== modified file 'openlp/plugins/bibles/lib/bibleCSVimpl.py'
--- openlp/plugins/bibles/lib/bibleCSVimpl.py 2009-09-25 00:43:42 +0000
+++ openlp/plugins/bibles/lib/bibleCSVimpl.py 2009-09-29 17:25:26 +0000
@@ -30,7 +30,7 @@
3030
31class BibleCSVImpl(BibleCommon):31class BibleCSVImpl(BibleCommon):
32 global log32 global log
33 log=logging.getLogger(u'BibleCSVImpl')33 log = logging.getLogger(u'BibleCSVImpl')
34 log.info(u'BibleCVSImpl loaded')34 log.info(u'BibleCVSImpl loaded')
35 def __init__(self, bibledb):35 def __init__(self, bibledb):
36 """36 """
3737
=== modified file 'openlp/plugins/bibles/lib/bibleHTTPimpl.py'
--- openlp/plugins/bibles/lib/bibleHTTPimpl.py 2009-09-26 18:22:10 +0000
+++ openlp/plugins/bibles/lib/bibleHTTPimpl.py 2009-09-29 17:25:26 +0000
@@ -28,7 +28,7 @@
2828
29class BGExtract(BibleCommon):29class BGExtract(BibleCommon):
30 global log30 global log
31 log=logging.getLogger(u'BibleHTTPMgr(BG_extract)')31 log = logging.getLogger(u'BibleHTTPMgr(BG_extract)')
32 log.info(u'BG_extract loaded')32 log.info(u'BG_extract loaded')
3333
34 def __init__(self, proxyurl= None):34 def __init__(self, proxyurl= None):
@@ -65,7 +65,7 @@
65 bible = {}65 bible = {}
66 while versePos > -1:66 while versePos > -1:
67 # clear out string67 # clear out string
68 verseText = ''68 verseText = u''
69 versePos = xml_string.find(u'</span', versePos)69 versePos = xml_string.find(u'</span', versePos)
70 i = xml_string.find(VerseSearch, versePos+1)70 i = xml_string.find(VerseSearch, versePos+1)
71 if i == -1:71 if i == -1:
@@ -88,7 +88,7 @@
8888
89class CWExtract(BibleCommon):89class CWExtract(BibleCommon):
90 global log90 global log
91 log=logging.getLogger(u'BibleHTTPMgr(CWExtract)')91 log = logging.getLogger(u'BibleHTTPMgr(CWExtract)')
92 log.info(u'CWExtract loaded')92 log.info(u'CWExtract loaded')
9393
94 def __init__(self, proxyurl=None):94 def __init__(self, proxyurl=None):
@@ -121,8 +121,8 @@
121 xml_string = self._get_web_text(urlstring, self.proxyurl)121 xml_string = self._get_web_text(urlstring, self.proxyurl)
122 ## Strip Book Title from Heading to return it to system122 ## Strip Book Title from Heading to return it to system
123 ##123 ##
124 i= xml_string.find(u'<title>')124 i = xml_string.find(u'<title>')
125 j= xml_string.find(u'-', i)125 j = xml_string.find(u'-', i)
126 book_title = xml_string[i + 7:j]126 book_title = xml_string[i + 7:j]
127 book_title = book_title.rstrip()127 book_title = book_title.rstrip()
128 log.debug(u'Book Title %s', book_title)128 log.debug(u'Book Title %s', book_title)
@@ -133,15 +133,15 @@
133 log.debug(u'Book Chapter %s', book_chapter)133 log.debug(u'Book Chapter %s', book_chapter)
134 # Strip Verse Data from Page and build an array134 # Strip Verse Data from Page and build an array
135135
136 i= xml_string.find(u'NavCurrentChapter')136 i = xml_string.find(u'NavCurrentChapter')
137 xml_string = xml_string[i:len(xml_string)]137 xml_string = xml_string[i:len(xml_string)]
138 i= xml_string.find(u'<TABLE')138 i = xml_string.find(u'<TABLE')
139 xml_string = xml_string[i:len(xml_string)]139 xml_string = xml_string[i:len(xml_string)]
140 i= xml_string.find(u'<B>')140 i = xml_string.find(u'<B>')
141 #remove the <B> at the front141 #remove the <B> at the front
142 xml_string = xml_string[i + 3 :len(xml_string)]142 xml_string = xml_string[i + 3 :len(xml_string)]
143 # Remove the heading for the book143 # Remove the heading for the book
144 i= xml_string.find(u'<B>')144 i = xml_string.find(u'<B>')
145 #remove the <B> at the front145 #remove the <B> at the front
146 xml_string = xml_string[i + 3 :len(xml_string)]146 xml_string = xml_string[i + 3 :len(xml_string)]
147 versePos = xml_string.find(u'<BLOCKQUOTE>')147 versePos = xml_string.find(u'<BLOCKQUOTE>')
@@ -151,7 +151,7 @@
151 versePos = xml_string.find(u'<B><I>', versePos) + 6151 versePos = xml_string.find(u'<B><I>', versePos) + 6
152 i = xml_string.find(u'</I></B>', versePos)152 i = xml_string.find(u'</I></B>', versePos)
153 # Got the Chapter153 # Got the Chapter
154 verse= xml_string[versePos:i]154 verse = xml_string[versePos:i]
155 # move the starting position to begining of the text155 # move the starting position to begining of the text
156 versePos = i + 8156 versePos = i + 8
157 # find the start of the next verse157 # find the start of the next verse
@@ -168,7 +168,7 @@
168168
169class BibleHTTPImpl():169class BibleHTTPImpl():
170 global log170 global log
171 log=logging.getLogger(u'BibleHTTPMgr')171 log = logging.getLogger(u'BibleHTTPMgr')
172 log.info(u'BibleHTTP manager loaded')172 log.info(u'BibleHTTP manager loaded')
173 def __init__(self):173 def __init__(self):
174 """174 """
@@ -180,8 +180,7 @@
180180
181 Init confirms the bible exists and stores the database path.181 Init confirms the bible exists and stores the database path.
182 """182 """
183 #bible = {}183 self.biblesource = u''
184 self.biblesource = ''
185 self.proxyurl = None184 self.proxyurl = None
186 self.bibleid = None185 self.bibleid = None
187186
188187
=== modified file 'openlp/plugins/bibles/lib/bibleOSISimpl.py'
--- openlp/plugins/bibles/lib/bibleOSISimpl.py 2009-09-26 14:36:08 +0000
+++ openlp/plugins/bibles/lib/bibleOSISimpl.py 2009-09-29 17:25:26 +0000
@@ -60,7 +60,7 @@
60 filepath = os.path.split(os.path.abspath(__file__))[0]60 filepath = os.path.split(os.path.abspath(__file__))[0]
61 filepath = os.path.abspath(os.path.join(61 filepath = os.path.abspath(os.path.join(
62 filepath, u'..', u'resources',u'osisbooks.csv'))62 filepath, u'..', u'resources',u'osisbooks.csv'))
63 fbibles=open(filepath, u'r')63 fbibles = open(filepath, u'r')
64 for line in fbibles:64 for line in fbibles:
65 p = line.split(u',')65 p = line.split(u',')
66 self.booksOfBible[p[0]] = p[1].replace(u'\n', u'')66 self.booksOfBible[p[0]] = p[1].replace(u'\n', u'')
@@ -99,9 +99,11 @@
99 if self.loadbible == False:99 if self.loadbible == False:
100 break100 break
101 pos = file_record.find(verseText)101 pos = file_record.find(verseText)
102 if pos > -1: # we have a verse102 # we have a verse
103 epos= file_record.find(u'>', pos)103 if pos > -1:
104 ref = file_record[pos+15:epos-1] # Book Reference104 epos = file_record.find(u'>', pos)
105 # Book Reference
106 ref = file_record[pos+15:epos-1]
105 #lets find the bible text only107 #lets find the bible text only
106 # find start of text108 # find start of text
107 pos = epos + 1109 pos = epos + 1
108110
=== modified file 'openlp/plugins/bibles/lib/common.py'
--- openlp/plugins/bibles/lib/common.py 2009-09-26 18:22:10 +0000
+++ openlp/plugins/bibles/lib/common.py 2009-09-29 17:25:26 +0000
@@ -104,15 +104,15 @@
104 urllib2.install_opener(opener)104 urllib2.install_opener(opener)
105 xml_string = u''105 xml_string = u''
106 req = urllib2.Request(urlstring)106 req = urllib2.Request(urlstring)
107 req.add_header('User-Agent', 'Mozilla/4.0 (compatible; MSIE 5.5; Windows NT)')107 req.add_header(u'User-Agent', u'Mozilla/4.0 (compatible; MSIE 5.5; Windows NT)')
108 try:108 try:
109 handle = urllib2.urlopen(req)109 handle = urllib2.urlopen(req)
110 html = handle.read()110 html = handle.read()
111 details = chardet.detect(html)111 details = chardet.detect(html)
112 xml_string = unicode(html, details['encoding'])112 xml_string = unicode(html, details[u'encoding'])
113 except IOError, e:113 except IOError, e:
114 if hasattr(e, u'reason'):114 if hasattr(e, u'reason'):
115 log.error(u'Reason : %s', e.reason)115 log.exception(u'Reason for failure: %s', e.reason)
116 return xml_string116 return xml_string
117117
118 def _clean_text(self, text):118 def _clean_text(self, text):
119119
=== modified file 'openlp/plugins/bibles/lib/manager.py'
--- openlp/plugins/bibles/lib/manager.py 2009-09-26 18:22:10 +0000
+++ openlp/plugins/bibles/lib/manager.py 2009-09-29 17:25:26 +0000
@@ -322,8 +322,7 @@
322 Rest can be guessed at !322 Rest can be guessed at !
323 """323 """
324 text = []324 text = []
325 self.media.setQuickMsg1(u'')325 self.media.setQuickMessage(u'')
326 self.media.setQuickMsg2(u'')
327 log.debug(u'get_verse_text %s,%s,%s,%s,%s,%s',326 log.debug(u'get_verse_text %s,%s,%s,%s,%s,%s',
328 bible, bookname, schapter, echapter, sverse, everse)327 bible, bookname, schapter, echapter, sverse, everse)
329 # check to see if book/chapter exists fow HTTP bibles and load cache328 # check to see if book/chapter exists fow HTTP bibles and load cache
@@ -331,10 +330,10 @@
331 if self.bible_http_cache[bible] is not None:330 if self.bible_http_cache[bible] is not None:
332 book = self.bible_db_cache[bible].get_bible_book(bookname)331 book = self.bible_db_cache[bible].get_bible_book(bookname)
333 if book is None:332 if book is None:
334 self.media.setQuickMsg1(u'Downloading')
335 log.debug(u'get_verse_text : new book')333 log.debug(u'get_verse_text : new book')
336 for chapter in range(schapter, echapter + 1):334 for chapter in range(schapter, echapter + 1):
337 self.media.setQuickMsg2(u'%s: %s'% (bookname, chapter))335 self.media.setQuickMessage \
336 (u'Downloading %s: %s'% (bookname, chapter))
338 search_results = \337 search_results = \
339 self.bible_http_cache[bible].get_bible_chapter(338 self.bible_http_cache[bible].get_bible_chapter(
340 bible, 0, bookname, chapter)339 bible, 0, bookname, chapter)
@@ -362,8 +361,8 @@
362 v = self.bible_db_cache[bible].get_bible_chapter(361 v = self.bible_db_cache[bible].get_bible_chapter(
363 book.id, chapter)362 book.id, chapter)
364 if v is None:363 if v is None:
365 self.media.setQuickMsg2(u'%s: %s'% (364 self.media.setQuickMessage \
366 bookname, chapter))365 (u'%Downloading %s: %s'% (bookname, chapter))
367 self.bible_db_cache[bible].create_chapter(366 self.bible_db_cache[bible].create_chapter(
368 book.id, chapter,367 book.id, chapter,
369 search_results.get_verselist())368 search_results.get_verselist())
@@ -374,9 +373,8 @@
374 book.id, chapter)373 book.id, chapter)
375 if v is None:374 if v is None:
376 try:375 try:
377 self.media.setQuickMsg1(u'Downloading')376 self.media.setQuickMessage \
378 self.media.setQuickMsg2(u'%s: %s'% \377 (u'Downloading %s: %s'% (bookname, chapter))
379 (bookname, chapter))
380 search_results = \378 search_results = \
381 self.bible_http_cache[bible].get_bible_chapter(379 self.bible_http_cache[bible].get_bible_chapter(
382 bible, book.id, bookname, chapter)380 bible, book.id, bookname, chapter)
383381
=== modified file 'openlp/plugins/bibles/lib/mediaitem.py'
--- openlp/plugins/bibles/lib/mediaitem.py 2009-09-29 02:54:32 +0000
+++ openlp/plugins/bibles/lib/mediaitem.py 2009-09-29 17:25:26 +0000
@@ -76,7 +76,9 @@
76 # Add the Quick Search tab76 # Add the Quick Search tab
77 self.QuickTab = QtGui.QWidget()77 self.QuickTab = QtGui.QWidget()
78 self.QuickTab.setObjectName(u'QuickTab')78 self.QuickTab.setObjectName(u'QuickTab')
79 self.QuickLayout = QtGui.QGridLayout(self.QuickTab)79 self.QuickVerticalLayout = QtGui.QVBoxLayout(self.QuickTab)
80 self.QuickVerticalLayout.setObjectName("verticalLayout")
81 self.QuickLayout = QtGui.QGridLayout()
80 self.QuickLayout.setMargin(5)82 self.QuickLayout.setMargin(5)
81 self.QuickLayout.setSpacing(4)83 self.QuickLayout.setSpacing(4)
82 self.QuickLayout.setObjectName(u'QuickLayout')84 self.QuickLayout.setObjectName(u'QuickLayout')
@@ -107,12 +109,10 @@
107 self.ClearQuickSearchComboBox = QtGui.QComboBox(self.QuickTab)109 self.ClearQuickSearchComboBox = QtGui.QComboBox(self.QuickTab)
108 self.ClearQuickSearchComboBox.setObjectName(u'ClearQuickSearchComboBox')110 self.ClearQuickSearchComboBox.setObjectName(u'ClearQuickSearchComboBox')
109 self.QuickLayout.addWidget(self.ClearQuickSearchComboBox, 3, 1, 1, 1)111 self.QuickLayout.addWidget(self.ClearQuickSearchComboBox, 3, 1, 1, 1)
110 self.QuickMsg1 = QtGui.QLabel(self.QuickTab)112 self.QuickVerticalLayout.addLayout(self.QuickLayout)
111 self.QuickMsg1.setObjectName(u'QuickSearchLabel')113 self.QuickMessage = QtGui.QLabel(self.QuickTab)
112 self.QuickLayout.addWidget(self.QuickMsg1, 4, 0, 1, 1)114 self.QuickMessage.setObjectName(u'QuickMessage')
113 self.QuickMsg2 = QtGui.QLabel(self.QuickTab)115 self.QuickVerticalLayout.addWidget(self.QuickMessage)
114 self.QuickMsg2.setObjectName(u'QuickSearchLabel')
115 self.QuickLayout.addWidget(self.QuickMsg2, 4, 1, 1, 1)
116 self.SearchTabWidget.addTab(self.QuickTab, 'Quick')116 self.SearchTabWidget.addTab(self.QuickTab, 'Quick')
117 QuickSpacerItem = QtGui.QSpacerItem(20, 40, QtGui.QSizePolicy.Minimum,117 QuickSpacerItem = QtGui.QSpacerItem(20, 40, QtGui.QSizePolicy.Minimum,
118 QtGui.QSizePolicy.Expanding)118 QtGui.QSizePolicy.Expanding)
@@ -230,14 +230,11 @@
230 self.loadBibles()230 self.loadBibles()
231 self.parent.biblemanager.set_media_manager(self)231 self.parent.biblemanager.set_media_manager(self)
232232
233 def setQuickMsg1(self, text):233 def setQuickMessage(self, text):
234 self.QuickMsg1.setText(translate(u'BibleMediaItem', unicode(text)))234 self.QuickMessage.setText(translate(u'BibleMediaItem', unicode(text)))
235
236 def setQuickMsg2(self, text):
237 self.QuickMsg2.setText(translate(u'BibleMediaItem', unicode(text)))
238 Receiver().send_message(u'process_events')235 Receiver().send_message(u'process_events')
239 #minor delay to get the events processed236 #minor delay to get the events processed
240 time.sleep(0.5)237 time.sleep(0.1)
241238
242 def loadBibles(self):239 def loadBibles(self):
243 log.debug(u'Loading Bibles')240 log.debug(u'Loading Bibles')
244241
=== modified file 'openlp/plugins/custom/customplugin.py'
--- openlp/plugins/custom/customplugin.py 2009-09-29 02:54:32 +0000
+++ openlp/plugins/custom/customplugin.py 2009-09-29 17:25:26 +0000
@@ -40,7 +40,7 @@
40 """40 """
4141
42 global log42 global log
43 log=logging.getLogger(u'CustomPlugin')43 log = logging.getLogger(u'CustomPlugin')
44 log.info(u'Custom Plugin loaded')44 log.info(u'Custom Plugin loaded')
4545
46 def __init__(self, plugin_helpers):46 def __init__(self, plugin_helpers):
4747
=== modified file 'openlp/plugins/custom/lib/mediaitem.py'
--- openlp/plugins/custom/lib/mediaitem.py 2009-09-26 09:11:39 +0000
+++ openlp/plugins/custom/lib/mediaitem.py 2009-09-29 17:25:26 +0000
@@ -38,7 +38,7 @@
38 This is the custom media manager item for Custom Slides.38 This is the custom media manager item for Custom Slides.
39 """39 """
40 global log40 global log
41 log=logging.getLogger(u'CustomMediaItem')41 log = logging.getLogger(u'CustomMediaItem')
42 log.info(u'Custom Media Item loaded')42 log.info(u'Custom Media Item loaded')
4343
44 def __init__(self, parent, icon, title):44 def __init__(self, parent, icon, title):
4545
=== modified file 'openlp/plugins/presentations/lib/mediaitem.py'
--- openlp/plugins/presentations/lib/mediaitem.py 2009-09-26 09:11:39 +0000
+++ openlp/plugins/presentations/lib/mediaitem.py 2009-09-29 17:25:26 +0000
@@ -43,7 +43,7 @@
43 It can present files using Openoffice43 It can present files using Openoffice
44 """44 """
45 global log45 global log
46 log=logging.getLogger(u'PresentationsMediaItem')46 log = logging.getLogger(u'PresentationsMediaItem')
47 log.info(u'Presentations Media Item loaded')47 log.info(u'Presentations Media Item loaded')
4848
49 def __init__(self, parent, icon, title, controllers):49 def __init__(self, parent, icon, title, controllers):
5050
=== modified file 'openlp/plugins/presentations/lib/messagelistener.py'
--- openlp/plugins/presentations/lib/messagelistener.py 2009-09-25 22:20:34 +0000
+++ openlp/plugins/presentations/lib/messagelistener.py 2009-09-29 17:25:26 +0000
@@ -30,7 +30,7 @@
30 controller and passes the messages on the the correct presentation handlers30 controller and passes the messages on the the correct presentation handlers
31 """31 """
32 global log32 global log
33 log=logging.getLogger(u'MessageListener')33 log = logging.getLogger(u'MessageListener')
34 log.info(u'Message Listener loaded')34 log.info(u'Message Listener loaded')
3535
36 def __init__(self, controllers):36 def __init__(self, controllers):
3737
=== modified file 'openlp/plugins/presentations/presentationplugin.py'
--- openlp/plugins/presentations/presentationplugin.py 2009-09-29 02:54:32 +0000
+++ openlp/plugins/presentations/presentationplugin.py 2009-09-29 17:25:26 +0000
@@ -36,7 +36,7 @@
3636
37 def __init__(self, plugin_helpers):37 def __init__(self, plugin_helpers):
38 # Call the parent constructor38 # Call the parent constructor
39 log.debug('Initialised')39 log.debug(u'Initialised')
40 self.controllers = {}40 self.controllers = {}
41 Plugin.__init__(self, u'Presentations', u'1.9.0', plugin_helpers)41 Plugin.__init__(self, u'Presentations', u'1.9.0', plugin_helpers)
42 self.weight = -842 self.weight = -8
@@ -66,7 +66,7 @@
66 Check to see if we have any presentation software available66 Check to see if we have any presentation software available
67 If Not do not install the plugin.67 If Not do not install the plugin.
68 """68 """
69 log.debug('check_pre_conditions')69 log.debug(u'check_pre_conditions')
70 #Lets see if Powerpoint is required (Default is Not wanted)70 #Lets see if Powerpoint is required (Default is Not wanted)
71 controller = PowerpointController(self)71 controller = PowerpointController(self)
72 if int(self.config.get_config(72 if int(self.config.get_config(
7373
=== modified file 'openlp/plugins/remotes/remoteplugin.py'
--- openlp/plugins/remotes/remoteplugin.py 2009-09-25 00:43:42 +0000
+++ openlp/plugins/remotes/remoteplugin.py 2009-09-29 17:25:26 +0000
@@ -39,7 +39,7 @@
39 """39 """
40 Check to see if remotes is required40 Check to see if remotes is required
41 """41 """
42 log.debug('check_pre_conditions')42 log.debug(u'check_pre_conditions')
43 #Lets see if Remote is required43 #Lets see if Remote is required
44 if int(self.config.get_config(u'startup', 0)) == QtCore.Qt.Checked:44 if int(self.config.get_config(u'startup', 0)) == QtCore.Qt.Checked:
45 return True45 return True