forked from openlp/openlp
Fix up notification on startup
Fix alerts for presentations Fix remote client so works better Add extra key strokes for display of songs bzr-revno: 701
This commit is contained in:
commit
cd51454628
@ -136,7 +136,7 @@ class OpenLP(QtGui.QApplication):
|
|||||||
# now kill the splashscreen
|
# now kill the splashscreen
|
||||||
self.splash.finish(self.mainWindow)
|
self.splash.finish(self.mainWindow)
|
||||||
self.mainWindow.repaint()
|
self.mainWindow.repaint()
|
||||||
self.mainWindow.versionCheck()
|
self.mainWindow.versionThread()
|
||||||
return self.exec_()
|
return self.exec_()
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
|
@ -54,7 +54,7 @@ class PluginManager(object):
|
|||||||
log.debug(u'Base path %s ', self.basepath)
|
log.debug(u'Base path %s ', self.basepath)
|
||||||
self.plugins = []
|
self.plugins = []
|
||||||
# this has to happen after the UI is sorted self.find_plugins(dir)
|
# this has to happen after the UI is sorted self.find_plugins(dir)
|
||||||
log.info(u'Plugin manager done init')
|
log.info(u'Plugin manager Initialised')
|
||||||
|
|
||||||
def find_plugins(self, dir, plugin_helpers):
|
def find_plugins(self, dir, plugin_helpers):
|
||||||
"""
|
"""
|
||||||
@ -200,6 +200,7 @@ class PluginManager(object):
|
|||||||
% (plugin.name, plugin.is_active()))
|
% (plugin.name, plugin.is_active()))
|
||||||
if plugin.is_active():
|
if plugin.is_active():
|
||||||
plugin.initialise()
|
plugin.initialise()
|
||||||
|
log.info(u'Initialisation Complete for %s ' % plugin.name)
|
||||||
if not plugin.is_active():
|
if not plugin.is_active():
|
||||||
plugin.remove_toolbox_item()
|
plugin.remove_toolbox_item()
|
||||||
|
|
||||||
@ -212,3 +213,4 @@ class PluginManager(object):
|
|||||||
for plugin in self.plugins:
|
for plugin in self.plugins:
|
||||||
if plugin.is_active():
|
if plugin.is_active():
|
||||||
plugin.finalise()
|
plugin.finalise()
|
||||||
|
log.info(u'Finalisation Complete for %s ' % plugin.name)
|
||||||
|
@ -42,4 +42,4 @@ from mainwindow import MainWindow
|
|||||||
|
|
||||||
__all__ = ['SplashScreen', 'AboutForm', 'SettingsForm', 'MainWindow',
|
__all__ = ['SplashScreen', 'AboutForm', 'SettingsForm', 'MainWindow',
|
||||||
'MainDisplay', 'SlideController', 'ServiceManager', 'ThemeManager',
|
'MainDisplay', 'SlideController', 'ServiceManager', 'ThemeManager',
|
||||||
'AmendThemeForm', 'MediaDockManager', 'ThemeLevel']
|
'AmendThemeForm', 'MediaDockManager']
|
||||||
|
@ -44,6 +44,11 @@ class DisplayWidget(QtGui.QWidget):
|
|||||||
def __init__(self, parent=None, name=None):
|
def __init__(self, parent=None, name=None):
|
||||||
QtGui.QWidget.__init__(self, parent)
|
QtGui.QWidget.__init__(self, parent)
|
||||||
self.parent = parent
|
self.parent = parent
|
||||||
|
self.hotkey_map = {QtCore.Qt.Key_Return: 'servicemanager_next_item',
|
||||||
|
QtCore.Qt.Key_Space: 'live_slidecontroller_next_noloop',
|
||||||
|
QtCore.Qt.Key_Enter: 'live_slidecontroller_next_noloop',
|
||||||
|
QtCore.Qt.Key_0: 'servicemanager_next_item',
|
||||||
|
QtCore.Qt.Key_Backspace: 'live_slidecontroller_previous_noloop'}
|
||||||
|
|
||||||
def keyPressEvent(self, event):
|
def keyPressEvent(self, event):
|
||||||
if type(event) == QtGui.QKeyEvent:
|
if type(event) == QtGui.QKeyEvent:
|
||||||
@ -60,6 +65,9 @@ class DisplayWidget(QtGui.QWidget):
|
|||||||
elif event.key() == QtCore.Qt.Key_PageDown:
|
elif event.key() == QtCore.Qt.Key_PageDown:
|
||||||
Receiver.send_message(u'live_slidecontroller_last')
|
Receiver.send_message(u'live_slidecontroller_last')
|
||||||
event.accept()
|
event.accept()
|
||||||
|
elif event.key() in self.hotkey_map:
|
||||||
|
Receiver.send_message(self.hotkey_map[event.key()]);
|
||||||
|
event.accept()
|
||||||
elif event.key() == QtCore.Qt.Key_Escape:
|
elif event.key() == QtCore.Qt.Key_Escape:
|
||||||
self.resetDisplay()
|
self.resetDisplay()
|
||||||
event.accept()
|
event.accept()
|
||||||
@ -194,22 +202,21 @@ class MainDisplay(DisplayWidget):
|
|||||||
self.showFullScreen()
|
self.showFullScreen()
|
||||||
|
|
||||||
def hideDisplay(self):
|
def hideDisplay(self):
|
||||||
|
self.mediaLoaded = True
|
||||||
self.setVisible(False)
|
self.setVisible(False)
|
||||||
|
|
||||||
def showDisplay(self):
|
def showDisplay(self):
|
||||||
|
self.mediaLoaded = False
|
||||||
if not self.primary:
|
if not self.primary:
|
||||||
self.setVisible(True)
|
self.setVisible(True)
|
||||||
self.showFullScreen()
|
self.showFullScreen()
|
||||||
|
self.generateAlert()
|
||||||
|
|
||||||
def addImageWithText(self, frame):
|
def addImageWithText(self, frame):
|
||||||
frame = resize_image(frame,
|
frame = resize_image(frame,
|
||||||
self.screen[u'size'].width(),
|
self.screen[u'size'].width(),
|
||||||
self.screen[u'size'].height() )
|
self.screen[u'size'].height() )
|
||||||
self.display_image.setPixmap(QtGui.QPixmap.fromImage(frame))
|
self.display_image.setPixmap(QtGui.QPixmap.fromImage(frame))
|
||||||
# self.display_image.show()
|
|
||||||
# if not self.isVisible():
|
|
||||||
# self.setVisible(True)
|
|
||||||
# self.showFullScreen()
|
|
||||||
|
|
||||||
def frameView(self, frame, transition=False):
|
def frameView(self, frame, transition=False):
|
||||||
"""
|
"""
|
||||||
|
@ -25,6 +25,7 @@
|
|||||||
|
|
||||||
import os
|
import os
|
||||||
import logging
|
import logging
|
||||||
|
import time
|
||||||
|
|
||||||
from PyQt4 import QtCore, QtGui
|
from PyQt4 import QtCore, QtGui
|
||||||
|
|
||||||
@ -50,6 +51,15 @@ media_manager_style = """
|
|||||||
border-color: palette(light);
|
border-color: palette(light);
|
||||||
}
|
}
|
||||||
"""
|
"""
|
||||||
|
class versionThread(QtCore.QThread):
|
||||||
|
def __init__(self, parent):
|
||||||
|
QtCore.QThread.__init__(self, parent)
|
||||||
|
self.parent = parent
|
||||||
|
def run (self):
|
||||||
|
time.sleep(2)
|
||||||
|
Receiver.send_message(u'version_check')
|
||||||
|
|
||||||
|
|
||||||
class Ui_MainWindow(object):
|
class Ui_MainWindow(object):
|
||||||
def setupUi(self, MainWindow):
|
def setupUi(self, MainWindow):
|
||||||
"""
|
"""
|
||||||
@ -483,6 +493,8 @@ class MainWindow(QtGui.QMainWindow, Ui_MainWindow):
|
|||||||
QtCore.SIGNAL(u'triggered()'), self.onOptionsSettingsItemClicked)
|
QtCore.SIGNAL(u'triggered()'), self.onOptionsSettingsItemClicked)
|
||||||
QtCore.QObject.connect(Receiver.get_receiver(),
|
QtCore.QObject.connect(Receiver.get_receiver(),
|
||||||
QtCore.SIGNAL(u'update_global_theme'), self.defaultThemeChanged)
|
QtCore.SIGNAL(u'update_global_theme'), self.defaultThemeChanged)
|
||||||
|
QtCore.QObject.connect(Receiver.get_receiver(),
|
||||||
|
QtCore.SIGNAL(u'version_check'), self.versionCheck)
|
||||||
QtCore.QObject.connect(self.FileNewItem,
|
QtCore.QObject.connect(self.FileNewItem,
|
||||||
QtCore.SIGNAL(u'triggered()'),
|
QtCore.SIGNAL(u'triggered()'),
|
||||||
self.ServiceManagerContents.onNewService)
|
self.ServiceManagerContents.onNewService)
|
||||||
@ -582,6 +594,10 @@ class MainWindow(QtGui.QMainWindow, Ui_MainWindow):
|
|||||||
QtGui.QMessageBox.StandardButtons(QtGui.QMessageBox.Ok),
|
QtGui.QMessageBox.StandardButtons(QtGui.QMessageBox.Ok),
|
||||||
QtGui.QMessageBox.Ok)
|
QtGui.QMessageBox.Ok)
|
||||||
|
|
||||||
|
def versionThread(self):
|
||||||
|
vT = versionThread(self)
|
||||||
|
vT.start()
|
||||||
|
|
||||||
def onHelpAboutItemClicked(self):
|
def onHelpAboutItemClicked(self):
|
||||||
"""
|
"""
|
||||||
Show the About form
|
Show the About form
|
||||||
|
@ -227,6 +227,8 @@ class ServiceManager(QtGui.QWidget):
|
|||||||
QtCore.SIGNAL(u'remote_edit_clear'), self.onRemoteEditClear)
|
QtCore.SIGNAL(u'remote_edit_clear'), self.onRemoteEditClear)
|
||||||
QtCore.QObject.connect(Receiver.get_receiver(),
|
QtCore.QObject.connect(Receiver.get_receiver(),
|
||||||
QtCore.SIGNAL(u'presentation types'), self.onPresentationTypes)
|
QtCore.SIGNAL(u'presentation types'), self.onPresentationTypes)
|
||||||
|
QtCore.QObject.connect(Receiver.get_receiver(),
|
||||||
|
QtCore.SIGNAL(u'servicemanager_next_item'), self.nextItem)
|
||||||
# Last little bits of setting up
|
# Last little bits of setting up
|
||||||
self.config = PluginConfig(u'ServiceManager')
|
self.config = PluginConfig(u'ServiceManager')
|
||||||
self.servicePath = self.config.get_data_path()
|
self.servicePath = self.config.get_data_path()
|
||||||
@ -236,12 +238,31 @@ class ServiceManager(QtGui.QWidget):
|
|||||||
def onPresentationTypes(self, presentation_types):
|
def onPresentationTypes(self, presentation_types):
|
||||||
self.presentation_types = presentation_types
|
self.presentation_types = presentation_types
|
||||||
|
|
||||||
|
def nextItem(self):
|
||||||
|
"""
|
||||||
|
Called by the SlideController to select the
|
||||||
|
next service item
|
||||||
|
"""
|
||||||
|
if len(self.ServiceManagerList.selectedItems()) == 0:
|
||||||
|
return
|
||||||
|
selected = self.ServiceManagerList.selectedItems()[0]
|
||||||
|
lookFor = 0
|
||||||
|
serviceIterator = QtGui.QTreeWidgetItemIterator(self.ServiceManagerList)
|
||||||
|
while serviceIterator.value():
|
||||||
|
if lookFor == 1 and serviceIterator.value().parent() is None:
|
||||||
|
self.ServiceManagerList.setCurrentItem(serviceIterator.value())
|
||||||
|
self.makeLive()
|
||||||
|
return
|
||||||
|
if serviceIterator.value() == selected:
|
||||||
|
lookFor = 1
|
||||||
|
serviceIterator += 1
|
||||||
|
|
||||||
def onMoveSelectionUp(self):
|
def onMoveSelectionUp(self):
|
||||||
"""
|
"""
|
||||||
Moves the selection up the window
|
Moves the selection up the window
|
||||||
Called by the up arrow
|
Called by the up arrow
|
||||||
"""
|
"""
|
||||||
serviceIterator = QTreeWidgetItemIterator(self.ServiceManagerList)
|
serviceIterator = QtGui.QTreeWidgetItemIterator(self.ServiceManagerList)
|
||||||
tempItem = None
|
tempItem = None
|
||||||
setLastItem = False
|
setLastItem = False
|
||||||
while serviceIterator:
|
while serviceIterator:
|
||||||
@ -266,7 +287,7 @@ class ServiceManager(QtGui.QWidget):
|
|||||||
Moves the selection down the window
|
Moves the selection down the window
|
||||||
Called by the down arrow
|
Called by the down arrow
|
||||||
"""
|
"""
|
||||||
serviceIterator = QTreeWidgetItemIterator(self.ServiceManagerList)
|
serviceIterator = QtGui.QTreeWidgetItemIterator(self.ServiceManagerList)
|
||||||
firstItem = serviceIterator
|
firstItem = serviceIterator
|
||||||
setSelected = False
|
setSelected = False
|
||||||
while serviceIterator:
|
while serviceIterator:
|
||||||
|
@ -41,6 +41,11 @@ class SlideList(QtGui.QTableWidget):
|
|||||||
def __init__(self, parent=None, name=None):
|
def __init__(self, parent=None, name=None):
|
||||||
QtGui.QTableWidget.__init__(self, parent.Controller)
|
QtGui.QTableWidget.__init__(self, parent.Controller)
|
||||||
self.parent = parent
|
self.parent = parent
|
||||||
|
self.hotkey_map = {QtCore.Qt.Key_Return: 'servicemanager_next_item',
|
||||||
|
QtCore.Qt.Key_Space: 'live_slidecontroller_next_noloop',
|
||||||
|
QtCore.Qt.Key_Enter: 'live_slidecontroller_next_noloop',
|
||||||
|
QtCore.Qt.Key_0: 'servicemanager_next_item',
|
||||||
|
QtCore.Qt.Key_Backspace: 'live_slidecontroller_previous_noloop'}
|
||||||
|
|
||||||
def keyPressEvent(self, event):
|
def keyPressEvent(self, event):
|
||||||
if type(event) == QtGui.QKeyEvent:
|
if type(event) == QtGui.QKeyEvent:
|
||||||
@ -57,6 +62,9 @@ class SlideList(QtGui.QTableWidget):
|
|||||||
elif event.key() == QtCore.Qt.Key_PageDown:
|
elif event.key() == QtCore.Qt.Key_PageDown:
|
||||||
self.parent.onSlideSelectedLast()
|
self.parent.onSlideSelectedLast()
|
||||||
event.accept()
|
event.accept()
|
||||||
|
elif event.key() in self.hotkey_map and self.parent.isLive:
|
||||||
|
Receiver.send_message(self.hotkey_map[event.key()]);
|
||||||
|
event.accept()
|
||||||
event.ignore()
|
event.ignore()
|
||||||
else:
|
else:
|
||||||
event.ignore()
|
event.ignore()
|
||||||
@ -277,6 +285,11 @@ class SlideController(QtGui.QWidget):
|
|||||||
QtCore.SIGNAL(u'%s_next' % prefix), self.onSlideSelectedNext)
|
QtCore.SIGNAL(u'%s_next' % prefix), self.onSlideSelectedNext)
|
||||||
QtCore.QObject.connect(Receiver.get_receiver(),
|
QtCore.QObject.connect(Receiver.get_receiver(),
|
||||||
QtCore.SIGNAL(u'%s_previous' % prefix), self.onSlideSelectedPrevious)
|
QtCore.SIGNAL(u'%s_previous' % prefix), self.onSlideSelectedPrevious)
|
||||||
|
QtCore.QObject.connect(Receiver.get_receiver(),
|
||||||
|
QtCore.SIGNAL(u'%s_next_noloop' % prefix), self.onSlideSelectedNextNoloop)
|
||||||
|
QtCore.QObject.connect(Receiver.get_receiver(),
|
||||||
|
QtCore.SIGNAL(u'%s_previous_noloop' % prefix),
|
||||||
|
self.onSlideSelectedPreviousNoloop)
|
||||||
QtCore.QObject.connect(Receiver.get_receiver(),
|
QtCore.QObject.connect(Receiver.get_receiver(),
|
||||||
QtCore.SIGNAL(u'%s_last' % prefix), self.onSlideSelectedLast)
|
QtCore.SIGNAL(u'%s_last' % prefix), self.onSlideSelectedLast)
|
||||||
QtCore.QObject.connect(Receiver.get_receiver(),
|
QtCore.QObject.connect(Receiver.get_receiver(),
|
||||||
@ -561,7 +574,10 @@ class SlideController(QtGui.QWidget):
|
|||||||
rect.y(), rect.width(), rect.height())
|
rect.y(), rect.width(), rect.height())
|
||||||
self.SlidePreview.setPixmap(winimg)
|
self.SlidePreview.setPixmap(winimg)
|
||||||
|
|
||||||
def onSlideSelectedNext(self):
|
def onSlideSelectedNextNoloop(self):
|
||||||
|
self.onSlideSelectedNext(False)
|
||||||
|
|
||||||
|
def onSlideSelectedNext(self, loop=True):
|
||||||
"""
|
"""
|
||||||
Go to the next slide.
|
Go to the next slide.
|
||||||
"""
|
"""
|
||||||
@ -574,11 +590,18 @@ class SlideController(QtGui.QWidget):
|
|||||||
else:
|
else:
|
||||||
row = self.PreviewListWidget.currentRow() + 1
|
row = self.PreviewListWidget.currentRow() + 1
|
||||||
if row == self.PreviewListWidget.rowCount():
|
if row == self.PreviewListWidget.rowCount():
|
||||||
|
if loop:
|
||||||
row = 0
|
row = 0
|
||||||
|
else:
|
||||||
|
Receiver.send_message('servicemanager_next_item')
|
||||||
|
return
|
||||||
self.PreviewListWidget.selectRow(row)
|
self.PreviewListWidget.selectRow(row)
|
||||||
self.onSlideSelected()
|
self.onSlideSelected()
|
||||||
|
|
||||||
def onSlideSelectedPrevious(self):
|
def onSlideSelectedPreviousNoloop(self):
|
||||||
|
self.onSlideSelectedPrevious(False)
|
||||||
|
|
||||||
|
def onSlideSelectedPrevious(self, loop=True):
|
||||||
"""
|
"""
|
||||||
Go to the previous slide.
|
Go to the previous slide.
|
||||||
"""
|
"""
|
||||||
@ -591,7 +614,10 @@ class SlideController(QtGui.QWidget):
|
|||||||
else:
|
else:
|
||||||
row = self.PreviewListWidget.currentRow() - 1
|
row = self.PreviewListWidget.currentRow() - 1
|
||||||
if row == -1:
|
if row == -1:
|
||||||
|
if loop:
|
||||||
row = self.PreviewListWidget.rowCount() - 1
|
row = self.PreviewListWidget.rowCount() - 1
|
||||||
|
else:
|
||||||
|
row = 0
|
||||||
self.PreviewListWidget.selectRow(row)
|
self.PreviewListWidget.selectRow(row)
|
||||||
self.onSlideSelected()
|
self.onSlideSelected()
|
||||||
|
|
||||||
|
@ -37,12 +37,14 @@ log = logging.getLogger(__name__)
|
|||||||
|
|
||||||
def check_latest_version(config, current_version):
|
def check_latest_version(config, current_version):
|
||||||
version_string = current_version
|
version_string = current_version
|
||||||
|
#set to prod in the distribution confif file.
|
||||||
|
environment = config.get_config(u'run environment', u'dev')
|
||||||
last_test = config.get_config(u'last version test', datetime.now().date())
|
last_test = config.get_config(u'last version test', datetime.now().date())
|
||||||
this_test = unicode(datetime.now().date())
|
this_test = unicode(datetime.now().date())
|
||||||
config.set_config(u'last version test', this_test)
|
config.set_config(u'last version test', this_test)
|
||||||
if last_test != this_test:
|
if last_test != this_test:
|
||||||
version_string = u''
|
version_string = u''
|
||||||
req = urllib2.Request(u'http://www.openlp.org/files/version.txt')
|
req = urllib2.Request(u'http://www.openlp.org/files/%s_version.txt' % environment)
|
||||||
req.add_header(u'User-Agent', u'OpenLP/%s' % current_version)
|
req.add_header(u'User-Agent', u'OpenLP/%s' % current_version)
|
||||||
try:
|
try:
|
||||||
handle = urllib2.urlopen(req, None)
|
handle = urllib2.urlopen(req, None)
|
||||||
|
@ -27,7 +27,7 @@ import logging
|
|||||||
|
|
||||||
from PyQt4 import QtCore, QtGui
|
from PyQt4 import QtCore, QtGui
|
||||||
|
|
||||||
from openlp.core.lib import Plugin, build_icon
|
from openlp.core.lib import Plugin, build_icon, PluginStatus
|
||||||
from openlp.plugins.bibles.lib import BibleManager, BiblesTab, BibleMediaItem
|
from openlp.plugins.bibles.lib import BibleManager, BiblesTab, BibleMediaItem
|
||||||
|
|
||||||
class BiblePlugin(Plugin):
|
class BiblePlugin(Plugin):
|
||||||
@ -36,10 +36,11 @@ class BiblePlugin(Plugin):
|
|||||||
log.info(u'Bible Plugin loaded')
|
log.info(u'Bible Plugin loaded')
|
||||||
|
|
||||||
def __init__(self, plugin_helpers):
|
def __init__(self, plugin_helpers):
|
||||||
Plugin.__init__(self, u'Bibles', u'1.9.0', plugin_helpers)
|
Plugin.__init__(self, u'Bibles', u'1.9.1', plugin_helpers)
|
||||||
self.weight = -9
|
self.weight = -9
|
||||||
self.icon = build_icon(u':/media/media_bible.png')
|
self.icon = build_icon(u':/media/media_bible.png')
|
||||||
#Register the bible Manager
|
#Register the bible Manager
|
||||||
|
self.status = PluginStatus.Active
|
||||||
self.manager = None
|
self.manager = None
|
||||||
|
|
||||||
def initialise(self):
|
def initialise(self):
|
||||||
@ -91,4 +92,3 @@ class BiblePlugin(Plugin):
|
|||||||
'plugin allows bible verses from different sources to be '
|
'plugin allows bible verses from different sources to be '
|
||||||
'displayed on the screen during the service.')
|
'displayed on the screen during the service.')
|
||||||
return about_text
|
return about_text
|
||||||
|
|
||||||
|
@ -51,15 +51,15 @@ class CSVBible(BibleDB):
|
|||||||
if u'versesfile' not in kwargs:
|
if u'versesfile' not in kwargs:
|
||||||
raise KeyError(u'You have to supply a file to import verses from.')
|
raise KeyError(u'You have to supply a file to import verses from.')
|
||||||
self.versesfile = kwargs[u'versesfile']
|
self.versesfile = kwargs[u'versesfile']
|
||||||
#QtCore.QObject.connect(Receiver.get_receiver(),
|
QtCore.QObject.connect(Receiver.get_receiver(),
|
||||||
# QtCore.SIGNAL(u'openlpstopimport'), self.stop_import)
|
QtCore.SIGNAL(u'openlpstopimport'), self.stop_import)
|
||||||
|
|
||||||
def stop_import(self):
|
def stop_import(self):
|
||||||
"""
|
"""
|
||||||
Stops the import of the Bible.
|
Stops the import of the Bible.
|
||||||
"""
|
"""
|
||||||
log.debug('Stopping import!')
|
log.debug('Stopping import!')
|
||||||
self.stop_import = True
|
self.stop_import_flag = True
|
||||||
|
|
||||||
def do_import(self):
|
def do_import(self):
|
||||||
#Populate the Tables
|
#Populate the Tables
|
||||||
@ -72,7 +72,7 @@ class CSVBible(BibleDB):
|
|||||||
books_reader = csv.reader(books_file, dialect)
|
books_reader = csv.reader(books_file, dialect)
|
||||||
for line in books_reader:
|
for line in books_reader:
|
||||||
# cancel pressed
|
# cancel pressed
|
||||||
if self.stop_import:
|
if self.stop_import_flag:
|
||||||
break
|
break
|
||||||
details = chardet.detect(line[1])
|
details = chardet.detect(line[1])
|
||||||
self.create_book(unicode(line[1], details['encoding']),
|
self.create_book(unicode(line[1], details['encoding']),
|
||||||
@ -94,7 +94,7 @@ class CSVBible(BibleDB):
|
|||||||
verse_file.seek(0)
|
verse_file.seek(0)
|
||||||
verse_reader = csv.reader(verse_file, dialect)
|
verse_reader = csv.reader(verse_file, dialect)
|
||||||
for line in verse_reader:
|
for line in verse_reader:
|
||||||
if self.stop_import: # cancel pressed
|
if self.stop_import_flag: # cancel pressed
|
||||||
break
|
break
|
||||||
details = chardet.detect(line[3])
|
details = chardet.detect(line[3])
|
||||||
if book_ptr != line[0]:
|
if book_ptr != line[0]:
|
||||||
@ -113,7 +113,7 @@ class CSVBible(BibleDB):
|
|||||||
finally:
|
finally:
|
||||||
if verse_file:
|
if verse_file:
|
||||||
verse_file.close()
|
verse_file.close()
|
||||||
if self.stop_import:
|
if self.stop_import_flag:
|
||||||
self.wizard.incrementProgressBar(u'Import canceled!')
|
self.wizard.incrementProgressBar(u'Import canceled!')
|
||||||
return False
|
return False
|
||||||
else:
|
else:
|
||||||
|
@ -67,7 +67,7 @@ class BibleDB(QtCore.QObject):
|
|||||||
raise KeyError(u'Missing keyword argument "name".')
|
raise KeyError(u'Missing keyword argument "name".')
|
||||||
if u'config' not in kwargs:
|
if u'config' not in kwargs:
|
||||||
raise KeyError(u'Missing keyword argument "config".')
|
raise KeyError(u'Missing keyword argument "config".')
|
||||||
self.stop_import = False
|
self.stop_import_flag = False
|
||||||
self.name = kwargs[u'name']
|
self.name = kwargs[u'name']
|
||||||
self.config = kwargs[u'config']
|
self.config = kwargs[u'config']
|
||||||
self.db_file = os.path.join(kwargs[u'path'],
|
self.db_file = os.path.join(kwargs[u'path'],
|
||||||
|
@ -52,15 +52,15 @@ class OpenSongBible(BibleDB):
|
|||||||
if 'filename' not in kwargs:
|
if 'filename' not in kwargs:
|
||||||
raise KeyError(u'You have to supply a file name to import from.')
|
raise KeyError(u'You have to supply a file name to import from.')
|
||||||
self.filename = kwargs['filename']
|
self.filename = kwargs['filename']
|
||||||
#QtCore.QObject.connect(Receiver.get_receiver(),
|
QtCore.QObject.connect(Receiver.get_receiver(),
|
||||||
# QtCore.SIGNAL(u'openlpstopimport'), self.stop_import)
|
QtCore.SIGNAL(u'openlpstopimport'), self.stop_import)
|
||||||
|
|
||||||
def stop_import(self):
|
def stop_import(self):
|
||||||
"""
|
"""
|
||||||
Stops the import of the Bible.
|
Stops the import of the Bible.
|
||||||
"""
|
"""
|
||||||
log.debug('Stopping import!')
|
log.debug('Stopping import!')
|
||||||
self.stop_import = True
|
self.stop_import_flag = True
|
||||||
|
|
||||||
def do_import(self):
|
def do_import(self):
|
||||||
"""
|
"""
|
||||||
@ -79,15 +79,15 @@ class OpenSongBible(BibleDB):
|
|||||||
opensong = objectify.parse(file)
|
opensong = objectify.parse(file)
|
||||||
bible = opensong.getroot()
|
bible = opensong.getroot()
|
||||||
for book in bible.b:
|
for book in bible.b:
|
||||||
if self.stop_import:
|
if self.stop_import_flag:
|
||||||
break
|
break
|
||||||
db_book = self.create_book(unicode(book.attrib[u'n']),
|
db_book = self.create_book(unicode(book.attrib[u'n']),
|
||||||
unicode(book.attrib[u'n'][:4]))
|
unicode(book.attrib[u'n'][:4]))
|
||||||
for chapter in book.c:
|
for chapter in book.c:
|
||||||
if self.stop_import:
|
if self.stop_import_flag:
|
||||||
break
|
break
|
||||||
for verse in chapter.v:
|
for verse in chapter.v:
|
||||||
if self.stop_import:
|
if self.stop_import_flag:
|
||||||
break
|
break
|
||||||
self.create_verse(
|
self.create_verse(
|
||||||
db_book.id,
|
db_book.id,
|
||||||
|
@ -81,15 +81,15 @@ class OSISBible(BibleDB):
|
|||||||
finally:
|
finally:
|
||||||
if fbibles:
|
if fbibles:
|
||||||
fbibles.close()
|
fbibles.close()
|
||||||
#QtCore.QObject.connect(Receiver.get_receiver(),
|
QtCore.QObject.connect(Receiver.get_receiver(),
|
||||||
# QtCore.SIGNAL(u'openlpstopimport'), self.stop_import)
|
QtCore.SIGNAL(u'openlpstopimport'), self.stop_import)
|
||||||
|
|
||||||
def stop_import(self):
|
def stop_import(self):
|
||||||
"""
|
"""
|
||||||
Stops the import of the Bible.
|
Stops the import of the Bible.
|
||||||
"""
|
"""
|
||||||
log.debug('Stopping import!')
|
log.debug('Stopping import!')
|
||||||
self.stop_import = True
|
self.stop_import_flag = True
|
||||||
|
|
||||||
def do_import(self):
|
def do_import(self):
|
||||||
"""
|
"""
|
||||||
@ -114,7 +114,7 @@ class OSISBible(BibleDB):
|
|||||||
testament = 1
|
testament = 1
|
||||||
db_book = None
|
db_book = None
|
||||||
for file_record in osis:
|
for file_record in osis:
|
||||||
if self.stop_import:
|
if self.stop_import_flag:
|
||||||
break
|
break
|
||||||
match = self.verse_regex.search(file_record)
|
match = self.verse_regex.search(file_record)
|
||||||
if match:
|
if match:
|
||||||
@ -126,7 +126,7 @@ class OSISBible(BibleDB):
|
|||||||
log.debug('New book: "%s"', self.books[book][0])
|
log.debug('New book: "%s"', self.books[book][0])
|
||||||
if book == u'Matt':
|
if book == u'Matt':
|
||||||
testament += 1
|
testament += 1
|
||||||
db_book = self.bibledb.create_book(
|
db_book = self.create_book(
|
||||||
unicode(self.books[book][0]),
|
unicode(self.books[book][0]),
|
||||||
unicode(self.books[book][1]),
|
unicode(self.books[book][1]),
|
||||||
testament)
|
testament)
|
||||||
@ -137,7 +137,7 @@ class OSISBible(BibleDB):
|
|||||||
self.wizard.ImportProgressBar.setMaximum(260)
|
self.wizard.ImportProgressBar.setMaximum(260)
|
||||||
if last_chapter != chapter:
|
if last_chapter != chapter:
|
||||||
if last_chapter != 0:
|
if last_chapter != 0:
|
||||||
self.bibledb.save_verses()
|
self.commit()
|
||||||
self.wizard.incrementProgressBar(
|
self.wizard.incrementProgressBar(
|
||||||
u'Importing %s %s...' % \
|
u'Importing %s %s...' % \
|
||||||
(self.books[match.group(1)][0], chapter))
|
(self.books[match.group(1)][0], chapter))
|
||||||
@ -170,9 +170,8 @@ class OSISBible(BibleDB):
|
|||||||
finally:
|
finally:
|
||||||
if osis:
|
if osis:
|
||||||
osis.close()
|
osis.close()
|
||||||
if self.stop_import:
|
if self.stop_import_flag:
|
||||||
self.wizard.incrementProgressBar(u'Import canceled!')
|
self.wizard.incrementProgressBar(u'Import canceled!')
|
||||||
return False
|
return False
|
||||||
else:
|
else:
|
||||||
return success
|
return success
|
||||||
|
|
||||||
|
@ -26,7 +26,7 @@
|
|||||||
import logging
|
import logging
|
||||||
|
|
||||||
from forms import EditCustomForm
|
from forms import EditCustomForm
|
||||||
from openlp.core.lib import Plugin, build_icon
|
from openlp.core.lib import Plugin, build_icon, PluginStatus
|
||||||
from openlp.plugins.custom.lib import CustomManager, CustomMediaItem, CustomTab
|
from openlp.plugins.custom.lib import CustomManager, CustomMediaItem, CustomTab
|
||||||
|
|
||||||
|
|
||||||
@ -45,11 +45,12 @@ class CustomPlugin(Plugin):
|
|||||||
log.info(u'Custom Plugin loaded')
|
log.info(u'Custom Plugin loaded')
|
||||||
|
|
||||||
def __init__(self, plugin_helpers):
|
def __init__(self, plugin_helpers):
|
||||||
Plugin.__init__(self, u'Custom', u'1.9.0', plugin_helpers)
|
Plugin.__init__(self, u'Custom', u'1.9.1', plugin_helpers)
|
||||||
self.weight = -5
|
self.weight = -5
|
||||||
self.custommanager = CustomManager(self.config)
|
self.custommanager = CustomManager(self.config)
|
||||||
self.edit_custom_form = EditCustomForm(self.custommanager)
|
self.edit_custom_form = EditCustomForm(self.custommanager)
|
||||||
self.icon = build_icon(u':/media/media_custom.png')
|
self.icon = build_icon(u':/media/media_custom.png')
|
||||||
|
self.status = PluginStatus.Active
|
||||||
|
|
||||||
def get_settings_tab(self):
|
def get_settings_tab(self):
|
||||||
return CustomTab(self.name)
|
return CustomTab(self.name)
|
||||||
|
@ -25,7 +25,7 @@
|
|||||||
|
|
||||||
import logging
|
import logging
|
||||||
|
|
||||||
from openlp.core.lib import Plugin, build_icon
|
from openlp.core.lib import Plugin, build_icon, PluginStatus
|
||||||
from openlp.plugins.images.lib import ImageMediaItem, ImageTab
|
from openlp.plugins.images.lib import ImageMediaItem, ImageTab
|
||||||
|
|
||||||
class ImagePlugin(Plugin):
|
class ImagePlugin(Plugin):
|
||||||
@ -34,9 +34,10 @@ class ImagePlugin(Plugin):
|
|||||||
log.info(u'Image Plugin loaded')
|
log.info(u'Image Plugin loaded')
|
||||||
|
|
||||||
def __init__(self, plugin_helpers):
|
def __init__(self, plugin_helpers):
|
||||||
Plugin.__init__(self, u'Images', u'1.9.0', plugin_helpers)
|
Plugin.__init__(self, u'Images', u'1.9.1', plugin_helpers)
|
||||||
self.weight = -7
|
self.weight = -7
|
||||||
self.icon = build_icon(u':/media/media_image.png')
|
self.icon = build_icon(u':/media/media_image.png')
|
||||||
|
self.status = PluginStatus.Active
|
||||||
|
|
||||||
def initialise(self):
|
def initialise(self):
|
||||||
log.info(u'Plugin Initialising')
|
log.info(u'Plugin Initialising')
|
||||||
|
@ -25,7 +25,7 @@
|
|||||||
|
|
||||||
import logging
|
import logging
|
||||||
|
|
||||||
from openlp.core.lib import Plugin, build_icon
|
from openlp.core.lib import Plugin, build_icon, PluginStatus
|
||||||
from openlp.plugins.media.lib import MediaMediaItem
|
from openlp.plugins.media.lib import MediaMediaItem
|
||||||
|
|
||||||
class MediaPlugin(Plugin):
|
class MediaPlugin(Plugin):
|
||||||
@ -34,11 +34,12 @@ class MediaPlugin(Plugin):
|
|||||||
log.info(u'Media Plugin loaded')
|
log.info(u'Media Plugin loaded')
|
||||||
|
|
||||||
def __init__(self, plugin_helpers):
|
def __init__(self, plugin_helpers):
|
||||||
Plugin.__init__(self, u'Media', u'1.9.0', plugin_helpers)
|
Plugin.__init__(self, u'Media', u'1.9.1', plugin_helpers)
|
||||||
self.weight = -6
|
self.weight = -6
|
||||||
self.icon = build_icon(u':/media/media_video.png')
|
self.icon = build_icon(u':/media/media_video.png')
|
||||||
# passed with drag and drop messages
|
# passed with drag and drop messages
|
||||||
self.dnd_id = u'Media'
|
self.dnd_id = u'Media'
|
||||||
|
self.status = PluginStatus.Active
|
||||||
|
|
||||||
def initialise(self):
|
def initialise(self):
|
||||||
log.info(u'Plugin Initialising')
|
log.info(u'Plugin Initialising')
|
||||||
|
@ -26,7 +26,7 @@
|
|||||||
import os
|
import os
|
||||||
import logging
|
import logging
|
||||||
|
|
||||||
from openlp.core.lib import Plugin, build_icon, Receiver
|
from openlp.core.lib import Plugin, build_icon, Receiver, PluginStatus
|
||||||
from openlp.plugins.presentations.lib import *
|
from openlp.plugins.presentations.lib import *
|
||||||
|
|
||||||
class PresentationPlugin(Plugin):
|
class PresentationPlugin(Plugin):
|
||||||
@ -37,9 +37,10 @@ class PresentationPlugin(Plugin):
|
|||||||
def __init__(self, plugin_helpers):
|
def __init__(self, plugin_helpers):
|
||||||
log.debug(u'Initialised')
|
log.debug(u'Initialised')
|
||||||
self.controllers = {}
|
self.controllers = {}
|
||||||
Plugin.__init__(self, u'Presentations', u'1.9.0', plugin_helpers)
|
Plugin.__init__(self, u'Presentations', u'1.9.1', plugin_helpers)
|
||||||
self.weight = -8
|
self.weight = -8
|
||||||
self.icon = build_icon(u':/media/media_presentation.png')
|
self.icon = build_icon(u':/media/media_presentation.png')
|
||||||
|
self.status = PluginStatus.Active
|
||||||
|
|
||||||
def get_settings_tab(self):
|
def get_settings_tab(self):
|
||||||
"""
|
"""
|
||||||
|
@ -28,7 +28,6 @@ import socket
|
|||||||
import sys
|
import sys
|
||||||
from optparse import OptionParser
|
from optparse import OptionParser
|
||||||
|
|
||||||
|
|
||||||
def sendData(options, message):
|
def sendData(options, message):
|
||||||
addr = (options.address, options.port)
|
addr = (options.address, options.port)
|
||||||
try:
|
try:
|
||||||
@ -47,34 +46,23 @@ def main():
|
|||||||
parser.add_option("-v", "--verbose",
|
parser.add_option("-v", "--verbose",
|
||||||
action="store_true", dest="verbose", default=True,
|
action="store_true", dest="verbose", default=True,
|
||||||
help="make lots of noise [%default]")
|
help="make lots of noise [%default]")
|
||||||
parser.add_option("-p", "--port",
|
parser.add_option("-p", "--port", default=4316,
|
||||||
default=4316,
|
|
||||||
help="IP Port number %default ")
|
help="IP Port number %default ")
|
||||||
parser.add_option("-a", "--address",
|
parser.add_option("-a", "--address",
|
||||||
help="Recipient address ")
|
help="Recipient address ")
|
||||||
parser.add_option("-e", "--event",
|
|
||||||
default=u'Alert',
|
|
||||||
help="Action to be undertaken")
|
|
||||||
parser.add_option("-m", "--message",
|
parser.add_option("-m", "--message",
|
||||||
help="Message to be passed for the action")
|
help="Message to be passed for the action")
|
||||||
parser.add_option("-n", "--slidenext",
|
|
||||||
help="Trigger the next slide")
|
|
||||||
|
|
||||||
(options, args) = parser.parse_args()
|
(options, args) = parser.parse_args()
|
||||||
if len(args) > 0:
|
if len(args) > 0:
|
||||||
parser.print_help()
|
parser.print_help()
|
||||||
parser.error("incorrect number of arguments")
|
parser.error("incorrect number of arguments")
|
||||||
elif options.message is None:
|
|
||||||
parser.print_help()
|
|
||||||
parser.error("No message passed")
|
|
||||||
elif options.address is None:
|
elif options.address is None:
|
||||||
parser.print_help()
|
parser.print_help()
|
||||||
parser.error("IP address missing")
|
parser.error("IP address missing")
|
||||||
elif options.slidenext:
|
elif options.message is None:
|
||||||
options.event = u'next_slide'
|
parser.print_help()
|
||||||
options.message = u''
|
parser.error("No message passed")
|
||||||
text = format_message(options)
|
|
||||||
sendData(options, text)
|
|
||||||
else:
|
else:
|
||||||
text = format_message(options)
|
text = format_message(options)
|
||||||
sendData(options, text)
|
sendData(options, text)
|
@ -37,7 +37,7 @@ class RemotesPlugin(Plugin):
|
|||||||
log.info(u'Remote Plugin loaded')
|
log.info(u'Remote Plugin loaded')
|
||||||
|
|
||||||
def __init__(self, plugin_helpers):
|
def __init__(self, plugin_helpers):
|
||||||
Plugin.__init__(self, u'Remotes', u'1.9.0', plugin_helpers)
|
Plugin.__init__(self, u'Remotes', u'1.9.1', plugin_helpers)
|
||||||
self.weight = -1
|
self.weight = -1
|
||||||
self.server = None
|
self.server = None
|
||||||
|
|
||||||
|
@ -1,113 +1,129 @@
|
|||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
|
# vim: autoindent shiftwidth=4 expandtab textwidth=80 tabstop=4 softtabstop=4
|
||||||
|
|
||||||
# Form implementation generated from reading ui file 'editversedialog.ui'
|
###############################################################################
|
||||||
#
|
# OpenLP - Open Source Lyrics Projection #
|
||||||
# Created: Wed Dec 2 08:14:47 2009
|
# --------------------------------------------------------------------------- #
|
||||||
# by: PyQt4 UI code generator 4.6.2
|
# Copyright (c) 2008-2010 Raoul Snyman #
|
||||||
#
|
# Portions copyright (c) 2008-2010 Tim Bentley, Jonathan Corwin, Michael #
|
||||||
# WARNING! All changes made in this file will be lost!
|
# Gorven, Scott Guerrieri, Maikel Stuivenberg, Martin Thompson, Jon Tibble, #
|
||||||
|
# Carsten Tinggaard #
|
||||||
|
# --------------------------------------------------------------------------- #
|
||||||
|
# This program is free software; you can redistribute it and/or modify it #
|
||||||
|
# under the terms of the GNU General Public License as published by the Free #
|
||||||
|
# Software Foundation; version 2 of the License. #
|
||||||
|
# #
|
||||||
|
# This program is distributed in the hope that it will be useful, but WITHOUT #
|
||||||
|
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or #
|
||||||
|
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for #
|
||||||
|
# more details. #
|
||||||
|
# #
|
||||||
|
# You should have received a copy of the GNU General Public License along #
|
||||||
|
# with this program; if not, write to the Free Software Foundation, Inc., 59 #
|
||||||
|
# Temple Place, Suite 330, Boston, MA 02111-1307 USA #
|
||||||
|
###############################################################################
|
||||||
|
|
||||||
from PyQt4 import QtCore, QtGui
|
from PyQt4 import QtCore, QtGui
|
||||||
|
|
||||||
class Ui_EditVerseDialog(object):
|
class Ui_EditVerseDialog(object):
|
||||||
def setupUi(self, EditVerseDialog):
|
def setupUi(self, EditVerseDialog):
|
||||||
EditVerseDialog.setObjectName("EditVerseDialog")
|
EditVerseDialog.setObjectName(u'EditVerseDialog')
|
||||||
EditVerseDialog.resize(500, 521)
|
EditVerseDialog.resize(500, 521)
|
||||||
EditVerseDialog.setModal(True)
|
EditVerseDialog.setModal(True)
|
||||||
self.layoutWidget = QtGui.QWidget(EditVerseDialog)
|
self.layoutWidget = QtGui.QWidget(EditVerseDialog)
|
||||||
self.layoutWidget.setGeometry(QtCore.QRect(11, 1, 471, 491))
|
self.layoutWidget.setGeometry(QtCore.QRect(11, 1, 471, 491))
|
||||||
self.layoutWidget.setObjectName("layoutWidget")
|
self.layoutWidget.setObjectName(u'layoutWidget')
|
||||||
self.verticalLayout_3 = QtGui.QVBoxLayout(self.layoutWidget)
|
self.verticalLayout_3 = QtGui.QVBoxLayout(self.layoutWidget)
|
||||||
self.verticalLayout_3.setObjectName("verticalLayout_3")
|
self.verticalLayout_3.setObjectName(u'verticalLayout_3')
|
||||||
self.horizontalLayout = QtGui.QHBoxLayout()
|
self.horizontalLayout = QtGui.QHBoxLayout()
|
||||||
self.horizontalLayout.setObjectName("horizontalLayout")
|
self.horizontalLayout.setObjectName(u'horizontalLayout')
|
||||||
self.verticalLayout = QtGui.QVBoxLayout()
|
self.verticalLayout = QtGui.QVBoxLayout()
|
||||||
self.verticalLayout.setObjectName("verticalLayout")
|
self.verticalLayout.setObjectName(u'verticalLayout')
|
||||||
self.VerseTypeLabel = QtGui.QLabel(self.layoutWidget)
|
self.VerseTypeLabel = QtGui.QLabel(self.layoutWidget)
|
||||||
self.VerseTypeLabel.setTextFormat(QtCore.Qt.PlainText)
|
self.VerseTypeLabel.setTextFormat(QtCore.Qt.PlainText)
|
||||||
self.VerseTypeLabel.setAlignment(QtCore.Qt.AlignCenter)
|
self.VerseTypeLabel.setAlignment(QtCore.Qt.AlignCenter)
|
||||||
self.VerseTypeLabel.setObjectName("VerseTypeLabel")
|
self.VerseTypeLabel.setObjectName(u'VerseTypeLabel')
|
||||||
self.verticalLayout.addWidget(self.VerseTypeLabel)
|
self.verticalLayout.addWidget(self.VerseTypeLabel)
|
||||||
self.VerseListComboBox = QtGui.QComboBox(self.layoutWidget)
|
self.VerseListComboBox = QtGui.QComboBox(self.layoutWidget)
|
||||||
self.VerseListComboBox.setObjectName("VerseListComboBox")
|
self.VerseListComboBox.setObjectName(u'VerseListComboBox')
|
||||||
self.VerseListComboBox.addItem("")
|
self.VerseListComboBox.addItem(u'')
|
||||||
self.VerseListComboBox.addItem("")
|
self.VerseListComboBox.addItem(u'')
|
||||||
self.VerseListComboBox.addItem("")
|
self.VerseListComboBox.addItem(u'')
|
||||||
self.VerseListComboBox.addItem("")
|
self.VerseListComboBox.addItem(u'')
|
||||||
self.VerseListComboBox.addItem("")
|
self.VerseListComboBox.addItem(u'')
|
||||||
self.VerseListComboBox.addItem("")
|
self.VerseListComboBox.addItem(u'')
|
||||||
self.VerseListComboBox.addItem("")
|
self.VerseListComboBox.addItem(u'')
|
||||||
self.verticalLayout.addWidget(self.VerseListComboBox)
|
self.verticalLayout.addWidget(self.VerseListComboBox)
|
||||||
self.horizontalLayout.addLayout(self.verticalLayout)
|
self.horizontalLayout.addLayout(self.verticalLayout)
|
||||||
self.verticalLayout_2 = QtGui.QVBoxLayout()
|
self.verticalLayout_2 = QtGui.QVBoxLayout()
|
||||||
self.verticalLayout_2.setObjectName("verticalLayout_2")
|
self.verticalLayout_2.setObjectName(u'verticalLayout_2')
|
||||||
self.VerseNumberLabel = QtGui.QLabel(self.layoutWidget)
|
self.VerseNumberLabel = QtGui.QLabel(self.layoutWidget)
|
||||||
self.VerseNumberLabel.setAlignment(QtCore.Qt.AlignCenter)
|
self.VerseNumberLabel.setAlignment(QtCore.Qt.AlignCenter)
|
||||||
self.VerseNumberLabel.setObjectName("VerseNumberLabel")
|
self.VerseNumberLabel.setObjectName(u'VerseNumberLabel')
|
||||||
self.verticalLayout_2.addWidget(self.VerseNumberLabel)
|
self.verticalLayout_2.addWidget(self.VerseNumberLabel)
|
||||||
self.SubVerseListComboBox = QtGui.QComboBox(self.layoutWidget)
|
self.SubVerseListComboBox = QtGui.QComboBox(self.layoutWidget)
|
||||||
self.SubVerseListComboBox.setObjectName("SubVerseListComboBox")
|
self.SubVerseListComboBox.setObjectName(u'SubVerseListComboBox')
|
||||||
self.verticalLayout_2.addWidget(self.SubVerseListComboBox)
|
self.verticalLayout_2.addWidget(self.SubVerseListComboBox)
|
||||||
self.horizontalLayout.addLayout(self.verticalLayout_2)
|
self.horizontalLayout.addLayout(self.verticalLayout_2)
|
||||||
self.verticalLayout_3.addLayout(self.horizontalLayout)
|
self.verticalLayout_3.addLayout(self.horizontalLayout)
|
||||||
self.VerseTextEdit = QtGui.QTextEdit(self.layoutWidget)
|
self.VerseTextEdit = QtGui.QTextEdit(self.layoutWidget)
|
||||||
self.VerseTextEdit.setAcceptRichText(False)
|
self.VerseTextEdit.setAcceptRichText(False)
|
||||||
self.VerseTextEdit.setObjectName("VerseTextEdit")
|
self.VerseTextEdit.setObjectName(u'VerseTextEdit')
|
||||||
self.verticalLayout_3.addWidget(self.VerseTextEdit)
|
self.verticalLayout_3.addWidget(self.VerseTextEdit)
|
||||||
self.horizontalLayout_2 = QtGui.QHBoxLayout()
|
self.horizontalLayout_2 = QtGui.QHBoxLayout()
|
||||||
self.horizontalLayout_2.setObjectName("horizontalLayout_2")
|
self.horizontalLayout_2.setObjectName(u'horizontalLayout_2')
|
||||||
self.addBridge = QtGui.QPushButton(self.layoutWidget)
|
self.addBridge = QtGui.QPushButton(self.layoutWidget)
|
||||||
self.addBridge.setObjectName("addBridge")
|
self.addBridge.setObjectName(u'addBridge')
|
||||||
self.horizontalLayout_2.addWidget(self.addBridge)
|
self.horizontalLayout_2.addWidget(self.addBridge)
|
||||||
self.addVerse = QtGui.QPushButton(self.layoutWidget)
|
self.addVerse = QtGui.QPushButton(self.layoutWidget)
|
||||||
self.addVerse.setObjectName("addVerse")
|
self.addVerse.setObjectName(u'addVerse')
|
||||||
self.horizontalLayout_2.addWidget(self.addVerse)
|
self.horizontalLayout_2.addWidget(self.addVerse)
|
||||||
self.addChorus = QtGui.QPushButton(self.layoutWidget)
|
self.addChorus = QtGui.QPushButton(self.layoutWidget)
|
||||||
self.addChorus.setObjectName("addChorus")
|
self.addChorus.setObjectName(u'addChorus')
|
||||||
self.horizontalLayout_2.addWidget(self.addChorus)
|
self.horizontalLayout_2.addWidget(self.addChorus)
|
||||||
self.verticalLayout_3.addLayout(self.horizontalLayout_2)
|
self.verticalLayout_3.addLayout(self.horizontalLayout_2)
|
||||||
self.horizontalLayout_3 = QtGui.QHBoxLayout()
|
self.horizontalLayout_3 = QtGui.QHBoxLayout()
|
||||||
self.horizontalLayout_3.setObjectName("horizontalLayout_3")
|
self.horizontalLayout_3.setObjectName(u'horizontalLayout_3')
|
||||||
self.addPreChorus = QtGui.QPushButton(self.layoutWidget)
|
self.addPreChorus = QtGui.QPushButton(self.layoutWidget)
|
||||||
self.addPreChorus.setObjectName("addPreChorus")
|
self.addPreChorus.setObjectName(u'addPreChorus')
|
||||||
self.horizontalLayout_3.addWidget(self.addPreChorus)
|
self.horizontalLayout_3.addWidget(self.addPreChorus)
|
||||||
self.addIntro = QtGui.QPushButton(self.layoutWidget)
|
self.addIntro = QtGui.QPushButton(self.layoutWidget)
|
||||||
self.addIntro.setObjectName("addIntro")
|
self.addIntro.setObjectName(u'addIntro')
|
||||||
self.horizontalLayout_3.addWidget(self.addIntro)
|
self.horizontalLayout_3.addWidget(self.addIntro)
|
||||||
self.addOther = QtGui.QPushButton(self.layoutWidget)
|
self.addOther = QtGui.QPushButton(self.layoutWidget)
|
||||||
self.addOther.setObjectName("addOther")
|
self.addOther.setObjectName(u'addOther')
|
||||||
self.horizontalLayout_3.addWidget(self.addOther)
|
self.horizontalLayout_3.addWidget(self.addOther)
|
||||||
self.addEnding = QtGui.QPushButton(self.layoutWidget)
|
self.addEnding = QtGui.QPushButton(self.layoutWidget)
|
||||||
self.addEnding.setObjectName("addEnding")
|
self.addEnding.setObjectName(u'addEnding')
|
||||||
self.horizontalLayout_3.addWidget(self.addEnding)
|
self.horizontalLayout_3.addWidget(self.addEnding)
|
||||||
self.verticalLayout_3.addLayout(self.horizontalLayout_3)
|
self.verticalLayout_3.addLayout(self.horizontalLayout_3)
|
||||||
self.ButtonBox = QtGui.QDialogButtonBox(self.layoutWidget)
|
self.ButtonBox = QtGui.QDialogButtonBox(self.layoutWidget)
|
||||||
self.ButtonBox.setOrientation(QtCore.Qt.Horizontal)
|
self.ButtonBox.setOrientation(QtCore.Qt.Horizontal)
|
||||||
self.ButtonBox.setStandardButtons(QtGui.QDialogButtonBox.Cancel|QtGui.QDialogButtonBox.Save)
|
self.ButtonBox.setStandardButtons(QtGui.QDialogButtonBox.Cancel|QtGui.QDialogButtonBox.Save)
|
||||||
self.ButtonBox.setObjectName("ButtonBox")
|
self.ButtonBox.setObjectName(u'ButtonBox')
|
||||||
self.verticalLayout_3.addWidget(self.ButtonBox)
|
self.verticalLayout_3.addWidget(self.ButtonBox)
|
||||||
|
|
||||||
self.retranslateUi(EditVerseDialog)
|
self.retranslateUi(EditVerseDialog)
|
||||||
QtCore.QObject.connect(self.ButtonBox, QtCore.SIGNAL("accepted()"), EditVerseDialog.accept)
|
QtCore.QObject.connect(self.ButtonBox, QtCore.SIGNAL(u'accepted()'), EditVerseDialog.accept)
|
||||||
QtCore.QObject.connect(self.ButtonBox, QtCore.SIGNAL("rejected()"), EditVerseDialog.reject)
|
QtCore.QObject.connect(self.ButtonBox, QtCore.SIGNAL(u'rejected()'), EditVerseDialog.reject)
|
||||||
QtCore.QMetaObject.connectSlotsByName(EditVerseDialog)
|
QtCore.QMetaObject.connectSlotsByName(EditVerseDialog)
|
||||||
|
|
||||||
def retranslateUi(self, EditVerseDialog):
|
def retranslateUi(self, EditVerseDialog):
|
||||||
EditVerseDialog.setWindowTitle(QtGui.QApplication.translate("EditVerseDialog", "Edit Verse", None, QtGui.QApplication.UnicodeUTF8))
|
EditVerseDialog.setWindowTitle(self.trUtf8('Edit Verse'))
|
||||||
self.VerseTypeLabel.setText(QtGui.QApplication.translate("EditVerseDialog", "Verse Type", None, QtGui.QApplication.UnicodeUTF8))
|
self.VerseTypeLabel.setText(self.trUtf8('Verse Type'))
|
||||||
self.VerseListComboBox.setItemText(0, QtGui.QApplication.translate("EditVerseDialog", "Intro", None, QtGui.QApplication.UnicodeUTF8))
|
self.VerseListComboBox.setItemText(0, self.trUtf8('Intro'))
|
||||||
self.VerseListComboBox.setItemText(1, QtGui.QApplication.translate("EditVerseDialog", "Verse", None, QtGui.QApplication.UnicodeUTF8))
|
self.VerseListComboBox.setItemText(1, self.trUtf8('Verse'))
|
||||||
self.VerseListComboBox.setItemText(2, QtGui.QApplication.translate("EditVerseDialog", "Pre-Chorus", None, QtGui.QApplication.UnicodeUTF8))
|
self.VerseListComboBox.setItemText(2, self.trUtf8('Pre-Chorus'))
|
||||||
self.VerseListComboBox.setItemText(3, QtGui.QApplication.translate("EditVerseDialog", "Chorus", None, QtGui.QApplication.UnicodeUTF8))
|
self.VerseListComboBox.setItemText(3, self.trUtf8('Chorus'))
|
||||||
self.VerseListComboBox.setItemText(4, QtGui.QApplication.translate("EditVerseDialog", "Bridge", None, QtGui.QApplication.UnicodeUTF8))
|
self.VerseListComboBox.setItemText(4, self.trUtf8('Bridge'))
|
||||||
self.VerseListComboBox.setItemText(5, QtGui.QApplication.translate("EditVerseDialog", "Ending", None, QtGui.QApplication.UnicodeUTF8))
|
self.VerseListComboBox.setItemText(5, self.trUtf8('Ending'))
|
||||||
self.VerseListComboBox.setItemText(6, QtGui.QApplication.translate("EditVerseDialog", "Other", None, QtGui.QApplication.UnicodeUTF8))
|
self.VerseListComboBox.setItemText(6, self.trUtf8('Other'))
|
||||||
self.VerseNumberLabel.setText(QtGui.QApplication.translate("EditVerseDialog", "Number", None, QtGui.QApplication.UnicodeUTF8))
|
self.VerseNumberLabel.setText(self.trUtf8('Number'))
|
||||||
self.addBridge.setText(QtGui.QApplication.translate("EditVerseDialog", "Bridge", None, QtGui.QApplication.UnicodeUTF8))
|
self.addBridge.setText(self.trUtf8('Bridge'))
|
||||||
self.addVerse.setText(QtGui.QApplication.translate("EditVerseDialog", "Verse", None, QtGui.QApplication.UnicodeUTF8))
|
self.addVerse.setText(self.trUtf8('Verse'))
|
||||||
self.addChorus.setText(QtGui.QApplication.translate("EditVerseDialog", "Chorus", None, QtGui.QApplication.UnicodeUTF8))
|
self.addChorus.setText(self.trUtf8('Chorus'))
|
||||||
self.addPreChorus.setText(QtGui.QApplication.translate("EditVerseDialog", "Pre-Chorus", None, QtGui.QApplication.UnicodeUTF8))
|
self.addPreChorus.setText(self.trUtf8('Pre-Chorus'))
|
||||||
self.addIntro.setText(QtGui.QApplication.translate("EditVerseDialog", "Intro", None, QtGui.QApplication.UnicodeUTF8))
|
self.addIntro.setText(self.trUtf8('Intro'))
|
||||||
self.addOther.setText(QtGui.QApplication.translate("EditVerseDialog", "Other", None, QtGui.QApplication.UnicodeUTF8))
|
self.addOther.setText(self.trUtf8('Other'))
|
||||||
self.addEnding.setText(QtGui.QApplication.translate("EditVerseDialog", "Ending", None, QtGui.QApplication.UnicodeUTF8))
|
self.addEnding.setText(self.trUtf8('Ending'))
|
||||||
|
|
||||||
|
@ -27,7 +27,7 @@ import logging
|
|||||||
|
|
||||||
from PyQt4 import QtCore, QtGui
|
from PyQt4 import QtCore, QtGui
|
||||||
|
|
||||||
from openlp.core.lib import Plugin, build_icon
|
from openlp.core.lib import Plugin, build_icon, PluginStatus
|
||||||
from openlp.plugins.songs.lib import SongManager, SongMediaItem, SongsTab
|
from openlp.plugins.songs.lib import SongManager, SongMediaItem, SongsTab
|
||||||
from openlp.plugins.songs.forms import OpenLPImportForm, OpenSongExportForm, \
|
from openlp.plugins.songs.forms import OpenLPImportForm, OpenSongExportForm, \
|
||||||
OpenSongImportForm, OpenLPExportForm
|
OpenSongImportForm, OpenLPExportForm
|
||||||
@ -49,7 +49,7 @@ class SongsPlugin(Plugin):
|
|||||||
"""
|
"""
|
||||||
Create and set up the Songs plugin.
|
Create and set up the Songs plugin.
|
||||||
"""
|
"""
|
||||||
Plugin.__init__(self, u'Songs', u'1.9.0', plugin_helpers)
|
Plugin.__init__(self, u'Songs', u'1.9.1', plugin_helpers)
|
||||||
self.weight = -10
|
self.weight = -10
|
||||||
self.songmanager = SongManager(self.config)
|
self.songmanager = SongManager(self.config)
|
||||||
self.openlp_import_form = OpenLPImportForm()
|
self.openlp_import_form = OpenLPImportForm()
|
||||||
@ -57,6 +57,7 @@ class SongsPlugin(Plugin):
|
|||||||
self.openlp_export_form = OpenLPExportForm()
|
self.openlp_export_form = OpenLPExportForm()
|
||||||
self.opensong_export_form = OpenSongExportForm()
|
self.opensong_export_form = OpenSongExportForm()
|
||||||
self.icon = build_icon(u':/media/media_song.png')
|
self.icon = build_icon(u':/media/media_song.png')
|
||||||
|
self.status = PluginStatus.Active
|
||||||
|
|
||||||
def get_settings_tab(self):
|
def get_settings_tab(self):
|
||||||
return SongsTab(self.name)
|
return SongsTab(self.name)
|
||||||
|
@ -39,7 +39,7 @@ class SongUsagePlugin(Plugin):
|
|||||||
log.info(u'SongUsage Plugin loaded')
|
log.info(u'SongUsage Plugin loaded')
|
||||||
|
|
||||||
def __init__(self, plugin_helpers):
|
def __init__(self, plugin_helpers):
|
||||||
Plugin.__init__(self, u'SongUsage', u'1.9.0', plugin_helpers)
|
Plugin.__init__(self, u'SongUsage', u'1.9.1', plugin_helpers)
|
||||||
self.weight = -4
|
self.weight = -4
|
||||||
self.icon = build_icon(u':/media/media_image.png')
|
self.icon = build_icon(u':/media/media_image.png')
|
||||||
self.songusagemanager = None
|
self.songusagemanager = None
|
||||||
|
@ -1,77 +1,73 @@
|
|||||||
[audit]
|
|
||||||
first service = 2
|
|
||||||
db type = sqlite
|
|
||||||
audit active = False
|
|
||||||
second service = 2
|
|
||||||
audit_status = 0
|
|
||||||
data path = audit
|
|
||||||
|
|
||||||
[bibles]
|
[bibles]
|
||||||
display new chapter = False
|
display new chapter = False
|
||||||
display brackets = 0
|
display brackets = 0
|
||||||
verse layout style = 0
|
dual bibles = False
|
||||||
bible theme = 0
|
db type = sqlite
|
||||||
search as type = True
|
bible theme =
|
||||||
bibles_status = 0
|
verse layout style = 1
|
||||||
|
status = 1
|
||||||
data path = bibles
|
data path = bibles
|
||||||
|
|
||||||
[media]
|
[media]
|
||||||
use mode layout = False
|
status = 1
|
||||||
media_status = 1
|
|
||||||
|
|
||||||
[image]
|
|
||||||
loop delay = 5
|
|
||||||
|
|
||||||
[alerts]
|
[alerts]
|
||||||
font color = #ffffff
|
font color = #ffffff
|
||||||
|
background color = #660000
|
||||||
font face = Sans Serif
|
font face = Sans Serif
|
||||||
timeout = 5
|
timeout = 5
|
||||||
background color = #660000
|
|
||||||
|
|
||||||
[user interface]
|
[remotes]
|
||||||
display previewpanel = True
|
remote port = 4316
|
||||||
display thememanager = True
|
|
||||||
display servicemanager = True
|
|
||||||
display mediamanager = True
|
|
||||||
|
|
||||||
[presentations]
|
[presentations]
|
||||||
data path = presentations
|
status = 1
|
||||||
impress = 0
|
impress = 0
|
||||||
|
data path = presentations
|
||||||
|
powerpoint = 0
|
||||||
|
powerpoint viewer = 0
|
||||||
|
|
||||||
[custom]
|
[custom]
|
||||||
|
status = 1
|
||||||
|
display footer = True
|
||||||
data path = custom
|
data path = custom
|
||||||
db type = sqlite
|
db type = sqlite
|
||||||
custom_status = 0
|
|
||||||
|
|
||||||
[themes]
|
[themes]
|
||||||
|
global theme =
|
||||||
data path = themes
|
data path = themes
|
||||||
theme global theme =
|
theme level = 1
|
||||||
theme global style = Global
|
|
||||||
|
[images]
|
||||||
|
status = 1
|
||||||
|
data path = images
|
||||||
|
loop delay = 5
|
||||||
|
|
||||||
|
[user interface]
|
||||||
|
theme manager = True
|
||||||
|
media manager = True
|
||||||
|
preview panel = True
|
||||||
|
service manager = True
|
||||||
|
|
||||||
[servicemanager]
|
[servicemanager]
|
||||||
data path = servicemanager
|
data path = servicemanager
|
||||||
theme service theme =
|
|
||||||
|
|
||||||
[remotes]
|
|
||||||
remotes_status = 1
|
|
||||||
remote port = 4316
|
|
||||||
|
|
||||||
[images]
|
|
||||||
images_status = 1
|
|
||||||
|
|
||||||
[general]
|
[general]
|
||||||
monitor = 0
|
monitor = 0
|
||||||
|
run environment = dev
|
||||||
|
ccli number =
|
||||||
|
blank warning = False
|
||||||
show splash = True
|
show splash = True
|
||||||
application version test = 2009-10-14
|
last version test = 2010-02-05
|
||||||
user name =
|
songselect username =
|
||||||
application version = 1.9.0-600
|
save prompt = False
|
||||||
warning = False
|
songselect password =
|
||||||
auto open = False
|
auto open = False
|
||||||
password =
|
|
||||||
ccl number = XXX
|
|
||||||
|
|
||||||
[songs]
|
[songs]
|
||||||
songs_status = 0
|
status = 1
|
||||||
|
search as type = False
|
||||||
|
display songbar = True
|
||||||
data path = songs
|
data path = songs
|
||||||
db type = sqlite
|
db type = sqlite
|
||||||
|
|
||||||
|
@ -1 +1 @@
|
|||||||
1.9.0-700
|
1.9.0-701
|
||||||
|
Loading…
Reference in New Issue
Block a user