mirror of
https://github.com/Drezil/imgui.git
synced 2025-07-07 21:39:54 +02:00
IO: Added "Super" keyboard modifiers (corresponding to Cmd on Mac and Windows key in theory although the later is hard to read) (#473)
NB: Value not used.
This commit is contained in:
@ -263,10 +263,10 @@ void ImGui_KeyboardCallback(uSynergyCookie cookie, uint16_t key,
|
||||
// printf("Synergy: keyboard callback: 0x%02X (%s)", scanCode, down?"true":"false");
|
||||
ImGuiIO& io = ImGui::GetIO();
|
||||
io.KeysDown[key] = down;
|
||||
io.KeyShift = modifiers & USYNERGY_MODIFIER_SHIFT;
|
||||
io.KeyCtrl = modifiers & USYNERGY_MODIFIER_CTRL;
|
||||
io.KeyAlt = modifiers & USYNERGY_MODIFIER_ALT;
|
||||
|
||||
io.KeyShift = (modifiers & USYNERGY_MODIFIER_SHIFT);
|
||||
io.KeyCtrl = (modifiers & USYNERGY_MODIFIER_CTRL);
|
||||
io.KeyAlt = (modifiers & USYNERGY_MODIFIER_ALT);
|
||||
io.KeySuper = (modifiers & USYNERGY_MODIFIER_WIN);
|
||||
|
||||
// Add this as keyboard input
|
||||
if ((down) && (key) && (scanCode<256) && !(modifiers & USYNERGY_MODIFIER_CTRL))
|
||||
|
Reference in New Issue
Block a user