Version: 1.0.0-beta3 (using KDE 4.2.98) Installed from: Gentoo Packages Steps to reproduce: 1. Activate rating filter (e.g. 4 stars) 2. Select All Images 3. Change rating filter (e.g. 3 stars) --> Result: All images between (and including) the first and the last image with 4 stars are selected. --> Expected behaviour: Selection should not change --> Notes & Workaround: The problem only occurs if "All Images" (Strg-A or dragging a mouse selection recatnagle over all images) have been selected. So, as workaroung, select all images, deselect one and select it again. Then the rating filter can be changed without problems.
It's relevant of new Qt4 model/View code... Gilles Caulier
This is indeep a Qt problem. See this code from QItemSelectionModel: void QItemSelectionModelPrivate::_q_layoutAboutToBeChanged() { savedPersistentIndexes.clear(); savedPersistentCurrentIndexes.clear(); // special case for when all indexes are selected if (ranges.isEmpty() && currentSelection.count() == 1) { QItemSelectionRange range = currentSelection.first(); QModelIndex parent = range.parent(); if (range.top() == 0 && range.left() == 0 && range.bottom() == model->rowCount(parent) - 1 && range.right() == model->columnCount(parent) - 1) { tableSelected = true; tableParent = parent; tableColCount = model->columnCount(parent); tableRowCount = model->rowCount(parent); return; } } ... } void QItemSelectionModelPrivate::_q_layoutChanged() { // special case for when all indexes are selected if (tableSelected && tableColCount == model->columnCount(tableParent) && tableRowCount == model->rowCount(tableParent)) { ... } if (savedPersistentCurrentIndexes.isEmpty() && savedPersistentIndexes.isEmpty()) { // either the selection was actually empty, or we // didn't get the layoutAboutToBeChanged() signal return; } ... } The "special case" is hit in the first method when storing the indexes. In the second method for restoring the selection, the special case is not met, and no indexes have been saved in the savedPersistentIndexes list. 1) For what purpose is this special case added? 2) File a Qt bug?
Posted to Qt task tracker with number 259089.
Now it really got added as a task with number 260134.
Now it has been fixed in Qt 4.6: http://qt.nokia.com/developer/task-tracker/index_html?method=entry&id=260134 KDE 4.4 depends on Qt 4.6. Does that mean that this should be closed? It work sfine now with Qt 4.6 trunk and Digikam trunk.
For me it can be closed.... Marcel Andi, do you have a fix in digiKam for Qt4 < 4.6 ? Gilles
No, because this is an indeep Qt problem. If it is really fixed now, we can ignore the bugreport. At least I don't feel like fixing bugs for Nokia right now :-)
Right. well closed... Gilles