Reputation: 2571
How do i trigger the cmd + click
behaviour (Go to Class, go to declaration etc) in IntelliJ when my current keymap uses Eclipse (MacOS)
?
I'm currently switching from Eclipse/STS to IntelliJ. So far, i've changed the keymap to use Eclipse (MacOS)
, so most of the familiar keyboard shortcuts i use still works.
control + click
does the functionality that i want using Eclipse (MacOS)
keymap but this also triggers system behaviour of right click, so menu pops out the same time that the go to class/variable triggers. Is there a way i can set or use cmd + click
to trigger the desired behavior?
Upvotes: 1
Views: 656
Reputation: 4772
Go to Preferences > Keymap
.
You have to copy the Eclipse (MacOS)
keymap to a new name, in order to make changes: select the Eclipse (MacOS)
keymap, press the Copy
button and give it a new name, e.g. Eclipse (MacOS) 2
.
Then click into the filter field, enter declaration
, then in the tree area do right-click on the Main menu > Navigate > Declaration
line in order to activate the context menu. The result should look like this:
Select Add Mouse Shortcut
from the context menu, a dialog opens. Perform into this dialog the key + click combination you wish to add, in your case cmd + click
:
Confirm the new Mouse shortcut with Ok
, then close the Preferences
dialog also with Ok
or Apply
. Done.
Note: you can delete the ctrl + click
mouse shortcut, if you wish to not use it by mistake, by selecting Remove ^Button1 Click
in the context menu.
Upvotes: 4