[Interest] [Development] Multi-Selection behavior of item views breaks drag'n'drop UX - options

Volker Hilsheimer volker.hilsheimer at qt.io
Fri Jun 11 16:16:53 CEST 2021


To close this thread, a bunch of changes that fix this in the least intrusive way have been merged for Qt 6.2.

In ExtendedSelection, Ctrl+Press does not deselect items that could also be dragged, Ctrl+Release does; Ctrl+Press on an unselected item selects the item, then you can drag it as part of a previous selection. An equivalent change n MultiSelection (minus the Ctrl):

* https://codereview.qt-project.org/c/qt/qtbase/+/351595/8
* https://codereview.qt-project.org/c/qt/qtbase/+/352401

Thanks for the comments and reviews. Qt 6.2 should be available as snapshot packages already, and the Alpha is around the corner as well. Early feedback to those (and several other changes and fixes to Qt Widgets from the last couple of weeks [1]) would be most welcome.


Cheers,
Volker

[1] https://codereview.qt-project.org/q/is:merged+branch:dev+path:%255Esrc/widgets/.*+after:2021-05-31


> On 1 Jun 2021, at 21:43, Volker Hilsheimer <volker.hilsheimer at qt.io> wrote:
> 
> But git history will remember the fool that broke all the things :P
> 
> Anyway, a bunch of patches in the chain currently ending at
> 
> https://codereview.qt-project.org/c/qt/qtbase/+/351595/3
> 
> in case anyone wants to give it a swing. MultiSelection is not changed yet, and it looks like we might get away with a minimal change for ExtendedSelection.
> 
> There’s no intention to bring those changes to Qt 5.
> 
> Volker
> 
> 
>> On 28 May 2021, at 19:01, Elvis Stansvik <elvstone at gmail.com> wrote:
>> 
>> Yea man, just change it. No one remembers a coward! :)
>> 
>> Den fre 28 maj 2021 kl 17:07 skrev David M. Cotter <dave at kjams.com>:
>>> 
>>> assuming your change "does the right thing in all cases" then i think it should be the default.
>>> 
>>> nobody WANTS the currently-bad behavior.
>>> 
>>> -dave
>>> 
>>>> On May 28, 2021, at 5:55 AM, Volker Hilsheimer <volker.hilsheimer at qt.io> wrote:
>>>> 
>>>> Cross-posting from the development mailing list in case any of you have a strong opinion about this.
>>>> 
>>>> Volker
>>>> 
>>>> 
>>>>> On 28 May 2021, at 13:10, Volker Hilsheimer <volker.hilsheimer at qt.io> wrote:
>>>>> 
>>>>> Hey Widget fans,
>>>>> 
>>>>> I need your opinions on https://bugreports.qt.io/browse/QTBUG-59888
>>>>> 
>>>>> The UX resulting from our (strange) choice to trigger selection changes on mouse press rather than mouse release is indeed quite horrible, as explained in the ticket.
>>>>> 
>>>>> The options to fix that seem to be:
>>>>> 
>>>>> 1) change the default behavior - always change selection on mouse release
>>>>> 2) change the default behavior if drag (as per dragDropMode)
>>>>> 3) make the "selection trigger" a property
>>>>> 
>>>>> None of those options would IMHO result in a change that qualifies for stable branches. I’ve for now implemented option 3. This introduces new API, so if we agree that this is the way to go then it would ideally be merged before 6.2 feature freeze next Friday.
>>>>> 
>>>>> https://codereview.qt-project.org/c/qt/qtbase/+/351595
>>>>> 
>>>>> However, the possible property values seem oddly specific to this problem, and give that this is a 6.2 only change anyway, perhaps it would be best to simply change the default, which would then also make Qt matching native UIs better (ie Windows Explorer or macOS Finder)?
>>>>> 
>>>>> Cheers,
>>>>> Volker
>>>>> 
>>>>> _______________________________________________
>>>>> Development mailing list
>>>>> Development at qt-project.org
>>>>> https://lists.qt-project.org/listinfo/development
>>>> 
>>>> _______________________________________________
>>>> Interest mailing list
>>>> Interest at qt-project.org
>>>> https://lists.qt-project.org/listinfo/interest
>>> 
>>> _______________________________________________
>>> Interest mailing list
>>> Interest at qt-project.org
>>> https://lists.qt-project.org/listinfo/interest
>> _______________________________________________
>> Interest mailing list
>> Interest at qt-project.org
>> https://lists.qt-project.org/listinfo/interest
> 
> _______________________________________________
> Interest mailing list
> Interest at qt-project.org
> https://lists.qt-project.org/listinfo/interest



More information about the Interest mailing list