Details
-
Bug
-
Resolution: Done
-
P2: Important
-
4.8.7, 5.12.0
-
Windows
$ uname -a
Linux vbbbbbb-u 4.8.0-2-amd64 #1 SMP Debian 4.8.15-2 (2017-01-04) x86_64 GNU/Linux
$ apt-cache policy libqt4-dev
libqt4-dev:
Installed: 4:4.8.7+dfsg-11
Candidate: 4:4.8.7+dfsg-11
Version table:
*** 4:4.8.7+dfsg-11 990
990 http://ftp.de.debian.org/debian stretch/main amd64 Packages
500 http://ftp.de.debian.org/debian unstable/main amd64 Packages
100 /var/lib/dpkg/statusWindows $ uname -a Linux vbbbbbb-u 4.8.0-2-amd64 #1 SMP Debian 4.8.15-2 (2017-01-04) x86_64 GNU/Linux $ apt-cache policy libqt4-dev libqt4-dev: Installed: 4:4.8.7+dfsg-11 Candidate: 4:4.8.7+dfsg-11 Version table: *** 4:4.8.7+dfsg-11 990 990 http://ftp.de.debian.org/debian stretch/main amd64 Packages 500 http://ftp.de.debian.org/debian unstable/main amd64 Packages 100 /var/lib/dpkg/status
-
7e60858cbc40b8958482ca2e77bed4fda69b161c (qt/qtbase/5.12)
Description
Hi,
I can craft a QTreeWidget containg a set of QTreeWidgetItem where a click to "collapse" one item triggers the "checking" an unrelated item.
This happens when a too-long tree of items is scrolled to the very bottom. When collapsing an item by clicking the appropriate box, the list autoscrolls and thus changes the item currently under the mouse-cursor. If if the item appearing under the cursor happens to be a "checkable" parent item, the mouse button release of the click to "collapse" will now toggle the "checked" status of the completely unrelated QTreeWidgetItem.
See the attached "minimal_example.cpp" file. The screenshots depict the situation before and after collapsing the "rootItem3->scndLevel1" item. Note that the previously unchecked "rootItem3" is checked afterwards although only a single click was performed.
I would have expected that the QTreeWidget behaves differently, although I do not know how a good solution would look like. I assume this will not be fixed for Qt4 ;-(
Is the same behavior observed in Qt5?
Greetings
Attachments
For Gerrit Dashboard: QTBUG-61476 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
253348,4 | Don't edit the item if we did not get the press event on the same item | 5.12 | qt/qtbase | Status: MERGED | +2 | 0 |