How to disable Cmd+W shortcut for Agent tabs?

Cmd+W should only close editor tabs and never Agent chat tabs even if the focus is on chat tab.
Needed in traditional cursor window, not Cursor 3 agents window.

In general it would be so easy if you separate cursor shortcuts from vscode shortcuts. and give option to disable/enable them.

anyone?

Hey, thanks for the request. In the chat tab, Cmd+W triggers a separate command composer.closeComposerTab instead of the standard closeActiveEditor. To disable it, open Keyboard Shortcuts (JSON):

  • Cmd+Shift+PPreferences: Open Keyboard Shortcuts (JSON)
  • Add this to the array:
{
  "key": "cmd+w",
  "command": "-composer.closeComposerTab"
}
  • Save the file.

This will disable Cmd+W only for chat tabs. In normal files, Cmd+W will keep closing the tab as before.