diff options
| author | Peter Penz <[email protected]> | 2012-02-14 22:58:24 +0100 |
|---|---|---|
| committer | Peter Penz <[email protected]> | 2012-02-14 23:00:48 +0100 |
| commit | 83130d8e16a4d6af4b5b8ef0451a95462599ffc1 (patch) | |
| tree | 5258e64ebc15d1c5fd9126b3fffcfa65adab3aae /src/kitemviews/kfileitemmodel.cpp | |
| parent | 55f46ceb9ca128655f2f7859966b7c6d0c50f2ed (diff) | |
Details view: Fix filter issue with sibblings
When the filter has been enabled, the sibblings got not updated. Explicitely
update the sibblings when inserting, removing or moving items. For layouting
implicitely update the sibblings only for recycled widgets.
Diffstat (limited to 'src/kitemviews/kfileitemmodel.cpp')
| -rw-r--r-- | src/kitemviews/kfileitemmodel.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/kitemviews/kfileitemmodel.cpp b/src/kitemviews/kfileitemmodel.cpp index f9ba397fa..ede3c3623 100644 --- a/src/kitemviews/kfileitemmodel.cpp +++ b/src/kitemviews/kfileitemmodel.cpp @@ -471,7 +471,10 @@ bool KFileItemModel::isExpandable(int index) const int KFileItemModel::expandedParentsCount(int index) const { if (index >= 0 && index < count()) { - return m_itemData.at(index)->values.value("expandedParentsCount").toInt(); + const int parentsCount = m_itemData.at(index)->values.value("expandedParentsCount").toInt(); + if (parentsCount > 0) { + return parentsCount; + } } return 0; } |
