From 8f759de26ac1a17676f3937019804b3a9a972e35 Mon Sep 17 00:00:00 2001 From: Tim Angus Date: Sun, 15 Nov 2009 01:10:27 +0000 Subject: * s/ITEM_TYPE_COMBO/ITEM_TYPE_CYCLE/ * Add ITEM_TYPE_COMBOBOX -- a proper combobox widget * Use ITEM_TYPE_COMBOBOX for video mode selection * General refactoring of the listbox code * Various other assorted tidy-ups --- assets/ui/ingame_options.menu | 33 +++++++++++++++++++++++++++------ 1 file changed, 27 insertions(+), 6 deletions(-) (limited to 'assets/ui/ingame_options.menu') diff --git a/assets/ui/ingame_options.menu b/assets/ui/ingame_options.menu index 62aec9b7..ad601938 100644 --- a/assets/ui/ingame_options.menu +++ b/assets/ui/ingame_options.menu @@ -24,6 +24,8 @@ #define SCONTENT_W (W-(SIDEBUTT_W+(2*BORDER))) #define SCONTENT_OFF (0-(SCONTENT_W/2)) +#define RESCOMBO_OFF 8 + #define ELEM_H 16 menuDef @@ -1585,17 +1587,36 @@ { name ghardware group optionsGrp - type ITEM_TYPE_COMBO + type ITEM_TYPE_TEXT text "Video Mode:" - feeder FEEDER_RESOLUTIONS - rect SCONTENT_X (SCONTENT_Y+(2*ELEM_H)) SCONTENT_W ELEM_H + rect SCONTENT_X (SCONTENT_Y+(2*ELEM_H)) (SCONTENT_W/2) ELEM_H textalign ALIGN_RIGHT textvalign VALIGN_CENTER - textalignx SCONTENT_OFF textscale .25 forecolor 1 1 1 1 - visible MENU_FALSE - action + visible MENU_TRUE + } + + itemDef + { + name ghardware + group optionsGrp + rect (SCONTENT_X+(SCONTENT_W/2)+RESCOMBO_OFF) (SCONTENT_Y+(2*ELEM_H)) ((SCONTENT_W/2)-(2*RESCOMBO_OFF)) ELEM_H + type ITEM_TYPE_COMBOBOX + style WINDOW_STYLE_FILLED + elementwidth ((SCONTENT_W/2)-(2*BORDER)) + elementheight ELEM_H + dropitems 5 + textscale .25 + elementtype LISTBOX_TEXT + feeder FEEDER_RESOLUTIONS + border WINDOW_BORDER_FULL + borderColor 0.5 0.5 0.5 1 + forecolor 1 1 1 1 + backcolor 0 0 0 1 + outlinecolor 0.1 0.1 0.1 0.5 + visible MENU_TRUE + doubleclick { play "sound/misc/menu1.wav"; } -- cgit