Added 'Super' virtual key (win-key) and better error-log.

This commit is contained in:
2026-02-10 13:18:55 +01:00
parent 30848e000d
commit ab705a9252
2 changed files with 5 additions and 1 deletions

View File

@@ -42,6 +42,8 @@ Virtual_Key :: enum {
Space, Enter, Escape, Tab, Backspace, CapsLock,
Shift, Control, Alt,
Arrow_Up, Arrow_Down, Arrow_Left, Arrow_Right,
Super,
}
Event_Keyboard :: struct {
virtual_key: Virtual_Key,

View File

@@ -386,8 +386,10 @@ destroy_windows :: proc(window: ^Window) {
case win.VK_RIGHT: return .Arrow_Right
case win.VK_UP: return .Arrow_Up
case win.VK_DOWN: return .Arrow_Down
case win.VK_LWIN, win.VK_RWIN: return .Super
case: {
assert(false)
assert(false, fmt.tprintf("Unhandled key: %v (0x%x)", vk, vk))
}
}