fix for windows

This commit is contained in:
Andreas Preikschat 2011-05-23 12:31:23 +02:00
commit a43a4f6a2a
2 changed files with 4 additions and 2 deletions

View File

@ -139,7 +139,8 @@ class CustomMediaItem(MediaManagerItem):
self.listView.clear()
# Sort the customs by its title considering language specific
# characters.
custom_slides.sort(cmp=locale.strcoll, key=operator.attrgetter('title'))
custom_slides.sort(
cmp=locale.strcoll, key=operator.attrgetter('title').lower())
for custom_slide in custom_slides:
custom_name = QtGui.QListWidgetItem(custom_slide.title)
custom_name.setData(

View File

@ -231,7 +231,8 @@ class SongMediaItem(MediaManagerItem):
log.debug(u'display results Song')
self.listView.clear()
# Sort the songs by its title considering language specific characters.
searchresults.sort(cmp=locale.strcoll, key=operator.attrgetter('title'))
searchresults.sort(
cmp=locale.strcoll, key=operator.attrgetter('title').lower())
for song in searchresults:
author_list = [author.display_name for author in song.authors]
song_title = unicode(song.title)