microsoft / vscode

Visual Studio Code
https://code.visualstudio.com
MIT License
163.61k stars 29.04k forks source link

CTRL + Click and Shift + Click don't work as expected in TreeViews #221551

Closed EhabY closed 3 months ago

EhabY commented 3 months ago

Steps to Reproduce:

  1. Clone https://github.com/microsoft/vscode-extension-samples/tree/main/tree-view-sample
  2. Use the FileExplorer TreeView but make sure to set canSelectMany: true
  3. Try to select multiple nodes by using CTRL + Click and CTRL + Shift (see attached video)

CTRL + Click

it seems when you have a selection already then you press CTRL and click on another node, the first click is ignored (I am pressing CTRL in the whole time here):

https://github.com/user-attachments/assets/30ed308d-fbc4-4a09-8478-d1a42db78ec7

Shift + Click

The same happens for shift where the first click is ignored (or rather the selection is applied then removed quickly) which causes subsequent clicks to produce strange behavior, but also selection are very strange when you have expandable content:

https://github.com/user-attachments/assets/296a065a-d2dd-4c7c-acfc-22641a4de10c

alexr00 commented 3 months ago

Duplicate of https://github.com/microsoft/vscode/issues/208802