From 56824b130b786aab49876a71c6c768a17c5a4f1c Mon Sep 17 00:00:00 2001 From: Simon Howard Date: Fri, 10 Dec 2010 20:31:46 +0000 Subject: Replace txt_widget_t#selectable with a callback function to query whether the widget is selectable. This stops the table code from selecting things that aren't really selectable - eg. empty tables, scrollpanes containing unselectable widgets, etc. Fixes a bug with the warp menu (thanks Proteh). Subversion-branch: /trunk/chocolate-doom Subversion-revision: 2207 --- setup/txt_joybinput.c | 1 + setup/txt_keyinput.c | 1 + setup/txt_mouseinput.c | 1 + 3 files changed, 3 insertions(+) (limited to 'setup') diff --git a/setup/txt_joybinput.c b/setup/txt_joybinput.c index 1e132962..cde3d2c2 100644 --- a/setup/txt_joybinput.c +++ b/setup/txt_joybinput.c @@ -206,6 +206,7 @@ static void TXT_JoystickInputMousePress(TXT_UNCAST_ARG(widget), int x, int y, in txt_widget_class_t txt_joystick_input_class = { + TXT_AlwaysSelectable, TXT_JoystickInputSizeCalc, TXT_JoystickInputDrawer, TXT_JoystickInputKeyPress, diff --git a/setup/txt_keyinput.c b/setup/txt_keyinput.c index 483c325f..08eb9d8c 100644 --- a/setup/txt_keyinput.c +++ b/setup/txt_keyinput.c @@ -171,6 +171,7 @@ static void TXT_KeyInputMousePress(TXT_UNCAST_ARG(widget), int x, int y, int b) txt_widget_class_t txt_key_input_class = { + TXT_AlwaysSelectable, TXT_KeyInputSizeCalc, TXT_KeyInputDrawer, TXT_KeyInputKeyPress, diff --git a/setup/txt_mouseinput.c b/setup/txt_mouseinput.c index 8b87e651..4f454c8c 100644 --- a/setup/txt_mouseinput.c +++ b/setup/txt_mouseinput.c @@ -164,6 +164,7 @@ static void TXT_MouseInputMousePress(TXT_UNCAST_ARG(widget), int x, int y, int b txt_widget_class_t txt_mouse_input_class = { + TXT_AlwaysSelectable, TXT_MouseInputSizeCalc, TXT_MouseInputDrawer, TXT_MouseInputKeyPress, -- cgit v1.2.3