oracle / javavscode

Java platform support for Visual Studio Code for full featured Java development (edit-compile-debug & test cycle)
Apache License 2.0
231 stars 31 forks source link

Please add the CMD + Click function to find the references of the class, object or method #290

Open alexandertsukanov opened 1 month ago

alexandertsukanov commented 1 month ago

Good afternoon. As a user, I want to be able to search for all references of a method or object across the project. Currently, I can achieve the desired behavior by using "right-click > Go to References," but this is not productive for me as a developer.

The same behaviour could be found within next VS Code plugin https://github.com/redhat-developer/vscode-java

Thanks, for your attention, and I am looking forward to your reply.

sid-srini commented 1 month ago

Thanks @alexandertsukanov for your suggestion and we can consider it for a future additional key shortcut.

You may also use shift+F12 for this, which is the default for VS Code itself.

You may also modify your VS Code settings via the keyboard shortcuts editor for setting key shortcuts you prefer. For adding a mouse click to a command's key shortcut, you may use the virtual key VK_LBUTTON.

Please let us know if this helped. Thanks.

alexandertsukanov commented 1 month ago

@sid-srini Actually, I am using macOS. I'm not sure if that is possible here. Additionally, I found another issue related to the mouse keybinding: https://github.com/microsoft/vscode/issues/3130

So, any suggestions will be appreciated.

sid-srini commented 1 month ago

@sid-srini Actually, I am using macOS. I'm not sure if that is possible here. Additionally, I found another issue related to the mouse keybinding: microsoft/vscode#3130

So, any suggestions will be appreciated.

Yes, you are right that VS Code on macOS does not seem to support virtual keys for mouse-binding.

You may still continue to use shift+F12 or any other keyboard-only shortcut that you find more productive. The function keys on macOS are normally activated using the Fn key, but you may configure macOS System Preferences to use them (or show them in the Touch Bar) by default.