]> cloud.milkyroute.net Git - dolphin.git/commitdiff
Improve behavior when changes are detected on the model.
authorRafael Fernández López <ereslibre@kde.org>
Tue, 26 Jun 2007 19:52:45 +0000 (19:52 +0000)
committerRafael Fernández López <ereslibre@kde.org>
Tue, 26 Jun 2007 19:52:45 +0000 (19:52 +0000)
svn path=/trunk/KDE/kdebase/apps/; revision=680643

src/klistview.cpp

index 1971d7f98def069deb65026bb72f6d58bd962201..e6ffdc1e0f41538dcd0b1260414c55d66abcd231 100644 (file)
@@ -948,6 +948,7 @@ void KListView::rowsInsertedArtifficial(const QModelIndex &parent,
                                         int start,
                                         int end)
 {
+    d->lastSelection = QItemSelection();
     d->elementsInfo.clear();
     d->elementsPosition.clear();
     d->elementDictionary.clear();
@@ -1052,7 +1053,8 @@ void KListView::rowsRemoved(const QModelIndex &parent,
                             int start,
                             int end)
 {
-    if (d->proxyModel)
+    if ((viewMode() == KListView::IconMode) && d->proxyModel &&
+        d->itemCategorizer)
     {
         // Force the view to update all elements
         rowsInsertedArtifficial(parent, start, end);