linuxmint / nemo

File browser for Cinnamon
GNU General Public License v2.0
1.24k stars 300 forks source link

List view: Selecting files using Ctrl+click and then Shift+click makes weird selections (Shift+second-last-clicked...) #2773

Open SebastJava opened 3 years ago

SebastJava commented 3 years ago
 * Nemo version: 4.8.6
 * Issue with windowed nemo
 * Distribution: Mint 20.1
 * Graphics:  Device-1: Intel 2nd Generation Core Processor Family Integrated Graphics driver: i915 v: kernel 
           Display: x11 server: X.Org 1.20.9 driver: modesetting unloaded: fbdev,vesa resolution: 1920x1080~60Hz 
           OpenGL: renderer: Mesa DRI Intel HD Graphics 2000 (SNB GT1) v: 3.3 Mesa 20.2.6
 * 64 bit

Issue When selecting files in Nemo using click, then Ctrl-click, and then Shift-click, the resulting selection is... strange.

https://user-images.githubusercontent.com/31940713/122597069-daa62680-d038-11eb-9bd7-4e09398dff0e.mp4

Steps to reproduce

  1. Open some directory where you already have a bunch of files. For clearer descriptions, let's say we have files named Test-00 Test-05 Test-10 Test-15 Test-20 Test-25 Test-30
  2. View > select List View.
  3. Select the Test-00 file, then Ctrl-click the Test-10, then Ctrl-click the Test-20.
  4. Shift-click the Test-30.
  5. See? The resulting selection is: Test-10 to Test-30 being selected. (see screencast)

Expected behaviour I would expect one of the followings:

  1. Shift-click adds the clicked file as well as the ones in between the last clicked one, and the previously selected ones are still there: selected files = 00,10,20,25,30
  2. Shift-click forgets the previous Ctrl-clicks, so only the clicked file, the last clicked one, and the ones in between would be selected: selected files = 20,25,30. That is how it works in the other view modes: Icon or Compact view...

Actual behaviour Shift-click adds all files between the second-last Ctrl-clicked one. So, in this case, files 10,15,20,25,30 are selected... And this is different from the Icon or Compact view behaviours!

Other information That is just one simple example. There are lots of other possible bigger and weirder combinations.

Source This bug was originally reported by Menard on https://forums.linuxmint.com/viewtopic.php?f=47&t=351188 on Thu Jun 17, 2021 9:27 am. It is confirmed by mikeflan and sebastjava.

SebastJava commented 3 years ago

Bump. Let's resume this bug in a simple and clear way...

Say you have 26 files named A,B,C,D,E,F... up to Z You want to select A,C,E, and then all the files from G to M

  1. View > select List View.
  2. Select files A,C,E using click and Ctrl-click.
  3. Try to add all the files from G to M: Ctrl-click on G, then Shift-click on M.

See ? You don't get the expected result. And this result is different from what you would get using the icon view ! At least, the icon view behaves the same way Windows does, as i remember. And i think i could get what i really expected using a Macintosh, but i can't confirm this, because i don't have a Macintosh.

https://user-images.githubusercontent.com/31940713/142945263-7fa77168-f63a-4915-ba25-17564359c5e9.mp4