forked from openlp/openlp
returned old code
This commit is contained in:
parent
eca016c21d
commit
ce807f57b6
@ -1403,7 +1403,7 @@ class ServiceManager(QtGui.QWidget, ServiceManagerDialog):
|
|||||||
Opens a dialog to rename the service item.
|
Opens a dialog to rename the service item.
|
||||||
"""
|
"""
|
||||||
item = self.find_service_item()[0]
|
item = self.find_service_item()[0]
|
||||||
if not service_item[u'service_item'].is_capable(ItemCapabilities.CanEditTitle):
|
if not self.service_items[item][u'service_item'].is_capable(ItemCapabilities.CanEditTitle):
|
||||||
return
|
return
|
||||||
title = self.service_items[item][u'service_item'].title
|
title = self.service_items[item][u'service_item'].title
|
||||||
title, ok = QtGui.QInputDialog.getText(self, self.tr(translate('OpenLP.ServiceManager', 'Input title')),
|
title, ok = QtGui.QInputDialog.getText(self, self.tr(translate('OpenLP.ServiceManager', 'Input title')),
|
||||||
|
@ -181,9 +181,9 @@ class MediaMediaItem(MediaManagerItem):
|
|||||||
translate('MediaPlugin.MediaItem', 'Missing Media File'),
|
translate('MediaPlugin.MediaItem', 'Missing Media File'),
|
||||||
translate('MediaPlugin.MediaItem', 'The file %s no longer exists.') % filename)
|
translate('MediaPlugin.MediaItem', 'The file %s no longer exists.') % filename)
|
||||||
return False
|
return False
|
||||||
service_item.shortname = self.displayTypeComboBox.currentText()
|
service_item.title = self.displayTypeComboBox.currentText()
|
||||||
|
service_item.shortname = service_item.title
|
||||||
(path, name) = os.path.split(filename)
|
(path, name) = os.path.split(filename)
|
||||||
service_item.title = name
|
|
||||||
service_item.add_from_command(path, name, CLAPPERBOARD)
|
service_item.add_from_command(path, name, CLAPPERBOARD)
|
||||||
# Only get start and end times if going to a service
|
# Only get start and end times if going to a service
|
||||||
if context == ServiceItemContext.Service:
|
if context == ServiceItemContext.Service:
|
||||||
@ -192,7 +192,7 @@ class MediaMediaItem(MediaManagerItem):
|
|||||||
return False
|
return False
|
||||||
service_item.add_capability(ItemCapabilities.CanAutoStartForLive)
|
service_item.add_capability(ItemCapabilities.CanAutoStartForLive)
|
||||||
service_item.add_capability(ItemCapabilities.RequiresMedia)
|
service_item.add_capability(ItemCapabilities.RequiresMedia)
|
||||||
service_item.add_capability(ItemCapabilities.CanEditTitle)
|
service_item.add_capability(ItemCapabilities.HasDetailedTitleDisplay)
|
||||||
if Settings().value(self.settings_section + u'/media auto start') == QtCore.Qt.Checked:
|
if Settings().value(self.settings_section + u'/media auto start') == QtCore.Qt.Checked:
|
||||||
service_item.will_auto_start = True
|
service_item.will_auto_start = True
|
||||||
# force a non-existent theme
|
# force a non-existent theme
|
||||||
|
@ -244,9 +244,10 @@ class PresentationMediaItem(MediaManagerItem):
|
|||||||
items = self.list_view.selectedItems()
|
items = self.list_view.selectedItems()
|
||||||
if len(items) > 1:
|
if len(items) > 1:
|
||||||
return False
|
return False
|
||||||
|
service_item.title = self.displayTypeComboBox.currentText()
|
||||||
service_item.shortname = self.displayTypeComboBox.currentText()
|
service_item.shortname = self.displayTypeComboBox.currentText()
|
||||||
service_item.add_capability(ItemCapabilities.ProvidesOwnDisplay)
|
service_item.add_capability(ItemCapabilities.ProvidesOwnDisplay)
|
||||||
service_item.add_capability(ItemCapabilities.CanEditTitle)
|
service_item.add_capability(ItemCapabilities.HasDetailedTitleDisplay)
|
||||||
shortname = service_item.shortname
|
shortname = service_item.shortname
|
||||||
if not shortname:
|
if not shortname:
|
||||||
return False
|
return False
|
||||||
@ -259,7 +260,6 @@ class PresentationMediaItem(MediaManagerItem):
|
|||||||
return False
|
return False
|
||||||
controller = self.controllers[service_item.shortname]
|
controller = self.controllers[service_item.shortname]
|
||||||
(path, name) = os.path.split(filename)
|
(path, name) = os.path.split(filename)
|
||||||
service_item.title = name
|
|
||||||
doc = controller.add_document(filename)
|
doc = controller.add_document(filename)
|
||||||
if doc.get_thumbnail_path(1, True) is None:
|
if doc.get_thumbnail_path(1, True) is None:
|
||||||
doc.load_presentation()
|
doc.load_presentation()
|
||||||
|
Loading…
Reference in New Issue
Block a user