forked from openlp/openlp
- remove None in .split() method
- change translatable codepage selection strings
This commit is contained in:
parent
bb571b0df5
commit
62766269f1
@ -525,7 +525,7 @@ class EditSongForm(QtGui.QDialog, Ui_EditSongDialog):
|
|||||||
return False
|
return False
|
||||||
if self.song.verse_order:
|
if self.song.verse_order:
|
||||||
order = []
|
order = []
|
||||||
order_names = self.song.verse_order.split(None)
|
order_names = self.song.verse_order.split()
|
||||||
for item in order_names:
|
for item in order_names:
|
||||||
if len(item) == 1:
|
if len(item) == 1:
|
||||||
order.append(item.lower() + u'1')
|
order.append(item.lower() + u'1')
|
||||||
|
@ -358,7 +358,7 @@ class SongMediaItem(MediaManagerItem):
|
|||||||
verse[1][:30], unicode(verse[1]), verseTag)
|
verse[1][:30], unicode(verse[1]), verseTag)
|
||||||
else:
|
else:
|
||||||
#Loop through the verse list and expand the song accordingly.
|
#Loop through the verse list and expand the song accordingly.
|
||||||
for order in song.verse_order.upper().split(None):
|
for order in song.verse_order.upper().split():
|
||||||
if len(order) == 0:
|
if len(order) == 0:
|
||||||
break
|
break
|
||||||
for verse in verseList:
|
for verse in verseList:
|
||||||
|
@ -201,34 +201,34 @@ class OpenLP1SongImport(SongImport):
|
|||||||
guess = u'cp1252'
|
guess = u'cp1252'
|
||||||
|
|
||||||
# Show dialog for encoding selection
|
# Show dialog for encoding selection
|
||||||
encodings = [(u'cp874', translate('SongsPlugin.OpenLP1SongImport',
|
encodings = [(u'cp1256', translate('SongsPlugin.OpenLP1SongImport',
|
||||||
'CP-874 (Thai)')),
|
'Arabic (CP-1256)')),
|
||||||
(u'cp932', translate('SongsPlugin.OpenLP1SongImport',
|
|
||||||
'CP-932 (Japanese)')),
|
|
||||||
(u'cp936', translate('SongsPlugin.OpenLP1SongImport',
|
|
||||||
'CP-936 (Simplified Chinese)')),
|
|
||||||
(u'cp949', translate('SongsPlugin.OpenLP1SongImport',
|
|
||||||
'CP-949 (Korean)')),
|
|
||||||
(u'cp950', translate('SongsPlugin.OpenLP1SongImport',
|
|
||||||
'CP-950 (Traditional Chinese)')),
|
|
||||||
(u'cp1250', translate('SongsPlugin.OpenLP1SongImport',
|
|
||||||
'CP-1250 (Central European)')),
|
|
||||||
(u'cp1251', translate('SongsPlugin.OpenLP1SongImport',
|
|
||||||
'CP-1251 (Cyrillic)')),
|
|
||||||
(u'cp1252', translate('SongsPlugin.OpenLP1SongImport',
|
|
||||||
'CP-1252 (Western European)')),
|
|
||||||
(u'cp1253', translate('SongsPlugin.OpenLP1SongImport',
|
|
||||||
'CP-1253 (Greek)')),
|
|
||||||
(u'cp1254', translate('SongsPlugin.OpenLP1SongImport',
|
|
||||||
'CP-1254 (Turkish)')),
|
|
||||||
(u'cp1255', translate('SongsPlugin.OpenLP1SongImport',
|
|
||||||
'CP-1255 (Hebrew)')),
|
|
||||||
(u'cp1256', translate('SongsPlugin.OpenLP1SongImport',
|
|
||||||
'CP-1256 (Arabic)')),
|
|
||||||
(u'cp1257', translate('SongsPlugin.OpenLP1SongImport',
|
(u'cp1257', translate('SongsPlugin.OpenLP1SongImport',
|
||||||
'CP-1257 (Baltic)')),
|
'Baltic (CP-1257)')),
|
||||||
|
(u'cp1250', translate('SongsPlugin.OpenLP1SongImport',
|
||||||
|
'Central European (CP-1250)')),
|
||||||
|
(u'cp1251', translate('SongsPlugin.OpenLP1SongImport',
|
||||||
|
'Cyrillic (CP-1251)')),
|
||||||
|
(u'cp1253', translate('SongsPlugin.OpenLP1SongImport',
|
||||||
|
'Greek (CP-1253)')),
|
||||||
|
(u'cp1255', translate('SongsPlugin.OpenLP1SongImport',
|
||||||
|
'Hebrew (CP-1255)')),
|
||||||
|
(u'cp932', translate('SongsPlugin.OpenLP1SongImport',
|
||||||
|
'Japanese (CP-932)')),
|
||||||
|
(u'cp949', translate('SongsPlugin.OpenLP1SongImport',
|
||||||
|
'Korean (CP-949)')),
|
||||||
|
(u'cp936', translate('SongsPlugin.OpenLP1SongImport',
|
||||||
|
'Simplified Chinese (CP-936)')),
|
||||||
|
(u'cp874', translate('SongsPlugin.OpenLP1SongImport',
|
||||||
|
'Thai (CP-874)')),
|
||||||
|
(u'cp950', translate('SongsPlugin.OpenLP1SongImport',
|
||||||
|
'Traditional Chinese (CP-950)')),
|
||||||
|
(u'cp1254', translate('SongsPlugin.OpenLP1SongImport',
|
||||||
|
'Turkish (CP-1254)')),
|
||||||
(u'cp1258', translate('SongsPlugin.OpenLP1SongImport',
|
(u'cp1258', translate('SongsPlugin.OpenLP1SongImport',
|
||||||
'CP-1258 (Vietnam)'))]
|
'Vietnam (CP-1258)')),
|
||||||
|
(u'cp1252', translate('SongsPlugin.OpenLP1SongImport',
|
||||||
|
'Western European (CP-1252)'))]
|
||||||
encoding_index = 0
|
encoding_index = 0
|
||||||
for index in range(len(encodings)):
|
for index in range(len(encodings)):
|
||||||
if guess == encodings[index][0]:
|
if guess == encodings[index][0]:
|
||||||
|
Loading…
Reference in New Issue
Block a user