I noticed that I can't get menu strip hotkeys work properly on Windows (10), while they do work perfectly fine on other platforms I've tried. Under windows some hotkeys just don't get triggered when pressing Ctrl+hotkey. Menu entries themselves do work if selected with the mouse.
Here's an example:
Code: Select all
MENU 1, {
{"First menu", {
{"test1", ID = "test1", Hotkey = "1"},
{"test2", ID = "test2", Hotkey = "2"}}},
{"Second menu", {
{"test3", ID = "test3", Hotkey = "3"},
{"test4", ID = "test4", Hotkey = "4"}}},
{"Third menu", {
{"test5", ID = "test5", Hotkey = "5"},
{"test6", ID = "test6", Hotkey = "6"}}}
}
@DISPLAY {Menu = 1}
NPrint("Try these hotkeys with the ctrl key: 1 2 3 4 5 6")
InstallEventHandler({OnMenuSelect=Function(msg) NPrint(msg.Action, msg.Item) EndFunction})
Repeat
WaitEvent
Forever
When I run that under Windows and try to press ctrl-1, ctrl-2, etc, only 5 and 6 do work, 1-4 just don't trigger the event. If I remove the third menu, then items in the second menu do work. So it looks here that only the items in the last menu do work, but I think it's the case only with this certain example. I had another kind of menu structure, and there the working keys felt more random... didn't save it but can try to re-create it if needed.