diff options
| author | Rafael Fernández López <[email protected]> | 2008-01-02 01:21:39 +0000 |
|---|---|---|
| committer | Rafael Fernández López <[email protected]> | 2008-01-02 01:21:39 +0000 |
| commit | 743bec375187a51ed6b88256ff070e9f7e9f4929 (patch) | |
| tree | cc6948abd9d21ecc0b5074883f7d4dcaa21f9382 /src/kcategorizedview.cpp | |
| parent | c6a4a3aa063fb25e163bed8dac8587efef8c02b5 (diff) | |
Better looking categories. Thanks to Aurélien Gâteau for the original patch.
CCMAIL: [email protected]
svn path=/trunk/KDE/kdebase/apps/; revision=755674
Diffstat (limited to 'src/kcategorizedview.cpp')
| -rw-r--r-- | src/kcategorizedview.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/kcategorizedview.cpp b/src/kcategorizedview.cpp index b2504a14b..51b4a000b 100644 --- a/src/kcategorizedview.cpp +++ b/src/kcategorizedview.cpp @@ -129,12 +129,12 @@ QRect KCategorizedView::Private::visualRectInViewport(const QModelIndex &index) if (listView->layoutDirection() == Qt::LeftToRight) { retRect = QRect(listView->spacing(), listView->spacing() * 2 + - categoryDrawer->categoryHeight(listView->viewOptions()), 0, 0); + categoryDrawer->categoryHeight(index, listView->viewOptions()), 0, 0); } else { retRect = QRect(listView->viewport()->width() - listView->spacing(), listView->spacing() * 2 + - categoryDrawer->categoryHeight(listView->viewOptions()), 0, 0); + categoryDrawer->categoryHeight(index, listView->viewOptions()), 0, 0); } int viewportWidth = listView->viewport()->width() - listView->spacing(); @@ -189,7 +189,7 @@ QRect KCategorizedView::Private::visualRectInViewport(const QModelIndex &index) retRect.setTop(retRect.top() + (rowsInt * itemHeight) + - categoryDrawer->categoryHeight(listView->viewOptions()) + + categoryDrawer->categoryHeight(index, listView->viewOptions()) + listView->spacing() * 2); if (listView->gridSize().isEmpty()) @@ -273,7 +273,7 @@ QRect KCategorizedView::Private::visualCategoryRectInViewport(const QString &cat retRect.setTop(retRect.top() + (rowsInt * itemHeight) + - categoryDrawer->categoryHeight(listView->viewOptions()) + + categoryDrawer->categoryHeight(index, listView->viewOptions()) + listView->spacing() * 2); if (listView->gridSize().isEmpty()) @@ -283,7 +283,7 @@ QRect KCategorizedView::Private::visualCategoryRectInViewport(const QString &cat } } - retRect.setHeight(categoryDrawer->categoryHeight(listView->viewOptions())); + retRect.setHeight(categoryDrawer->categoryHeight(index, listView->viewOptions())); return retRect; } |
