Skip to content

Handle the shortcut key like the meta key#25

Open
jkaving wants to merge 1 commit into
0x4a616e:masterfrom
jkaving:fix-shortcut-keycode
Open

Handle the shortcut key like the meta key#25
jkaving wants to merge 1 commit into
0x4a616e:masterfrom
jkaving:fix-shortcut-keycode

Conversation

@jkaving
Copy link
Copy Markdown

@jkaving jkaving commented Nov 18, 2022

KeyCombination.shortcut is a way to add platform-independent keyboard shortcuts that will e.g. use "Ctrl" on Windows and "Cmd" on macOS (see the Javadoc in javafx.scene.input.KeyCombination).

This commit just adds a check for getShortcut() and sets the NSEventModifierFlagCommand just like is already done for getMeta().

Fixes #24

KeyCombination.shortcut is a way to add platform-independent keyboard
shortcuts that will e.g. use "Ctrl" on Windows and "Cmd" on macOS
(see the Javadoc in javafx.scene.input.KeyCombination).

This commit just adds a check for getShortcut() and sets the
NSEventModifierFlagCommand just like is already done for getMeta().

Fixes 0x4a616e#24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

KeyCode.SHORTCUT not working when adding keyboard accelerators

1 participant