]> cloud.milkyroute.net Git - dolphin.git/blobdiff - src/klistview.cpp
Fix the scrollbar issue. We can live with the setSingleStep nasty workaround for...
[dolphin.git] / src / klistview.cpp
index 15c8b576ad73b99f7e17d3184a6d68791a02d479..553c4e400c3e31f99e3474f6115c869b4ebadb2d 100644 (file)
@@ -386,6 +386,9 @@ void KListView::Private::updateScrollbars()
 {
     int lastItemBottom = cachedRectIndex(lastIndex).bottom() +
                            listView->spacing() - listView->viewport()->height();
+
+    listView->verticalScrollBar()->setSingleStep(listView->viewport()->height() / 10);
+    listView->verticalScrollBar()->setPageStep(listView->viewport()->height());
     listView->verticalScrollBar()->setRange(0, lastItemBottom);
 }
 
@@ -956,7 +959,7 @@ void KListView::updateGeometries()
 
 void KListView::slotSortingRoleChanged()
 {
-    if ((viewMode() != KListView::ListMode) && d->proxyModel &&
+    if ((viewMode() == KListView::IconMode) && d->proxyModel &&
         d->itemCategorizer)
     {
         // Force the view to update all elements