Sometimes does a rubberband selection instead of initiating DnD when dragging from selected items in listview
Affected version
- Nightly flatpak: Yes
- Other: maybe version 44?
Steps to reproduce
- Select 2 or 3 files in listview mode
- Try to drag them, in any direction, even if your mouse cursor is dead-center over one of the selected items. If the issue doesn't immediately occur, try again until it does (it manifests randomly).
Current behavior
Sometimes it will initiate a drag, sometimes it will initiate a rubberband selection, which replaces/messes up your current selection. This is what it looks like when it happens:
2023-03-12-nautilus-nightly-drag-from-compact-listview-fails
Expected behavior
Always initiate a drag (never rubberband-select) when the mouse cursor is over (or even between) a contiguous range of selected files; not a rubberband selection. If I wanted to replace the selection through rubberbanding, I'd be using the left/right margins of the listview.
Note that you could have the opportunity here to fix two issues at once: this regression, and also the fact that if you click "between" items when trying to initiate a drag (which is quite possible if you're not perfectly accurate in the compact zoom level of listview) then you would again mess up the selection... if the code checked whether the cursor's/click's position is "between the height range of a contiguous selection of items" it could avoid this usability problem as well.
Additional information
- I have tested this on the Xorg/X11 version of GNOME 43, with the nightly flatpak you provide.
- The 43.2 version provided by Fedora 37 does not seem affected, as far as I can tell.
- I use Single-click mode in Nautilus
- It seems to be independent of the zoom level
- Today I experienced this using my ThinkPad's trackpoint (or touchpad) + physical left-click button, but I believe I've also frequently encountered this with a regular external mouse on my other computers, too.