diff options
author | Uwe Klotz <uwe_klotz@web.de> | 2016-12-08 22:26:50 +0100 |
---|---|---|
committer | Uwe Klotz <uwe_klotz@web.de> | 2016-12-09 23:45:42 +0100 |
commit | 7d2e0fce392413c7a4f4292ccc0dd5e5f45f496f (patch) | |
tree | 353080c6a7e3ab2b8bba9ff2d8c2b48a18a41c27 /src/library/browse/foldertreemodel.cpp | |
parent | e49571835af3278537630b1d09af94cb54c38e26 (diff) |
Improve and simplify the design/interface of TreeItem
Diffstat (limited to 'src/library/browse/foldertreemodel.cpp')
-rw-r--r-- | src/library/browse/foldertreemodel.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/library/browse/foldertreemodel.cpp b/src/library/browse/foldertreemodel.cpp index 62b28afc41..3c51828f15 100644 --- a/src/library/browse/foldertreemodel.cpp +++ b/src/library/browse/foldertreemodel.cpp @@ -38,14 +38,14 @@ bool FolderTreeModel::hasChildren(const QModelIndex& parent) const { * However, for, buid-in items such as 'Quick Links' there exist * child items at init time */ - if(item->dataPath().toString() == QUICK_LINK_NODE) + if(item->getData().toString() == QUICK_LINK_NODE) return true; //Can only happen on Windows - if(item->dataPath().toString() == DEVICE_NODE) + if(item->getData().toString() == DEVICE_NODE) return true; - // In all other cases the dataPath() points to a folder - QString folder = item->dataPath().toString(); + // In all other cases the getData() points to a folder + QString folder = item->getData().toString(); return directoryHasChildren(folder); } @@ -63,7 +63,7 @@ bool FolderTreeModel::directoryHasChildren(const QString& path) const { * QDIR::EntryInfoList returns a full QFileInfolist * * - * QDir dir(item->dataPath().toString()); + * QDir dir(item->getData().toString()); * QFileInfoList all = dir.entryInfoList(QDir::Dirs | QDir::NoDotAndDotDot); * return (all.count() > 0); * |