diff --git a/openlp/core/lib/ui.py b/openlp/core/lib/ui.py index 9e2bde7d6..4e69ec546 100644 --- a/openlp/core/lib/ui.py +++ b/openlp/core/lib/ui.py @@ -373,7 +373,7 @@ def create_action(parent, name, **kwargs): True in case the action will be considered a separator. ``data`` - Data which is set as QVariant type. + The actions data. ``shortcuts`` A QList (or a list of strings) which are set as shortcuts. diff --git a/openlp/core/ui/servicemanager.py b/openlp/core/ui/servicemanager.py index a3adfa43a..8aff5c174 100644 --- a/openlp/core/ui/servicemanager.py +++ b/openlp/core/ui/servicemanager.py @@ -480,7 +480,6 @@ class ServiceManager(QtGui.QWidget): path) service = [] write_list = [] - print 1 missing_list = [] audio_files = [] total_size = 0 @@ -501,12 +500,12 @@ class ServiceManager(QtGui.QWidget): write_list.append(path_from) if missing_list: Receiver.send_message(u'cursor_normal') - title = unicode(translate('OpenLP.ServiceManager', - 'Service File(s) Missing')) - message = unicode(translate('OpenLP.ServiceManager', + title = translate('OpenLP.ServiceManager', + 'Service File(s) Missing') + message = translate('OpenLP.ServiceManager', 'The following file(s) in the service are missing:\n\t%s\n\n' - 'These files will be removed if you continue to save.') - ) % "\n\t".join(missing_list) + 'These files will be removed if you continue to save.') % \ + "\n\t".join(missing_list) answer = QtGui.QMessageBox.critical(self, title, message, QtGui.QMessageBox.StandardButtons( @@ -591,7 +590,6 @@ class ServiceManager(QtGui.QWidget): self.mainwindow.addRecentFile(path_file_name) self.setModified(False) delete_file(temp_file_name) - print 2 return success def saveFileAs(self): diff --git a/openlp/plugins/media/lib/mediaitem.py b/openlp/plugins/media/lib/mediaitem.py index c1a884d9c..a075c6754 100644 --- a/openlp/plugins/media/lib/mediaitem.py +++ b/openlp/plugins/media/lib/mediaitem.py @@ -305,7 +305,7 @@ class MediaMediaItem(MediaManagerItem): filename = os.path.split(unicode(track))[1] item_name = QtGui.QListWidgetItem(filename) item_name.setIcon(build_icon(ERROR)) - item_name.setData(QtCore.Qt.UserRole, QtCore.QVariant(track)) + item_name.setData(QtCore.Qt.UserRole, track) elif track_info.isFile(): filename = os.path.split(unicode(track))[1] item_name = QtGui.QListWidgetItem(filename) diff --git a/openlp/plugins/presentations/lib/mediaitem.py b/openlp/plugins/presentations/lib/mediaitem.py index 4e0f7821a..afaf59253 100644 --- a/openlp/plugins/presentations/lib/mediaitem.py +++ b/openlp/plugins/presentations/lib/mediaitem.py @@ -184,7 +184,7 @@ class PresentationMediaItem(MediaManagerItem): if not os.path.exists(file): item_name = QtGui.QListWidgetItem(filename) item_name.setIcon(build_icon(ERROR)) - item_name.setData(QtCore.Qt.UserRole, QtCore.QVariant(file)) + item_name.setData(QtCore.Qt.UserRole, file) item_name.setToolTip(file) self.listView.addItem(item_name) else: