Wizards and applications

This commit is contained in:
Jon Tibble 2011-02-12 20:25:40 +00:00
parent 0561fa2525
commit bffa44a1cb
4 changed files with 75 additions and 131 deletions

View File

@ -74,6 +74,7 @@ class UiStrings(object):
NFSp = translate('OpenLP.Ui', 'No Files Selected', 'Plural') NFSp = translate('OpenLP.Ui', 'No Files Selected', 'Plural')
NISs = translate('OpenLP.Ui', 'No Item Selected', 'Singular') NISs = translate('OpenLP.Ui', 'No Item Selected', 'Singular')
NISp = translate('OpenLP.Ui', 'No Items Selected', 'Plural') NISp = translate('OpenLP.Ui', 'No Items Selected', 'Plural')
OLPV1 = translate('OpenLP.Ui', 'openlp.org 1.x')
OLPV2 = translate('OpenLP.Ui', 'OpenLP 2.0') OLPV2 = translate('OpenLP.Ui', 'OpenLP 2.0')
OpenType = unicode(translate('OpenLP.Ui', 'Open %s')) OpenType = unicode(translate('OpenLP.Ui', 'Open %s'))
Preview = translate('OpenLP.Ui', 'Preview') Preview = translate('OpenLP.Ui', 'Preview')

View File

