Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CMake tools default keybinding conflicts with default editor keybinding #1170

Closed
mtrp12 opened this issue Apr 11, 2020 · 7 comments
Closed
Assignees
Labels
bug a bug in the product Feature: debug/launch fixed (release pending) fixed in pre-release and is pending official release
Milestone

Comments

@mtrp12
Copy link

mtrp12 commented Apr 11, 2020

Brief Issue Summary

image

vscode cmake tools out of the box key binding does contradictory action compared to the editor keybinding. As a result, breakpoint triggers even if I select run without debug from editor menu. Also, debugging started from editor using launch.json does not end after pressing SHIFT+f5(editor default). Instead it runs cmake tools: run without debugging. While I can rebind the keys, I think default keybindings should not conflict with main editor defaults. In my observation, I noticed cmake tools keybinding is overriding editor keybinding. If that is so, it should have the same keybinding for same task as main editor. Alternatively, a non conflicting keybinding.

Expected:

Editor keybindings to work.

Apparent Behavior:

CMake tools key binding triggers

Platform and Versions

  • Operating System: Ubuntu 18.04
  • CMake Version: 3.10
  • VSCode Version: 1.44.0
  • CMake Tools Extension Version: 1.3.1
  • Compiler/Toolchain: gcc7.4
@bobbrow
Copy link
Member

bobbrow commented Apr 14, 2020

That is a problem. The tricky thing about this is that (I think) this extension was using the keybinding before VS Code was, so changing it now could confuse our existing users. We currently employ a strategy to enable this keybinding only when a CMake project is open in the editor.

The fix for SHIFT+F5 is simple though. It just needs to add logic to not be active during a debug session.

@bobbrow bobbrow added bug a bug in the product Feature: debug/launch labels Apr 14, 2020
@bobbrow bobbrow self-assigned this Apr 14, 2020
@bobbrow bobbrow added this to the 1.4.0 milestone Apr 14, 2020
@bobbrow bobbrow added the fixed (release pending) fixed in pre-release and is pending official release label Apr 16, 2020
@ghuser404
Copy link

@bobbrow I think anyone coming from the VS background, expects F5 to start with debugger and Ctrl+F5 to start without debugger. It's very unfortunate that the defaults are mixed, and I hope they can be changed at some point.

@andreeis
Copy link
Contributor

CMake Tools 1.4.0 Beta is available on GitHub.
https://github.com/microsoft/vscode-cmake-tools/releases/tag/1.4.0-beta

Please try it out and let us know if you encounter any issues.

@andreeis
Copy link
Contributor

This fix is available in CMake Tools #1.4.0 which has been released.

@marcomeyerVFX
Copy link

doesn't work for me, it looks like the change was undone by another commit 52b4ccf

@bobbrow
Copy link
Member

bobbrow commented May 21, 2020

☹️ @andreeis can you add !inDebugMode condition back to the shift+f5 keybinding in package.json?

@bobbrow bobbrow reopened this May 21, 2020
@bobbrow bobbrow modified the milestones: 1.4.0, 1.4.1 May 21, 2020
@bobbrow bobbrow removed the fixed (release pending) fixed in pre-release and is pending official release label May 21, 2020
@andreeis andreeis added the fixed (release pending) fixed in pre-release and is pending official release label Jun 9, 2020
@andreeis
Copy link
Contributor

This should be fixed in CMake Tools 1.4.1 which was published today.
Let us know if you encounter any issues with this release.

@github-actions github-actions bot locked and limited conversation to collaborators Jan 29, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug a bug in the product Feature: debug/launch fixed (release pending) fixed in pre-release and is pending official release
Projects
None yet
Development

No branches or pull requests

5 participants