handle the Apple (command) key with Servoy on Mac OS X

I want to create a shortcut key command by using the windows plugin.

because I hide all the menu’s I dont have CTRL-F (windows) & Apple-F (apple) anymore
So I have this now: plugins.window.createShortcut(‘control F’, ‘globals.core_onFind’);

which works fine, but how do I create the shortcut: Apple-F for Apple?

If I am not mistaken the apple key is the ‘command’ key…

So

plugins.window.createShortcut(‘command F’, ‘globals.core_onFind’);

should work?

do I really need to create 2 two shortcuts? one for windows? one for Apple? or can this be done in one call?

again, if I remember well, command can be used for ‘apple’ on mac and ‘control’ on win. Just try and see :)

Harjo,

I think the command key on the mac is called meta in java keystroke terms.
When you use ‘menu’ in the window plugin, on the mac it will translate to ‘meta’ and on the rest to ‘control’.

plugins.window.createShortcut(‘menu F’, ‘globals.core_onFind’);

Rob

What are the left and right arrow keys called?

Christian,

In the sample code of the createShortcut method you can find a reference to

This tells you that key code name is the the name following “VK_” in the constants definitions which are defined here:

So, the right arrow key is called RIGHT, right?

Rob