forked from openlp/openlp
Cleanup unneeded trailing backslashes
This commit is contained in:
parent
a34957297c
commit
1005a3c1b1
@ -208,40 +208,40 @@ class MediaManagerItem(QtGui.QWidget):
|
|||||||
## Import Button ##
|
## Import Button ##
|
||||||
if self.hasImportIcon:
|
if self.hasImportIcon:
|
||||||
self.addToolbarButton(
|
self.addToolbarButton(
|
||||||
unicode(translate('MediaManagerItem', 'Import %s')) % \
|
unicode(translate('MediaManagerItem', 'Import %s')) %
|
||||||
self.PluginNameShort,
|
self.PluginNameShort,
|
||||||
unicode(translate('MediaManagerItem', 'Import a %s')) % \
|
unicode(translate('MediaManagerItem', 'Import a %s')) %
|
||||||
self.PluginNameVisible,
|
self.PluginNameVisible,
|
||||||
u':/general/general_import.png', self.onImportClick)
|
u':/general/general_import.png', self.onImportClick)
|
||||||
## File Button ##
|
## File Button ##
|
||||||
if self.hasFileIcon:
|
if self.hasFileIcon:
|
||||||
self.addToolbarButton(
|
self.addToolbarButton(
|
||||||
unicode(translate('MediaManagerItem', 'Load %s')) % \
|
unicode(translate('MediaManagerItem', 'Load %s')) %
|
||||||
self.PluginNameShort,
|
self.PluginNameShort,
|
||||||
unicode(translate('MediaManagerItem', 'Load a new %s')) % \
|
unicode(translate('MediaManagerItem', 'Load a new %s')) %
|
||||||
self.PluginNameVisible,
|
self.PluginNameVisible,
|
||||||
u':/general/general_open.png', self.onFileClick)
|
u':/general/general_open.png', self.onFileClick)
|
||||||
## New Button ##
|
## New Button ##
|
||||||
if self.hasNewIcon:
|
if self.hasNewIcon:
|
||||||
self.addToolbarButton(
|
self.addToolbarButton(
|
||||||
unicode(translate('MediaManagerItem', 'New %s')) % \
|
unicode(translate('MediaManagerItem', 'New %s')) %
|
||||||
self.PluginNameShort,
|
self.PluginNameShort,
|
||||||
unicode(translate('MediaManagerItem', 'Add a new %s')) % \
|
unicode(translate('MediaManagerItem', 'Add a new %s')) %
|
||||||
self.PluginNameVisible,
|
self.PluginNameVisible,
|
||||||
u':/general/general_new.png', self.onNewClick)
|
u':/general/general_new.png', self.onNewClick)
|
||||||
## Edit Button ##
|
## Edit Button ##
|
||||||
if self.hasEditIcon:
|
if self.hasEditIcon:
|
||||||
self.addToolbarButton(
|
self.addToolbarButton(
|
||||||
unicode(translate('MediaManagerItem', 'Edit %s')) % \
|
unicode(translate('MediaManagerItem', 'Edit %s')) %
|
||||||
self.PluginNameShort,
|
self.PluginNameShort,
|
||||||
unicode(translate(
|
unicode(translate(
|
||||||
'MediaManagerItem', 'Edit the selected %s')) % \
|
'MediaManagerItem', 'Edit the selected %s')) %
|
||||||
self.PluginNameVisible,
|
self.PluginNameVisible,
|
||||||
u':/general/general_edit.png', self.onEditClick)
|
u':/general/general_edit.png', self.onEditClick)
|
||||||
## Delete Button ##
|
## Delete Button ##
|
||||||
if self.hasDeleteIcon:
|
if self.hasDeleteIcon:
|
||||||
self.addToolbarButton(
|
self.addToolbarButton(
|
||||||
unicode(translate('MediaManagerItem', 'Delete %s')) % \
|
unicode(translate('MediaManagerItem', 'Delete %s')) %
|
||||||
self.PluginNameShort,
|
self.PluginNameShort,
|
||||||
translate('MediaManagerItem', 'Delete the selected item'),
|
translate('MediaManagerItem', 'Delete the selected item'),
|
||||||
u':/general/general_delete.png', self.onDeleteClick)
|
u':/general/general_delete.png', self.onDeleteClick)
|
||||||
@ -249,7 +249,7 @@ class MediaManagerItem(QtGui.QWidget):
|
|||||||
self.addToolbarSeparator()
|
self.addToolbarSeparator()
|
||||||
## Preview ##
|
## Preview ##
|
||||||
self.addToolbarButton(
|
self.addToolbarButton(
|
||||||
unicode(translate('MediaManagerItem', 'Preview %s')) % \
|
unicode(translate('MediaManagerItem', 'Preview %s')) %
|
||||||
self.PluginNameShort,
|
self.PluginNameShort,
|
||||||
translate('MediaManagerItem', 'Preview the selected item'),
|
translate('MediaManagerItem', 'Preview the selected item'),
|
||||||
u':/general/general_preview.png', self.onPreviewClick)
|
u':/general/general_preview.png', self.onPreviewClick)
|
||||||
@ -260,7 +260,7 @@ class MediaManagerItem(QtGui.QWidget):
|
|||||||
u':/general/general_live.png', self.onLiveClick)
|
u':/general/general_live.png', self.onLiveClick)
|
||||||
## Add to service Button ##
|
## Add to service Button ##
|
||||||
self.addToolbarButton(
|
self.addToolbarButton(
|
||||||
unicode(translate('MediaManagerItem', 'Add %s to Service')) % \
|
unicode(translate('MediaManagerItem', 'Add %s to Service')) %
|
||||||
self.PluginNameShort,
|
self.PluginNameShort,
|
||||||
translate('MediaManagerItem',
|
translate('MediaManagerItem',
|
||||||
'Add the selected item(s) to the service'),
|
'Add the selected item(s) to the service'),
|
||||||
@ -285,7 +285,7 @@ class MediaManagerItem(QtGui.QWidget):
|
|||||||
self.ListView.addAction(
|
self.ListView.addAction(
|
||||||
context_menu_action(
|
context_menu_action(
|
||||||
self.ListView, u':/general/general_edit.png',
|
self.ListView, u':/general/general_edit.png',
|
||||||
unicode(translate('MediaManagerItem', '&Edit %s')) % \
|
unicode(translate('MediaManagerItem', '&Edit %s')) %
|
||||||
self.PluginNameVisible,
|
self.PluginNameVisible,
|
||||||
self.onEditClick))
|
self.onEditClick))
|
||||||
self.ListView.addAction(context_menu_separator(self.ListView))
|
self.ListView.addAction(context_menu_separator(self.ListView))
|
||||||
@ -293,14 +293,14 @@ class MediaManagerItem(QtGui.QWidget):
|
|||||||
self.ListView.addAction(
|
self.ListView.addAction(
|
||||||
context_menu_action(
|
context_menu_action(
|
||||||
self.ListView, u':/general/general_delete.png',
|
self.ListView, u':/general/general_delete.png',
|
||||||
unicode(translate('MediaManagerItem', '&Delete %s')) % \
|
unicode(translate('MediaManagerItem', '&Delete %s')) %
|
||||||
self.PluginNameVisible,
|
self.PluginNameVisible,
|
||||||
self.onDeleteClick))
|
self.onDeleteClick))
|
||||||
self.ListView.addAction(context_menu_separator(self.ListView))
|
self.ListView.addAction(context_menu_separator(self.ListView))
|
||||||
self.ListView.addAction(
|
self.ListView.addAction(
|
||||||
context_menu_action(
|
context_menu_action(
|
||||||
self.ListView, u':/general/general_preview.png',
|
self.ListView, u':/general/general_preview.png',
|
||||||
unicode(translate('MediaManagerItem', '&Preview %s')) % \
|
unicode(translate('MediaManagerItem', '&Preview %s')) %
|
||||||
self.PluginNameVisible,
|
self.PluginNameVisible,
|
||||||
self.onPreviewClick))
|
self.onPreviewClick))
|
||||||
self.ListView.addAction(
|
self.ListView.addAction(
|
||||||
|
@ -677,7 +677,7 @@ class ServiceManager(QtGui.QWidget):
|
|||||||
translate('ServiceManager',
|
translate('ServiceManager',
|
||||||
'File is not a valid service.\n'
|
'File is not a valid service.\n'
|
||||||
'The content encoding is not UTF-8.'))
|
'The content encoding is not UTF-8.'))
|
||||||
log.exception(u'Filename "%s" is not valid UTF-8' % \
|
log.exception(u'Filename "%s" is not valid UTF-8' %
|
||||||
file.decode(u'utf-8', u'replace'))
|
file.decode(u'utf-8', u'replace'))
|
||||||
continue
|
continue
|
||||||
osfile = unicode(QtCore.QDir.toNativeSeparators(ucsfile))
|
osfile = unicode(QtCore.QDir.toNativeSeparators(ucsfile))
|
||||||
|
@ -398,7 +398,7 @@ class ThemeManager(QtGui.QWidget):
|
|||||||
self, translate('ThemeManager', 'Error'),
|
self, translate('ThemeManager', 'Error'),
|
||||||
translate('ThemeManager', 'File is not a valid theme.\n'
|
translate('ThemeManager', 'File is not a valid theme.\n'
|
||||||
'The content encoding is not UTF-8.'))
|
'The content encoding is not UTF-8.'))
|
||||||
log.exception(u'Filename "%s" is not valid UTF-8' % \
|
log.exception(u'Filename "%s" is not valid UTF-8' %
|
||||||
file.decode(u'utf-8', u'replace'))
|
file.decode(u'utf-8', u'replace'))
|
||||||
continue
|
continue
|
||||||
osfile = unicode(QtCore.QDir.toNativeSeparators(ucsfile))
|
osfile = unicode(QtCore.QDir.toNativeSeparators(ucsfile))
|
||||||
|
@ -294,5 +294,5 @@ class AlertsTab(SettingsTab):
|
|||||||
font.setBold(True)
|
font.setBold(True)
|
||||||
font.setPointSize(self.font_size)
|
font.setPointSize(self.font_size)
|
||||||
self.FontPreview.setFont(font)
|
self.FontPreview.setFont(font)
|
||||||
self.FontPreview.setStyleSheet(u'background-color: %s; color: %s' % \
|
self.FontPreview.setStyleSheet(u'background-color: %s; color: %s' %
|
||||||
(self.bg_color, self.font_color))
|
(self.bg_color, self.font_color))
|
||||||
|
@ -71,12 +71,11 @@ class SongUsageDetailForm(QtGui.QDialog, Ui_SongUsageDetailDialog):
|
|||||||
|
|
||||||
def accept(self):
|
def accept(self):
|
||||||
log.debug(u'Detailed report generated')
|
log.debug(u'Detailed report generated')
|
||||||
filename = u'usage_detail_%s_%s.txt' % \
|
filename = u'usage_detail_%s_%s.txt' %
|
||||||
(self.FromDate.selectedDate().toString(u'ddMMyyyy'),
|
(self.FromDate.selectedDate().toString(u'ddMMyyyy'),
|
||||||
self.ToDate.selectedDate().toString(u'ddMMyyyy'))
|
self.ToDate.selectedDate().toString(u'ddMMyyyy'))
|
||||||
usage = self.parent.songusagemanager.get_all_songusage(\
|
usage = self.parent.songusagemanager.get_all_songusage(
|
||||||
self.FromDate.selectedDate(), \
|
self.FromDate.selectedDate(), self.ToDate.selectedDate())
|
||||||
self.ToDate.selectedDate())
|
|
||||||
outname = os.path.join(unicode(self.FileLineEdit.text()), filename)
|
outname = os.path.join(unicode(self.FileLineEdit.text()), filename)
|
||||||
file = None
|
file = None
|
||||||
try:
|
try:
|
||||||
|
@ -53,7 +53,7 @@ class SongUsageManager(object):
|
|||||||
db_type = unicode(
|
db_type = unicode(
|
||||||
settings.value(u'db type', QtCore.QVariant(u'sqlite')).toString())
|
settings.value(u'db type', QtCore.QVariant(u'sqlite')).toString())
|
||||||
if db_type == u'sqlite':
|
if db_type == u'sqlite':
|
||||||
self.db_url = u'sqlite:///%s/songusage.sqlite' % \
|
self.db_url = u'sqlite:///%s/songusage.sqlite' %
|
||||||
AppLocation.get_section_data_path(u'songusage')
|
AppLocation.get_section_data_path(u'songusage')
|
||||||
else:
|
else:
|
||||||
self.db_url = u'%s://%s:%s@%s/%s' % (db_type,
|
self.db_url = u'%s://%s:%s@%s/%s' % (db_type,
|
||||||
|
Loading…
Reference in New Issue
Block a user