modified:

openlp/core/lib/mediamanageritem.py
  openlp/core/ui/slidecontroller.py
This commit is contained in:
Stevan Pettit 2011-05-20 01:01:49 -04:00
parent af5fdcf73d
commit c4b0862979
2 changed files with 13 additions and 2 deletions

View File

@ -113,7 +113,6 @@ class MediaManagerItem(QtGui.QWidget):
self.retranslateUi() self.retranslateUi()
QtCore.QObject.connect(Receiver.get_receiver(), QtCore.QObject.connect(Receiver.get_receiver(),
QtCore.SIGNAL(u'%s_service_load' % self.parent.name.lower()), QtCore.SIGNAL(u'%s_service_load' % self.parent.name.lower()),
self.serviceLoad)
def requiredIcons(self): def requiredIcons(self):
""" """
@ -499,10 +498,11 @@ class MediaManagerItem(QtGui.QWidget):
""" """
Add a selected item to the current service Add a selected item to the current service
""" """
print "OnAddClick"
if not self.listView.selectedIndexes() and not self.remoteTriggered: if not self.listView.selectedIndexes() and not self.remoteTriggered:
QtGui.QMessageBox.information(self, UiStrings().NISp, QtGui.QMessageBox.information(self, UiStrings().NISp,
translate('OpenLP.MediaManagerItem', translate('OpenLP.MediaManagerItem',
'You must select one or more items.')) 'You must select one or more items to add.'))
else: else:
# Is it posssible to process multiple list items to generate # Is it posssible to process multiple list items to generate
# multiple service items? # multiple service items?

View File

@ -210,6 +210,11 @@ class SlideController(QtGui.QWidget):
u'Go Live', u':/general/general_live.png', u'Go Live', u':/general/general_live.png',
translate('OpenLP.SlideController', 'Move to live'), translate('OpenLP.SlideController', 'Move to live'),
self.onGoLive) self.onGoLive)
self.toolbar.addToolbarButton(
# Does not need translating - control string.
u'Add to Service', u':/general/general_add.png',
translate('OpenLP.SlideController', 'Add to Service'),
self.onPreviewAddToService)
self.toolbar.addToolbarSeparator(u'Close Separator') self.toolbar.addToolbarSeparator(u'Close Separator')
self.toolbar.addToolbarButton( self.toolbar.addToolbarButton(
# Does not need translating - control string. # Does not need translating - control string.
@ -1044,6 +1049,12 @@ class SlideController(QtGui.QWidget):
Receiver.send_message(u'%s_edit' % self.serviceItem.name.lower(), Receiver.send_message(u'%s_edit' % self.serviceItem.name.lower(),
u'P:%s' % self.serviceItem.edit_id) u'P:%s' % self.serviceItem.edit_id)
def onPreviewAddToService(self):
"""
From the preview display request the Item to be added to service
"""
Receiver.send_message(u'%s_add_service_item' % self.serviceItem.name)
def onGoLiveClick(self): def onGoLiveClick(self):
""" """
triggered by clicking the Preview slide items triggered by clicking the Preview slide items