=== modified file 'mixxx/src/library/itunestrackmodel.cpp' --- mixxx/src/library/itunestrackmodel.cpp 2010-02-16 07:27:18 +0000 +++ mixxx/src/library/itunestrackmodel.cpp 2010-02-18 21:18:13 +0000 @@ -208,8 +208,21 @@ return findValueByKey(songNode,"Year"); case ITunesTrackModel::COLUMN_GENRE: return findValueByKey(songNode,"Genre"); - case ITunesTrackModel::COLUMN_LOCATION: - return findValueByKey(songNode,"Location"); + case ITunesTrackModel::COLUMN_LOCATION: { + /* + * Strip the crappy file://localhost/ from the URL and + * format URL as in method ITunesTrackModel::parseTrackNode(QDomNode songNode) + */ + QString strloc = findValueByKey(songNode,"Location"); + QByteArray strlocbytes = strloc.toUtf8(); + QString location = QUrl::fromEncoded(strlocbytes).toLocalFile(); + #if defined(__WINDOWS__) + return location.remove("//localhost/"); + #else + return location.remove("//localhost"); + #endif + } + case ITunesTrackModel::COLUMN_DURATION: value = findValueByKey(songNode,"Total Time"); if (qVariantCanConvert(value)) {