(bindingName string, keyCode sdl.Keycode, mods ...sdl.Keycode)
| 423 | } |
| 424 | |
| 425 | func (kb *Keybindings) DefineKeyShortcut(bindingName string, keyCode sdl.Keycode, mods ...sdl.Keycode) *Shortcut { |
| 426 | sc := NewShortcut(bindingName) |
| 427 | sc.SetKeys(keyCode, mods...) |
| 428 | kb.Shortcuts[bindingName] = sc |
| 429 | kb.ShortcutsInOrder = append(kb.ShortcutsInOrder, sc) |
| 430 | return sc |
| 431 | } |
| 432 | |
| 433 | func (kb *Keybindings) DefineMouseShortcut(bindingName string, mouseButton uint8) *Shortcut { |
| 434 | sc := NewShortcut(bindingName) |
no test coverage detected