diff options
| author | Volker Hilsheimer <volker.hilsheimer@qt.io> | 2021-06-02 15:24:25 +0200 |
|---|---|---|
| committer | Volker Hilsheimer <volker.hilsheimer@qt.io> | 2021-06-08 00:10:42 +0200 |
| commit | efdaba37d61e82f27a7bcbb49e176313452f59f9 (patch) | |
| tree | 1f8c25617f7bcda5b1776b17981bbe336859df50 /src/testlib/doc/snippets | |
| parent | 8654192f8fe54512f17deeeb312e892b2e964a4f (diff) | |
QAItemView: in MultiSelection, press deselects only if no drag can start
In MultiSelection mode, items are by default toggled on press, which
follows the example of standard Windows controls. However, when dragging
is enabled, then the press might be the beginning of a drag'n'drop
operation, and deselecting the item on press breaks the selection and user
experience.
Don't toggle the selection for presses on an already selected item that
might get dragged; instead, wait for the release event.
Extend the test case slightly to cover the special case. Dragging a
selection in a drag-enabled and MultiSelection item view wasn't possible
before either.
Fixes: QTBUG-59888
Change-Id: Ibd3e95a71ea63dd1e9bc3c8a723eafa9a1c21afa
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: David Skoland <david.skoland@qt.io>
Diffstat (limited to 'src/testlib/doc/snippets')
0 files changed, 0 insertions, 0 deletions