@ -41,6 +41,20 @@ class WizardStrings(object):
""" """
Provide standard strings for wizards to use. Provide standard strings for wizards to use.
""" """
# Applications/Formats we import from or export to. These get used in
# multiple places but do not need translating unless you find evidence of
# the writers translating their own product name.
CCLI = u'CCLI/SongSelect'
CSV = u'CSV'
EW = u'EasyWorship'
ES = u'EasiSlides'
GDP = translate('OpenLP.Ui', 'Generic Document or Presentation')
OL = u'OpenLyrics'
OS = u'OpenSong'
OSIS = u'OSIS'
SB = u'SongBeamer'
SoF = u'Songs of Fellowship'
WoW = u'Words of Worship'
# These strings should need a good reason to be retranslated elsewhere. # These strings should need a good reason to be retranslated elsewhere.
Description = unicode(translate('OpenLP.Ui', 'This wizard will help you ' Description = unicode(translate('OpenLP.Ui', 'This wizard will help you '
'to %s %s from a variety of formats. Click the next button ' 'to %s %s from a variety of formats. Click the next button '
@ -52,9 +66,12 @@ class WizardStrings(object):
ImportSelect = translate('OpenLP.Ui', 'Select Import Source') ImportSelect = translate('OpenLP.Ui', 'Select Import Source')
ImportSelectLong = unicode(translate('OpenLP.Ui', ImportSelectLong = unicode(translate('OpenLP.Ui',
'Select the import format and the location to import from.')) 'Select the import format and the location to import from.'))
OpenTypeFile = unicode(translate('OpenLP.Ui', 'Open %s File'))
Welcome = u'<span style="font-size:14pt; font-weight:600;">%s</span>' % \ Welcome = u'<span style="font-size:14pt; font-weight:600;">%s</span>' % \
translate('OpenLP.Ui', 'Welcome to the %s %s Wizard', translate('OpenLP.Ui', 'Welcome to the %s %s Wizard',
'Variable 1 is the type e.g. Bible and variable 2 is import/export') 'Variable 1 is the type e.g. Bible and variable 2 is import/export')
YouSpecifyFile = unicode(translate('OpenLP.Ui', 'You need to specify at '
'least one %s file to import from.', 'A file type e.g. OpenSong'))
class OpenLPWizard(QtGui.QWizard): class OpenLPWizard(QtGui.QWizard):

View File

@ -370,12 +370,9 @@ class BibleImportForm(OpenLPWizard):
self.selectPage.setTitle(WizardStrings.ImportSelect) self.selectPage.setTitle(WizardStrings.ImportSelect)
self.selectPage.setSubTitle(WizardStrings.ImportSelectLong) self.selectPage.setSubTitle(WizardStrings.ImportSelectLong)
self.formatLabel.setText(WizardStrings.FormatLabel) self.formatLabel.setText(WizardStrings.FormatLabel)
self.formatComboBox.setItemText(0, self.formatComboBox.setItemText(0, WizardStrings.OSIS)
translate('BiblesPlugin.ImportWizardForm', 'OSIS')) self.formatComboBox.setItemText(1, WizardStrings.CSV)
self.formatComboBox.setItemText(1, self.formatComboBox.setItemText(2, WizardStrings.OS)
translate('BiblesPlugin.ImportWizardForm', 'CSV'))
self.formatComboBox.setItemText(2,
translate('BiblesPlugin.ImportWizardForm', 'OpenSong'))
self.formatComboBox.setItemText(3, self.formatComboBox.setItemText(3,
translate('BiblesPlugin.ImportWizardForm', 'Web Download')) translate('BiblesPlugin.ImportWizardForm', 'Web Download'))
self.formatComboBox.setItemText(4, self.formatComboBox.setItemText(4,
@ -459,9 +456,7 @@ class BibleImportForm(OpenLPWizard):
if self.field(u'source_format').toInt()[0] == BibleFormat.OSIS: if self.field(u'source_format').toInt()[0] == BibleFormat.OSIS:
if not self.field(u'osis_location').toString(): if not self.field(u'osis_location').toString():
critical_error_message_box(UiStrings.NFSs, critical_error_message_box(UiStrings.NFSs,
translate('BiblesPlugin.ImportWizardForm', WizardStrings.YouSpecifyFile % WizardStrings.OSIS)
'You need to specify a file to import your '
'Bible from.'))
self.osisFileEdit.setFocus() self.osisFileEdit.setFocus()
return False return False
elif self.field(u'source_format').toInt()[0] == BibleFormat.CSV: elif self.field(u'source_format').toInt()[0] == BibleFormat.CSV:
@ -473,7 +468,7 @@ class BibleImportForm(OpenLPWizard):
if answer == QtGui.QMessageBox.No: if answer == QtGui.QMessageBox.No:
self.csvTestamentsEdit.setFocus() self.csvTestamentsEdit.setFocus()
return False return False
elif not self.field(u'csv_booksfile').toString(): if not self.field(u'csv_booksfile').toString():
critical_error_message_box(UiStrings.NFSs, critical_error_message_box(UiStrings.NFSs,
translate('BiblesPlugin.ImportWizardForm', translate('BiblesPlugin.ImportWizardForm',
'You need to specify a file with books of ' 'You need to specify a file with books of '
@ -491,17 +486,13 @@ class BibleImportForm(OpenLPWizard):
BibleFormat.OpenSong: BibleFormat.OpenSong:
if not self.field(u'opensong_file').toString(): if not self.field(u'opensong_file').toString():
critical_error_message_box(UiStrings.NFSs, critical_error_message_box(UiStrings.NFSs,
translate('BiblesPlugin.ImportWizardForm', WizardStrings.YouSpecifyFile % WizardStrings.OS)
'You need to specify an OpenSong Bible '
'file to import.'))
self.openSongFileEdit.setFocus() self.openSongFileEdit.setFocus()
return False return False
elif self.field(u'source_format').toInt()[0] == BibleFormat.OpenLP1: elif self.field(u'source_format').toInt()[0] == BibleFormat.OpenLP1:
if not self.field(u'openlp1_location').toString(): if not self.field(u'openlp1_location').toString():
critical_error_message_box(UiStrings.NFSs, critical_error_message_box(UiStrings.NFSs,
translate('BiblesPlugin.ImportWizardForm', WizardStrings.YouSpecifyFile % UiStrings.OLPV1)
'You need to specify a file to import your '
'Bible from.'))
self.openlp1FileEdit.setFocus() self.openlp1FileEdit.setFocus()
return False return False
return True return True
@ -551,24 +542,22 @@ class BibleImportForm(OpenLPWizard):
""" """
Show the file open dialog for the OSIS file. Show the file open dialog for the OSIS file.
""" """
self.getFileName( self.getFileName(WizardStrings.OpenTypeFile % WizardStrings.OSIS,
translate('BiblesPlugin.ImportWizardForm', 'Open OSIS File'),
self.osisFileEdit) self.osisFileEdit)
def onCsvTestamentsBrowseButtonClicked(self): def onCsvTestamentsBrowseButtonClicked(self):
""" """
Show the file open dialog for the testaments CSV file. Show the file open dialog for the testaments CSV file.
""" """
self.getFileName(translate('BiblesPlugin.ImportWizardForm', self.getFileName(WizardStrings.OpenTypeFile % WizardStrings.CSV,
'Open Testaments CSV File'), self.csvTestamentsEdit, u'%s (*.csv)' self.csvTestamentsEdit, u'%s (*.csv)'
% translate('BiblesPlugin.ImportWizardForm', 'CSV File')) % translate('BiblesPlugin.ImportWizardForm', 'CSV File'))
def onCsvBooksBrowseButtonClicked(self): def onCsvBooksBrowseButtonClicked(self):
""" """
Show the file open dialog for the books CSV file. Show the file open dialog for the books CSV file.
""" """
self.getFileName( self.getFileName(WizardStrings.OpenTypeFile % WizardStrings.CSV,
translate('BiblesPlugin.ImportWizardForm', 'Open Books CSV File'),
self.csvBooksEdit, u'%s (*.csv)' self.csvBooksEdit, u'%s (*.csv)'
% translate('BiblesPlugin.ImportWizardForm', 'CSV File')) % translate('BiblesPlugin.ImportWizardForm', 'CSV File'))
@ -576,27 +565,24 @@ class BibleImportForm(OpenLPWizard):
""" """
Show the file open dialog for the verses CSV file. Show the file open dialog for the verses CSV file.
""" """
self.getFileName(translate('BiblesPlugin.ImportWizardForm', self.getFileName(WizardStrings.OpenTypeFile % WizardStrings.CSV,
'Open Verses CSV File'), self.csvVersesEdit, u'%s (*.csv)' self.csvVersesEdit, u'%s (*.csv)'
% translate('BiblesPlugin.ImportWizardForm', 'CSV File')) % translate('BiblesPlugin.ImportWizardForm', 'CSV File'))
def onOpenSongBrowseButtonClicked(self): def onOpenSongBrowseButtonClicked(self):
""" """
Show the file open dialog for the OpenSong file. Show the file open dialog for the OpenSong file.
""" """
self.getFileName( self.getFileName(WizardStrings.OpenTypeFile % WizardStrings.OS,
translate('BiblesPlugin.ImportWizardForm', 'Open OpenSong Bible'),
self.openSongFileEdit) self.openSongFileEdit)
def onOpenlp1BrowseButtonClicked(self): def onOpenlp1BrowseButtonClicked(self):
""" """
Show the file open dialog for the openlp.org 1.x file. Show the file open dialog for the openlp.org 1.x file.
""" """
self.getFileName( self.getFileName(WizardStrings.OpenTypeFile % WizardStrings.OLPV1,
translate('BiblesPlugin.ImportWizardForm', self.openlp1FileEdit, u'%s (*.bible)' %
'Open openlp.org 1.x Bible'), self.openlp1FileEdit, translate('BiblesPlugin.ImportWizardForm', 'openlp.org 1.x bible'))
u'%s (*.bible)' % translate('BiblesPlugin.ImportWizardForm',
'openlp.org 1.x bible'))
def registerFields(self): def registerFields(self):
""" """

View File

@ -207,29 +207,17 @@ class SongImportForm(OpenLPWizard):
self.sourcePage.setSubTitle(WizardStrings.ImportSelectLong) self.sourcePage.setSubTitle(WizardStrings.ImportSelectLong)
self.formatLabel.setText(WizardStrings.FormatLabel) self.formatLabel.setText(WizardStrings.FormatLabel)
self.formatComboBox.setItemText(0, UiStrings.OLPV2) self.formatComboBox.setItemText(0, UiStrings.OLPV2)
self.formatComboBox.setItemText(1, self.formatComboBox.setItemText(1, UiStrings.OLPV1)
translate('SongsPlugin.ImportWizardForm', 'openlp.org 1.x')) self.formatComboBox.setItemText(2, WizardStrings.OL)
self.formatComboBox.setItemText(2, self.formatComboBox.setItemText(3, WizardStrings.OS)
translate('SongsPlugin.ImportWizardForm', 'OpenLyrics')) self.formatComboBox.setItemText(4, WizardStrings.WoW)
self.formatComboBox.setItemText(3, self.formatComboBox.setItemText(5, WizardStrings.CCLI)
translate('SongsPlugin.ImportWizardForm', 'OpenSong')) self.formatComboBox.setItemText(6, WizardStrings.SoF)
self.formatComboBox.setItemText(4, self.formatComboBox.setItemText(7, WizardStrings.GDP)
translate('SongsPlugin.ImportWizardForm', 'Words of Worship')) self.formatComboBox.setItemText(8, WizardStrings.ES)
self.formatComboBox.setItemText(5, self.formatComboBox.setItemText(9, WizardStrings.EW)
translate('SongsPlugin.ImportWizardForm', 'CCLI/SongSelect')) self.formatComboBox.setItemText(10, WizardStrings.SB)
self.formatComboBox.setItemText(6, # self.formatComboBox.setItemText(11, WizardStrings.CSV)
translate('SongsPlugin.ImportWizardForm', 'Songs of Fellowship'))
self.formatComboBox.setItemText(7,
translate('SongsPlugin.ImportWizardForm',
'Generic Document/Presentation'))
self.formatComboBox.setItemText(8,
translate('SongsPlugin.ImportWizardForm', 'EasiSlides'))
self.formatComboBox.setItemText(9,
translate('SongsPlugin.ImportWizardForm', 'EasyWorship'))
self.formatComboBox.setItemText(10,
translate('SongsPlugin.ImportWizardForm', 'SongBeamer'))
# self.formatComboBox.setItemText(11,
# translate('SongsPlugin.ImportWizardForm', 'CSV'))
self.openLP2FilenameLabel.setText( self.openLP2FilenameLabel.setText(
translate('SongsPlugin.ImportWizardForm', 'Filename:')) translate('SongsPlugin.ImportWizardForm', 'Filename:'))
self.openLP2BrowseButton.setText(UiStrings.Browse) self.openLP2BrowseButton.setText(UiStrings.Browse)
@ -316,89 +304,68 @@ class SongImportForm(OpenLPWizard):
if source_format == SongFormat.OpenLP2: if source_format == SongFormat.OpenLP2:
if self.openLP2FilenameEdit.text().isEmpty(): if self.openLP2FilenameEdit.text().isEmpty():
critical_error_message_box(UiStrings.NFSs, critical_error_message_box(UiStrings.NFSs,
translate('SongsPlugin.ImportWizardForm', WizardStrings.YouSpecifyFile % UiStrings.OLPV2)
'You need to select an OpenLP 2.0 song database '
'file to import from.'))
self.openLP2BrowseButton.setFocus() self.openLP2BrowseButton.setFocus()
return False return False
elif source_format == SongFormat.OpenLP1: elif source_format == SongFormat.OpenLP1:
if self.openLP1FilenameEdit.text().isEmpty(): if self.openLP1FilenameEdit.text().isEmpty():
critical_error_message_box(UiStrings.NFSs, critical_error_message_box(UiStrings.NFSs,
translate('SongsPlugin.ImportWizardForm', WizardStrings.YouSpecifyFile % UiStrings.OLPV1)
'You need to select an openlp.org 1.x song '
'database file to import from.'))
self.openLP1BrowseButton.setFocus() self.openLP1BrowseButton.setFocus()
return False return False
elif source_format == SongFormat.OpenLyrics: elif source_format == SongFormat.OpenLyrics:
if self.openLyricsFileListWidget.count() == 0: if self.openLyricsFileListWidget.count() == 0:
critical_error_message_box(UiStrings.NFSp, critical_error_message_box(UiStrings.NFSp,
translate('SongsPlugin.ImportWizardForm', WizardStrings.YouSpecifyFile % WizardStrings.OL)
'You need to add at least one OpenLyrics '
'song file to import from.'))
self.openLyricsAddButton.setFocus() self.openLyricsAddButton.setFocus()
return False return False
elif source_format == SongFormat.OpenSong: elif source_format == SongFormat.OpenSong:
if self.openSongFileListWidget.count() == 0: if self.openSongFileListWidget.count() == 0:
critical_error_message_box(UiStrings.NFSp, critical_error_message_box(UiStrings.NFSp,
translate('SongsPlugin.ImportWizardForm', WizardStrings.YouSpecifyFile % WizardStrings.OS)
'You need to add at least one OpenSong '
'song file to import from.'))
self.openSongAddButton.setFocus() self.openSongAddButton.setFocus()
return False return False
elif source_format == SongFormat.WordsOfWorship: elif source_format == SongFormat.WordsOfWorship:
if self.wordsOfWorshipFileListWidget.count() == 0: if self.wordsOfWorshipFileListWidget.count() == 0:
critical_error_message_box(UiStrings.NFSp, critical_error_message_box(UiStrings.NFSp,
translate('SongsPlugin.ImportWizardForm', WizardStrings.YouSpecifyFile % WizardStrings.WoW)
'You need to add at least one Words of Worship '
'file to import from.'))
self.wordsOfWorshipAddButton.setFocus() self.wordsOfWorshipAddButton.setFocus()
return False return False
elif source_format == SongFormat.CCLI: elif source_format == SongFormat.CCLI:
if self.ccliFileListWidget.count() == 0: if self.ccliFileListWidget.count() == 0:
critical_error_message_box(UiStrings.NFSp, critical_error_message_box(UiStrings.NFSp,
translate('SongsPlugin.ImportWizardForm', WizardStrings.YouSpecifyFile % WizardStrings.CCLI)
'You need to add at least one CCLI file '
'to import from.'))
self.ccliAddButton.setFocus() self.ccliAddButton.setFocus()
return False return False
elif source_format == SongFormat.SongsOfFellowship: elif source_format == SongFormat.SongsOfFellowship:
if self.songsOfFellowshipFileListWidget.count() == 0: if self.songsOfFellowshipFileListWidget.count() == 0:
critical_error_message_box(UiStrings.NFSp, critical_error_message_box(UiStrings.NFSp,
translate('SongsPlugin.ImportWizardForm', WizardStrings.YouSpecifyFile % WizardStrings.SoF)
'You need to add at least one Songs of Fellowship '
'file to import from.'))
self.songsOfFellowshipAddButton.setFocus() self.songsOfFellowshipAddButton.setFocus()
return False return False
elif source_format == SongFormat.Generic: elif source_format == SongFormat.Generic:
if self.genericFileListWidget.count() == 0: if self.genericFileListWidget.count() == 0:
critical_error_message_box(UiStrings.NFSp, critical_error_message_box(UiStrings.NFSp,
translate('SongsPlugin.ImportWizardForm', WizardStrings.YouSpecifyFile %
'You need to add at least one document or ' WizardStrings.GDP.toLower())
'presentation file to import from.'))
self.genericAddButton.setFocus() self.genericAddButton.setFocus()
return False return False
elif source_format == SongFormat.EasiSlides: elif source_format == SongFormat.EasiSlides:
if self.easiSlidesFilenameEdit.text().isEmpty(): if self.easiSlidesFilenameEdit.text().isEmpty():
critical_error_message_box(UiStrings.NFSp, critical_error_message_box(UiStrings.NFSp,
translate('SongsPlugin.ImportWizardForm', WizardStrings.YouSpecifyFile % WizardStrings.ES)
'You need to select an xml song file exported from '
'EasiSlides, to import from.'))
self.easiSlidesBrowseButton.setFocus() self.easiSlidesBrowseButton.setFocus()
return False return False
elif source_format == SongFormat.EasyWorship: elif source_format == SongFormat.EasyWorship:
if self.ewFilenameEdit.text().isEmpty(): if self.ewFilenameEdit.text().isEmpty():
critical_error_message_box(UiStrings.NFSs, critical_error_message_box(UiStrings.NFSs,
translate('SongsPlugin.ImportWizardForm', WizardStrings.YouSpecifyFile % WizardStrings.EW)
'You need to select an EasyWorship song database '
'file to import from.'))
self.ewBrowseButton.setFocus() self.ewBrowseButton.setFocus()
return False return False
elif source_format == SongFormat.SongBeamer: elif source_format == SongFormat.SongBeamer:
if self.songBeamerFileListWidget.count() == 0: if self.songBeamerFileListWidget.count() == 0:
critical_error_message_box(UiStrings.NFSp, critical_error_message_box(UiStrings.NFSp,
translate('SongsPlugin.ImportWizardForm', WizardStrings.YouSpecifyFile % WizardStrings.SB)
'You need to add at least one SongBeamer '
'file to import from.'))
self.songBeamerAddButton.setFocus() self.songBeamerAddButton.setFocus()
return False return False
return True return True
@ -454,9 +421,7 @@ class SongImportForm(OpenLPWizard):
""" """
Get OpenLP v2 song database file Get OpenLP v2 song database file
""" """
self.getFileName( self.getFileName(WizardStrings.OpenTypeFile % UiStrings.OLPV2,
translate('SongsPlugin.ImportWizardForm',
'Select OpenLP 2.0 Database File'),
self.openLP2FilenameEdit, u'%s (*.sqlite)' self.openLP2FilenameEdit, u'%s (*.sqlite)'
% (translate('SongsPlugin.ImportWizardForm', % (translate('SongsPlugin.ImportWizardForm',
'OpenLP 2.0 Databases')) 'OpenLP 2.0 Databases'))
@ -466,9 +431,7 @@ class SongImportForm(OpenLPWizard):
""" """
Get OpenLP v1 song database file Get OpenLP v1 song database file
""" """
self.getFileName( self.getFileName(WizardStrings.OpenTypeFile % UiStrings.OLPV1,
translate('SongsPlugin.ImportWizardForm',
'Select openlp.org 1.x Database File'),
self.openLP1FilenameEdit, u'%s (*.olp)' self.openLP1FilenameEdit, u'%s (*.olp)'
% translate('SongsPlugin.ImportWizardForm', % translate('SongsPlugin.ImportWizardForm',
'openlp.org v1.x Databases') 'openlp.org v1.x Databases')
@ -478,11 +441,8 @@ class SongImportForm(OpenLPWizard):
""" """
Get OpenLyrics song database files Get OpenLyrics song database files
""" """
self.getFiles( self.getFileName(WizardStrings.OpenTypeFile % WizardStrings.OL,
translate('SongsPlugin.ImportWizardForm', self.openLyricsFileListWidget)
'Select OpenLyrics Files'),
self.openLyricsFileListWidget
)
def onOpenLyricsRemoveButtonClicked(self): def onOpenLyricsRemoveButtonClicked(self):
""" """
@ -494,10 +454,8 @@ class SongImportForm(OpenLPWizard):
""" """
Get OpenSong song database files Get OpenSong song database files
""" """
self.getFiles( self.getFileName(WizardStrings.OpenTypeFile % WizardStrings.OS,
translate('SongsPlugin.ImportWizardForm', 'Select Open Song Files'), self.openSongFileListWidget)
self.openSongFileListWidget
)
def onOpenSongRemoveButtonClicked(self): def onOpenSongRemoveButtonClicked(self):
""" """
@ -509,9 +467,7 @@ class SongImportForm(OpenLPWizard):
""" """
Get Words of Worship song database files Get Words of Worship song database files
""" """
self.getFiles( self.getFileName(WizardStrings.OpenTypeFile % WizardStrings.WoW,
translate('SongsPlugin.ImportWizardForm',
'Select Words of Worship Files'),
self.wordsOfWorshipFileListWidget, u'%s (*.wsg *.wow-song)' self.wordsOfWorshipFileListWidget, u'%s (*.wsg *.wow-song)'
% translate('SongsPlugin.ImportWizardForm', % translate('SongsPlugin.ImportWizardForm',
'Words Of Worship Song Files') 'Words Of Worship Song Files')
@ -527,11 +483,8 @@ class SongImportForm(OpenLPWizard):
""" """
Get CCLI song database files Get CCLI song database files
""" """
self.getFiles( self.getFileName(WizardStrings.OpenTypeFile % WizardStrings.CCLI,
translate('SongsPlugin.ImportWizardForm', self.ccliFileListWidget)
'Select CCLI Files'),
self.ccliFileListWidget
)
def onCCLIRemoveButtonClicked(self): def onCCLIRemoveButtonClicked(self):
""" """
@ -543,9 +496,7 @@ class SongImportForm(OpenLPWizard):
""" """
Get Songs of Fellowship song database files Get Songs of Fellowship song database files
""" """
self.getFiles( self.getFileName(WizardStrings.OpenTypeFile % WizardStrings.SoF,
translate('SongsPlugin.ImportWizardForm',
'Select Songs of Fellowship Files'),
self.songsOfFellowshipFileListWidget, u'%s (*.rtf)' self.songsOfFellowshipFileListWidget, u'%s (*.rtf)'
% translate('SongsPlugin.ImportWizardForm', % translate('SongsPlugin.ImportWizardForm',
'Songs Of Fellowship Song Files') 'Songs Of Fellowship Song Files')
@ -561,11 +512,8 @@ class SongImportForm(OpenLPWizard):
""" """
Get song database files Get song database files
""" """
self.getFiles( self.getFileName(WizardStrings.OpenTypeFile % WizardStrings.GDP,
translate('SongsPlugin.ImportWizardForm', self.genericFileListWidget)
'Select Document/Presentation Files'),
self.genericFileListWidget
)
def onGenericRemoveButtonClicked(self): def onGenericRemoveButtonClicked(self):
""" """
@ -574,29 +522,21 @@ class SongImportForm(OpenLPWizard):
self.removeSelectedItems(self.genericFileListWidget) self.removeSelectedItems(self.genericFileListWidget)
def onEasiSlidesBrowseButtonClicked(self): def onEasiSlidesBrowseButtonClicked(self):
self.getFileName( self.getFileName(WizardStrings.OpenTypeFile % WizardStrings.ES,
translate('SongsPlugin.ImportWizardForm', self.easiSlidesFilenameEdit)
'Select EasiSlides songfile'),
self.easiSlidesFilenameEdit
)
def onEWBrowseButtonClicked(self): def onEWBrowseButtonClicked(self):
""" """
Get EasyWorship song database files Get EasyWorship song database files
""" """
self.getFileName( self.getFileName(WizardStrings.OpenTypeFile % WizardStrings.EW,
translate('SongsPlugin.ImportWizardForm', self.ewFilenameEdit)
'Select EasyWorship Database File'),
self.ewFilenameEdit
)
def onSongBeamerAddButtonClicked(self): def onSongBeamerAddButtonClicked(self):
""" """
Get SongBeamer song database files Get SongBeamer song database files
""" """
self.getFiles( self.getFileName(WizardStrings.OpenTypeFile % WizardStrings.SB,
translate('SongsPlugin.ImportWizardForm',
'Select SongBeamer Files'),
self.songBeamerFileListWidget, u'%s (*.sng)' % self.songBeamerFileListWidget, u'%s (*.sng)' %
translate('SongsPlugin.ImportWizardForm', 'SongBeamer files') translate('SongsPlugin.ImportWizardForm', 'SongBeamer files')
) )