aboutsummaryrefslogtreecommitdiff
path: root/src/ui
diff options
context:
space:
mode:
Diffstat (limited to 'src/ui')
-rw-r--r--src/ui/playlistmodel.cpp10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/ui/playlistmodel.cpp b/src/ui/playlistmodel.cpp
index b155114ec..f0e1643b8 100644
--- a/src/ui/playlistmodel.cpp
+++ b/src/ui/playlistmodel.cpp
@@ -109,7 +109,7 @@ void PlayListModel::load(PlayListItem *item)
emit firstAdded();
//if (!m_block_update_signals)
- emit listChanged();
+ emit listChanged();
}
int PlayListModel::count()
@@ -857,7 +857,13 @@ void PlayListModel::loadPlaylist(const QString &f_name)
if (file.open(QIODevice::ReadOnly))
{
//clear();
- addFiles(prs->decode(QTextStream(&file).readAll()));
+ QStringList list = prs->decode(QTextStream(&file).readAll());
+ for (int i = 0; i < list.size(); ++i)
+ {
+ if (QFileInfo(list.at(i)).isRelative() && !list.at(i).contains("://"))
+ QString path = list[i].prepend(QFileInfo(f_name).canonicalPath () + QDir::separator ());
+ }
+ addFiles(list);
file.close();
}
else