vscode icon indicating copy to clipboard operation
vscode copied to clipboard

Do you trust the authors of the files in this folder? prompt blocks cmd-w from closing window

Open jsoref opened this issue 10 months ago • 2 comments

Type: Bug

  1. Use code . to open VS Code to an untrusted folder
  2. Wait for VS Code to open a new window to the folder and show the Do you trust the authors of the files in this folder? prompt
  3. Focus window Image
  4. press cmd-w VS Code version: Code 1.97.0 (Universal) (33fc5a94a3f99ebe7087e8fe79fbe1d37a251016, 2025-02-04T22:41:26.688Z) OS version: Darwin arm64 24.3.0 Modes: Restricted
System Info
Item Value
CPUs Apple M1 Max (10 x 2400)
GPU Status 2d_canvas: enabled
canvas_oop_rasterization: enabled_on
direct_rendering_display_compositor: disabled_off_ok
gpu_compositing: enabled
multiple_raster_threads: enabled_on
opengl: enabled_on
rasterization: enabled
raw_draw: disabled_off_ok
skia_graphite: disabled_off
video_decode: enabled
video_encode: enabled
webgl: enabled
webgl2: enabled
webgpu: enabled
webnn: disabled_off
Load (avg) 9, 10, 9
Memory (System) 64.00GB (0.07GB free)
Process Argv --crash-reporter-id 1fc67ee2-0174-4598-9f98-4537df0dd32c
Screen Reader no
VM 0%
Extensions (7)
Extension Author (truncated) Version
vscode-intelephense-client bme 1.12.6
intelli-php-vscode DEV 0.12.15062
dhall-lang dha 0.0.4
vscode-pull-request-github Git 0.105.2025021010
go gol 0.44.0
vscode-xml red 0.27.2
simple-rst tro 1.5.4
A/B Experiments
vsliv368:30146709
vspor879:30202332
vspor708:30202333
vspor363:30204092
vswsl492:30256859
vscod805cf:30301675
binariesv615:30325510
vsaa593:30376534
py29gd2263:31024239
c4g48928:30535728
azure-dev_surveyone:30548225
vscrp:30673768
962ge761:30959799
h48ei257:31000450
pythontbext0:30879054
cppperfnew:31000557
dwnewjupytercf:31046870
nativerepl2:31139839
pythonrstrctxt:31112756
nativeloc2:31192216
iacca1:31171482
5fd0e150:31155592
dwcopilot:31170013
stablechunks:31184530
6074i472:31201624
dwoutputscf:31233691
5a9hg449:31230677
hdaa2157:31222309
copilot_t_ci:31222730
jda6j935:31233686

jsoref avatar Feb 10 '25 14:02 jsoref

This is as designed; the trust dialog functions as a modal dialog and all modal dialogs prevent closing the window with cmd+w. E.g. opening the "About" page.

sbatten avatar Feb 12 '25 20:02 sbatten

That dialog doesn't have a close widget. But it does respond to <Escape>.

This one is just some sort of dialog tied within a window and the window does have a close widget (red gem). If you want a truly modal button that shouldn't respond to cmd-w, get rid of the red gem in the window.

jsoref avatar Feb 12 '25 21:02 jsoref

Coming here from a duplicate issue!

That dialog doesn't have a close widget. But it does respond to <Escape>.

This seems to be false for me. I cannot find any way to dismiss the modal using the keyboard.

This causes an accessibility issue, as it means I can get into a situation using a keyboard that I can't resolve using the keyboard. It's mostly harmless, but unfortunately it's very annoying and adds cognitive overload because nothing else in macOS behaves this way.

lgarron avatar Dec 11 '25 02:12 lgarron