From 0397658b81ce371047d9ce6979aa37d8112f1a2c Mon Sep 17 00:00:00 2001 From: Peter Penz Date: Tue, 14 Feb 2012 18:04:47 +0100 Subject: Details view: Fix indicator-branches Up to now no indicator-branches have been drawn when showing a tree. The patch fixes this so that that the style-dependent branches are drawn. The main part of the patch is the implementation of KItemListView::updateSiblingsInformation(). Most of the other changes are related due to an internal renaming of the expansionsLevel-role to expandedParentsCount and some related cleanups. BUG: 290276 FIXED-IN: 4.8.1 --- src/kitemviews/kitemlistview.h | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'src/kitemviews/kitemlistview.h') diff --git a/src/kitemviews/kitemlistview.h b/src/kitemviews/kitemlistview.h index 6ed714b20..dbb746d92 100644 --- a/src/kitemviews/kitemlistview.h +++ b/src/kitemviews/kitemlistview.h @@ -496,6 +496,20 @@ private: */ void updateGroupHeaderHeight(); + /** + * Updates the siblings-information for all visible items that are inside + * the range of \p firstIndex and \p lastIndex. + * @see KItemListWidget::setSiblingsInformation() + */ + void updateSiblingsInformation(int firstIndex, int lastIndex); + + /** + * Helper method for updateExpansionIndicators(). + * @return True if the item with the index \a index has a sibling successor + * (= the item is not the last item of the current hierarchy). + */ + bool hasSiblingSuccessor(int index) const; + /** * Helper function for triggerAutoScrolling(). * @param pos Logical position of the mouse relative to the range. -- cgit v1.3