1
0
mirror of https://github.com/clementine-player/Clementine synced 2024-12-16 11:19:18 +01:00

Show the basefilename in the title column if there's no title tag. Fixes issue #99

This commit is contained in:
David Sansome 2010-03-25 15:00:56 +00:00
parent d5762bbbd7
commit 38b114e4ad

View File

@ -83,7 +83,8 @@ QVariant Playlist::data(const QModelIndex& index, int role) const {
// Don't forget to change Playlist::CompareItems when adding new columns // Don't forget to change Playlist::CompareItems when adding new columns
switch (index.column()) { switch (index.column()) {
case Column_Title: return song.title(); case Column_Title:
return song.title().isEmpty() ? song.basefilename() : song.title();
case Column_Artist: return song.artist(); case Column_Artist: return song.artist();
case Column_Album: return song.album(); case Column_Album: return song.album();
case Column_Length: return song.length(); case Column_Length: return song.length();