lsp4intellij icon indicating copy to clipboard operation
lsp4intellij copied to clipboard

Use IntelliJ's "Go To Declaration" configured shortcut instead of CTRL + CLICK

Open JorgeGarciaIrazabal opened this issue 4 years ago • 2 comments

https://github.com/ballerina-platform/lsp4intellij/blob/7683a2ef60677846aee6dff9a78668f432076bd7/src/main/java/org/wso2/lsp4intellij/editor/EditorEventManager.java#L357

Right now, you are using CTRL + CLICK to go to definition (which is the standard) but IntelliJ allows you to configure it and execute it with different commands. Would it be possible to get the configured short cut of the action and map it to trySourceNavigationAndHover?

JorgeGarciaIrazabal avatar Mar 03 '20 20:03 JorgeGarciaIrazabal

@JorgeGarciaIrazabal Thats a good suggestion. I'll check whether IntelliJ has a related API so that we can honor custom key map configurations :) Thanks for bringing this up!

NipunaRanasinghe avatar Mar 11 '20 08:03 NipunaRanasinghe

i think we can possibly inject ourselves here: https://upsource.jetbrains.com/idea-ce/file/idea-ce-4b94ba01122752d7576eb9d69638b6e89d1671b7/platform/analysis-api/src/com/intellij/codeInsight/navigation/actions/GotoDeclarationHandler.java if anyone wants to have a look

Trias avatar Dec 28 '20 15:12 Trias