Improve keyboard/joystick input in Team Arena UI

Make Yes/No, Multi, Slider, and Bind items allow enter key to change
value without mouse over item. Add support for left and right arrow keys
and joystick button 1-4 to Yes/No, Multi, and Slider and many item
specific 'ownerdraw' key handlers.

Listbox still requires mouse hover and Team Arena main menu requires
mouse hover to get anywhere...

Enabling K_JOY1-4 to select in default key handler also caused additional
mouse button (K_AUX1-16) to select, which is done in q3_ui as well. Both
handle K_AUX equally badly (not treated as a mouse button and not handled
by item specific key handlers), so it's probably fine.
This commit is contained in:
Zack Middleton 2016-05-23 09:06:34 -05:00
parent 6394180224
commit d875c1f03c
3 changed files with 229 additions and 207 deletions

View file

@ -417,6 +417,7 @@ void Menu_Reset( void );
qboolean Menus_AnyFullScreenVisible( void );
void Menus_Activate(menuDef_t *menu);
int UI_SelectForKey(int key);
displayContextDef_t *Display_GetContext( void );
void *Display_CaptureItem(int x, int y);
qboolean Display_MouseMove(void *p, int x, int y);