X-Git-Url: https://cloud.milkyroute.net/gitweb/dolphin.git/blobdiff_plain/ce7852fb2352155e4373f9a41f0a01549985bd45..c6bccbf6de33ba907f1cddfa64dadb8cfeea4d2c:/src/kitemviews/kfileitemmodel.cpp diff --git a/src/kitemviews/kfileitemmodel.cpp b/src/kitemviews/kfileitemmodel.cpp index 23afb087a..052a71cbd 100644 --- a/src/kitemviews/kfileitemmodel.cpp +++ b/src/kitemviews/kfileitemmodel.cpp @@ -15,6 +15,7 @@ #include #include +#include #include #include #include @@ -575,6 +576,9 @@ bool KFileItemModel::setExpanded(int index, bool expanded) m_expandedDirs.remove(targetUrl); m_dirLister->stop(url); +#if KIO_VERSION >= QT_VERSION_CHECK(5, 92, 0) + m_dirLister->forgetDirs(url); +#endif const int parentLevel = expandedParentsCount(index); const int itemCount = m_itemData.count(); @@ -590,6 +594,9 @@ bool KFileItemModel::setExpanded(int index, bool expanded) const QUrl url = itemData->item.url(); m_expandedDirs.remove(targetUrl); m_dirLister->stop(url); // TODO: try to unit-test this, see https://bugs.kde.org/show_bug.cgi?id=332102#c11 +#if KIO_VERSION >= QT_VERSION_CHECK(5, 92, 0) + m_dirLister->forgetDirs(url); +#endif expandedChildren.append(targetUrl); } ++childIndex;