summaryrefslogtreecommitdiff
path: root/src/ui/ui_shared.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/ui/ui_shared.c')
-rw-r--r--src/ui/ui_shared.c190
1 files changed, 94 insertions, 96 deletions
diff --git a/src/ui/ui_shared.c b/src/ui/ui_shared.c
index 8d6d3635..8351f6fd 100644
--- a/src/ui/ui_shared.c
+++ b/src/ui/ui_shared.c
@@ -129,7 +129,7 @@ UI_Alloc
*/
void *UI_Alloc( int size )
{
- char * p;
+ char *p;
if( allocPoint + size > MEM_POOL_SIZE )
{
@@ -387,7 +387,7 @@ Float_Parse
*/
qboolean Float_Parse( char **p, float *f )
{
- char * token;
+ char *token;
token = COM_ParseExt( p, qfalse );
if( token && token[0] != 0 )
@@ -749,7 +749,7 @@ Int_Parse
*/
qboolean Int_Parse( char **p, int *i )
{
- char * token;
+ char *token;
token = COM_ParseExt( p, qfalse );
if( token && token[0] != 0 )
@@ -860,7 +860,7 @@ String_Parse
*/
qboolean String_Parse( char **p, const char **out )
{
- char * token;
+ char *token;
token = COM_ParseExt( p, qfalse );
@@ -1331,7 +1331,7 @@ itemDef_t *Menu_GetMatchingItemByNumber( menuDef_t *menu, int index, const char
void Script_SetColor( itemDef_t *item, char **args )
{
- const char * name;
+ const char *name;
int i;
float f;
vec4_t *out;
@@ -1369,7 +1369,7 @@ void Script_SetColor( itemDef_t *item, char **args )
void Script_SetAsset( itemDef_t *item, char **args )
{
- const char * name;
+ const char *name;
// expecting name to set asset to
if( String_Parse( args, &name ) )
@@ -1385,7 +1385,7 @@ void Script_SetAsset( itemDef_t *item, char **args )
void Script_SetBackground( itemDef_t *item, char **args )
{
- const char * name;
+ const char *name;
// expecting name to set asset to
if( String_Parse( args, &name ) )
@@ -1413,7 +1413,7 @@ itemDef_t *Menu_FindItemByName( menuDef_t *menu, const char *p )
void Script_SetItemColor( itemDef_t *item, char **args )
{
- const char * itemname;
+ const char *itemname;
const char *name;
vec4_t color;
int i;
@@ -1577,7 +1577,7 @@ void Menus_CloseAll( qboolean force )
void Script_Show( itemDef_t *item, char **args )
{
- const char * name;
+ const char *name;
if( String_Parse( args, &name ) )
Menu_ShowItemByName( item->parent, name, qtrue );
@@ -1585,7 +1585,7 @@ void Script_Show( itemDef_t *item, char **args )
void Script_Hide( itemDef_t *item, char **args )
{
- const char * name;
+ const char *name;
if( String_Parse( args, &name ) )
Menu_ShowItemByName( item->parent, name, qfalse );
@@ -1593,7 +1593,7 @@ void Script_Hide( itemDef_t *item, char **args )
void Script_FadeIn( itemDef_t *item, char **args )
{
- const char * name;
+ const char *name;
if( String_Parse( args, &name ) )
Menu_FadeItemByName( item->parent, name, qfalse );
@@ -1601,7 +1601,7 @@ void Script_FadeIn( itemDef_t *item, char **args )
void Script_FadeOut( itemDef_t *item, char **args )
{
- const char * name;
+ const char *name;
if( String_Parse( args, &name ) )
Menu_FadeItemByName( item->parent, name, qtrue );
@@ -1611,7 +1611,7 @@ void Script_FadeOut( itemDef_t *item, char **args )
void Script_Open( itemDef_t *item, char **args )
{
- const char * name;
+ const char *name;
if( String_Parse( args, &name ) )
Menus_ActivateByName( name );
@@ -1619,7 +1619,7 @@ void Script_Open( itemDef_t *item, char **args )
void Script_ConditionalOpen( itemDef_t *item, char **args )
{
- const char * cvar;
+ const char *cvar;
const char *name1;
const char *name2;
float val;
@@ -1637,7 +1637,7 @@ void Script_ConditionalOpen( itemDef_t *item, char **args )
void Script_Close( itemDef_t *item, char **args )
{
- const char * name;
+ const char *name;
if( String_Parse( args, &name ) )
Menus_CloseByName( name );
@@ -1646,7 +1646,7 @@ void Script_Close( itemDef_t *item, char **args )
void Menu_TransitionItemByName( menuDef_t *menu, const char *p, rectDef_t rectFrom, rectDef_t rectTo,
int time, float amt )
{
- itemDef_t * item;
+ itemDef_t *item;
int i;
int count = Menu_ItemsMatchingGroup( menu, p );
@@ -1672,7 +1672,7 @@ void Menu_TransitionItemByName( menuDef_t *menu, const char *p, rectDef_t rectFr
void Script_Transition( itemDef_t *item, char **args )
{
- const char * name;
+ const char *name;
rectDef_t rectFrom, rectTo;
int time;
float amt;
@@ -1690,7 +1690,7 @@ void Script_Transition( itemDef_t *item, char **args )
void Menu_OrbitItemByName( menuDef_t *menu, const char *p, float x, float y, float cx, float cy, int time )
{
- itemDef_t * item;
+ itemDef_t *item;
int i;
int count = Menu_ItemsMatchingGroup( menu, p );
@@ -1714,7 +1714,7 @@ void Menu_OrbitItemByName( menuDef_t *menu, const char *p, float x, float y, flo
void Script_Orbit( itemDef_t *item, char **args )
{
- const char * name;
+ const char *name;
float cx, cy, x, y;
int time;
@@ -1732,7 +1732,7 @@ void Script_Orbit( itemDef_t *item, char **args )
void Script_SetFocus( itemDef_t *item, char **args )
{
- const char * name;
+ const char *name;
itemDef_t *focusItem;
if( String_Parse( args, &name ) )
@@ -1762,7 +1762,7 @@ void Script_SetFocus( itemDef_t *item, char **args )
void Script_Reset( itemDef_t *item, char **args )
{
- const char * name;
+ const char *name;
itemDef_t *resetItem;
if( String_Parse( args, &name ) )
@@ -1784,7 +1784,7 @@ void Script_Reset( itemDef_t *item, char **args )
void Script_SetPlayerModel( itemDef_t *item, char **args )
{
- const char * name;
+ const char *name;
if( String_Parse( args, &name ) )
DC->setCVar( "team_model", name );
@@ -1792,7 +1792,7 @@ void Script_SetPlayerModel( itemDef_t *item, char **args )
void Script_SetPlayerHead( itemDef_t *item, char **args )
{
- const char * name;
+ const char *name;
if( String_Parse( args, &name ) )
DC->setCVar( "team_headmodel", name );
@@ -1800,7 +1800,7 @@ void Script_SetPlayerHead( itemDef_t *item, char **args )
void Script_SetCvar( itemDef_t *item, char **args )
{
- const char * cvar, *val;
+ const char *cvar, *val;
if( String_Parse( args, &cvar ) && String_Parse( args, &val ) )
DC->setCVar( cvar, val );
@@ -1809,7 +1809,7 @@ void Script_SetCvar( itemDef_t *item, char **args )
void Script_Exec( itemDef_t *item, char **args )
{
- const char * val;
+ const char *val;
if( String_Parse( args, &val ) )
DC->executeText( EXEC_APPEND, va( "%s ; ", val ) );
@@ -1817,7 +1817,7 @@ void Script_Exec( itemDef_t *item, char **args )
void Script_Play( itemDef_t *item, char **args )
{
- const char * val;
+ const char *val;
if( String_Parse( args, &val ) )
DC->startLocalSound( DC->registerSound( val, qfalse ), CHAN_LOCAL_SOUND );
@@ -1825,7 +1825,7 @@ void Script_Play( itemDef_t *item, char **args )
void Script_playLooped( itemDef_t *item, char **args )
{
- const char * val;
+ const char *val;
if( String_Parse( args, &val ) )
{
@@ -1966,7 +1966,7 @@ static void UI_Text_PaintChar( float x, float y, float width, float height,
}
void UI_Text_Paint_Limit( float *maxX, float x, float y, float scale,
- vec4_t color, const char* text, float adjust, int limit )
+ vec4_t color, const char *text, float adjust, int limit )
{
int len, count;
vec4_t newColor;
@@ -1974,7 +1974,7 @@ void UI_Text_Paint_Limit( float *maxX, float x, float y, float scale,
if( text )
{
- const char * s = text;
+ const char *s = text;
float max = *maxX;
float useScale;
fontInfo_t *font = &DC->Assets.textFont;
@@ -2059,7 +2059,7 @@ void UI_Text_Paint( float x, float y, float scale, vec4_t color, const char *tex
if( text )
{
- const char * s = text;
+ const char *s = text;
DC->setColor( color );
memcpy( &newColor[0], &color[0], sizeof( vec4_t ) );
len = strlen( text );
@@ -2394,7 +2394,7 @@ void Item_RunScript( itemDef_t *item, const char *s )
while( 1 )
{
- const char * command;
+ const char *command;
// expect command then arguments, ; ends command, NULL ends script
if( !String_Parse( &p, &command ) )
@@ -2438,7 +2438,7 @@ qboolean Item_EnableShowViaCvar( itemDef_t *item, int flag )
while( 1 )
{
- const char * val;
+ const char *val;
// expect value then ; or NULL, NULL ends list
if( !String_Parse( &p, &val ) )
@@ -2554,7 +2554,7 @@ qboolean Item_SetFocus( itemDef_t *item, float x, float y )
int Item_ListBox_MaxScroll( itemDef_t *item )
{
- listBoxDef_t * listPtr = ( listBoxDef_t* )item->typeData;
+ listBoxDef_t *listPtr = ( listBoxDef_t* )item->typeData;
int count = DC->feederCount( item->special );
int max;
@@ -2929,7 +2929,7 @@ qboolean Item_OwnerDraw_HandleKey( itemDef_t *item, int key )
qboolean Item_ListBox_HandleKey( itemDef_t *item, int key, qboolean down, qboolean force )
{
- listBoxDef_t * listPtr = ( listBoxDef_t* )item->typeData;
+ listBoxDef_t *listPtr = ( listBoxDef_t* )item->typeData;
int count = DC->feederCount( item->special );
int max, viewmax;
@@ -3248,7 +3248,7 @@ qboolean Item_YesNo_HandleKey( itemDef_t *item, int key )
int Item_Multi_CountSettings( itemDef_t *item )
{
- multiDef_t * multiPtr = ( multiDef_t* )item->typeData;
+ multiDef_t *multiPtr = ( multiDef_t* )item->typeData;
if( multiPtr == NULL )
return 0;
@@ -3358,7 +3358,7 @@ qboolean Item_Combobox_HandleKey( itemDef_t *item, int key )
qboolean Item_Multi_HandleKey( itemDef_t *item, int key )
{
- multiDef_t * multiPtr = ( multiDef_t* )item->typeData;
+ multiDef_t *multiPtr = ( multiDef_t* )item->typeData;
qboolean mouseOver = Rect_ContainsPoint( &item->window.rect, DC->cursorx, DC->cursory );
int max = Item_Multi_CountSettings( item );
qboolean changed = qfalse;
@@ -3409,7 +3409,7 @@ qboolean Item_Multi_HandleKey( itemDef_t *item, int key )
static void Item_TextField_CalcPaintOffset( itemDef_t *item, char *buff )
{
- editFieldDef_t * editPtr = ( editFieldDef_t* )item->typeData;
+ editFieldDef_t *editPtr = ( editFieldDef_t* )item->typeData;
if( item->cursorPos < editPtr->paintOffset )
editPtr->paintOffset = item->cursorPos;
@@ -3608,7 +3608,7 @@ exit:
static void Scroll_ListBox_AutoFunc( void *p )
{
- scrollInfo_t * si = ( scrollInfo_t* )p;
+ scrollInfo_t *si = ( scrollInfo_t* )p;
if( DC->realTime > si->nextScrollTime )
{
@@ -3630,7 +3630,7 @@ static void Scroll_ListBox_AutoFunc( void *p )
static void Scroll_ListBox_ThumbFunc( void *p )
{
- scrollInfo_t * si = ( scrollInfo_t* )p;
+ scrollInfo_t *si = ( scrollInfo_t* )p;
rectDef_t r;
int pos, max;
@@ -3792,7 +3792,7 @@ qboolean Item_Slider_HandleKey( itemDef_t *item, int key, qboolean down )
{
if( key == K_MOUSE1 || key == K_ENTER || key == K_MOUSE2 || key == K_MOUSE3 )
{
- editFieldDef_t * editDef = item->typeData;
+ editFieldDef_t *editDef = item->typeData;
if( editDef )
{
@@ -4045,7 +4045,7 @@ void Menus_Activate( menuDef_t *menu )
{
if( menu->items[ i ]->type == ITEM_TYPE_LISTBOX )
{
- listBoxDef_t * listPtr = ( listBoxDef_t* )menu->items[ i ]->typeData;
+ listBoxDef_t *listPtr = ( listBoxDef_t* )menu->items[ i ]->typeData;
menu->items[ i ]->cursorPos = 0;
listPtr->startPos = 0;
DC->feederSelection( menu->items[ i ]->special, 0 );
@@ -4344,7 +4344,7 @@ void Rect_ToWindowCoords( rectDef_t *rect, windowDef_t *window )
void Item_SetTextExtents( itemDef_t *item, int *width, int *height, const char *text )
{
- const char * textPtr = ( text ) ? text : item->text;
+ const char *textPtr = ( text ) ? text : item->text;
if( textPtr == NULL )
return;
@@ -4568,7 +4568,7 @@ static int cacheReadLineNum = 0;
static void UI_CreateCacheEntry( const char *text, rectDef_t *rect, float scale )
{
- wrapCache_t * cacheEntry = &wrapCache[ cacheWriteIndex ];
+ wrapCache_t *cacheEntry = &wrapCache[ cacheWriteIndex ];
Q_strncpyz( cacheEntry->text, text, sizeof( cacheEntry->text ) );
cacheEntry->rect.x = rect->x;
@@ -4581,7 +4581,7 @@ static void UI_CreateCacheEntry( const char *text, rectDef_t *rect, float scale
static void UI_AddCacheEntryLine( const char *text, float x, float y )
{
- wrapCache_t * cacheEntry = &wrapCache[ cacheWriteIndex ];
+ wrapCache_t *cacheEntry = &wrapCache[ cacheWriteIndex ];
if( cacheEntry->numLines >= MAX_WRAP_LINES )
return;
@@ -4635,7 +4635,7 @@ static qboolean UI_CheckWrapCache( const char *text, rectDef_t *rect, float scal
static qboolean UI_NextWrapLine( const char **text, float *x, float *y )
{
- wrapCache_t * cacheEntry = &wrapCache[ cacheReadIndex ];
+ wrapCache_t *cacheEntry = &wrapCache[ cacheReadIndex ];
if( cacheReadLineNum >= cacheEntry->numLines )
return qfalse;
@@ -5046,16 +5046,14 @@ typedef struct
int bind1;
int bind2;
}
-
bind_t;
typedef struct
{
- char* name;
+ char *name;
float defaultvalue;
float value;
}
-
configcvar_t;
@@ -5857,7 +5855,7 @@ void Item_ListBox_Paint( itemDef_t *item )
void Item_OwnerDraw_Paint( itemDef_t *item )
{
- menuDef_t * parent;
+ menuDef_t *parent;
const char *text;
if( item == NULL )
@@ -6259,7 +6257,7 @@ void Menu_SetFeederSelection( menuDef_t *menu, int feeder, int index, const char
{
if( index == 0 )
{
- listBoxDef_t * listPtr = ( listBoxDef_t* )menu->items[i]->typeData;
+ listBoxDef_t *listPtr = ( listBoxDef_t* )menu->items[i]->typeData;
listPtr->cursorPos = 0;
listPtr->startPos = 0;
}
@@ -6535,7 +6533,7 @@ void KeywordHash_Add( keywordHash_t *table[], keywordHash_t *key )
keywordHash_t *KeywordHash_Find( keywordHash_t *table[], char *keyword )
{
- keywordHash_t * key;
+ keywordHash_t *key;
int hash;
hash = KeywordHash_Key( keyword );
@@ -6567,7 +6565,7 @@ qboolean ItemParse_name( itemDef_t *item, int handle )
// name <string>
qboolean ItemParse_focusSound( itemDef_t *item, int handle )
{
- const char * temp;
+ const char *temp;
if( !PC_String_Parse( handle, &temp ) )
return qfalse;
@@ -6598,7 +6596,7 @@ qboolean ItemParse_group( itemDef_t *item, int handle )
// asset_model <string>
qboolean ItemParse_asset_model( itemDef_t *item, int handle )
{
- const char * temp;
+ const char *temp;
modelDef_t *modelPtr;
Item_ValidateTypeData( item );
modelPtr = ( modelDef_t* )item->typeData;
@@ -6614,7 +6612,7 @@ qboolean ItemParse_asset_model( itemDef_t *item, int handle )
// asset_shader <string>
qboolean ItemParse_asset_shader( itemDef_t *item, int handle )
{
- const char * temp;
+ const char *temp;
if( !PC_String_Parse( handle, &temp ) )
return qfalse;
@@ -6626,7 +6624,7 @@ qboolean ItemParse_asset_shader( itemDef_t *item, int handle )
// model_origin <number> <number> <number>
qboolean ItemParse_model_origin( itemDef_t *item, int handle )
{
- modelDef_t * modelPtr;
+ modelDef_t *modelPtr;
Item_ValidateTypeData( item );
modelPtr = ( modelDef_t* )item->typeData;
@@ -6645,7 +6643,7 @@ qboolean ItemParse_model_origin( itemDef_t *item, int handle )
// model_fovx <number>
qboolean ItemParse_model_fovx( itemDef_t *item, int handle )
{
- modelDef_t * modelPtr;
+ modelDef_t *modelPtr;
Item_ValidateTypeData( item );
modelPtr = ( modelDef_t* )item->typeData;
@@ -6658,7 +6656,7 @@ qboolean ItemParse_model_fovx( itemDef_t *item, int handle )
// model_fovy <number>
qboolean ItemParse_model_fovy( itemDef_t *item, int handle )
{
- modelDef_t * modelPtr;
+ modelDef_t *modelPtr;
Item_ValidateTypeData( item );
modelPtr = ( modelDef_t* )item->typeData;
@@ -6671,7 +6669,7 @@ qboolean ItemParse_model_fovy( itemDef_t *item, int handle )
// model_rotation <integer>
qboolean ItemParse_model_rotation( itemDef_t *item, int handle )
{
- modelDef_t * modelPtr;
+ modelDef_t *modelPtr;
Item_ValidateTypeData( item );
modelPtr = ( modelDef_t* )item->typeData;
@@ -6684,7 +6682,7 @@ qboolean ItemParse_model_rotation( itemDef_t *item, int handle )
// model_angle <integer>
qboolean ItemParse_model_angle( itemDef_t *item, int handle )
{
- modelDef_t * modelPtr;
+ modelDef_t *modelPtr;
Item_ValidateTypeData( item );
modelPtr = ( modelDef_t* )item->typeData;
@@ -6731,7 +6729,7 @@ qboolean ItemParse_decoration( itemDef_t *item, int handle )
// notselectable
qboolean ItemParse_notselectable( itemDef_t *item, int handle )
{
- listBoxDef_t * listPtr;
+ listBoxDef_t *listPtr;
Item_ValidateTypeData( item );
listPtr = ( listBoxDef_t* )item->typeData;
@@ -6744,7 +6742,7 @@ qboolean ItemParse_notselectable( itemDef_t *item, int handle )
// noscrollbar
qboolean ItemParse_noscrollbar( itemDef_t *item, int handle )
{
- listBoxDef_t * listPtr;
+ listBoxDef_t *listPtr;
Item_ValidateTypeData( item );
listPtr = ( listBoxDef_t* )item->typeData;
@@ -6783,7 +6781,7 @@ qboolean ItemParse_type( itemDef_t *item, int handle )
// uses textalignx for storage
qboolean ItemParse_elementwidth( itemDef_t *item, int handle )
{
- listBoxDef_t * listPtr;
+ listBoxDef_t *listPtr;
Item_ValidateTypeData( item );
listPtr = ( listBoxDef_t* )item->typeData;
@@ -6798,7 +6796,7 @@ qboolean ItemParse_elementwidth( itemDef_t *item, int handle )
// uses textaligny for storage
qboolean ItemParse_elementheight( itemDef_t *item, int handle )
{
- listBoxDef_t * listPtr;
+ listBoxDef_t *listPtr;
Item_ValidateTypeData( item );
listPtr = ( listBoxDef_t* )item->typeData;
@@ -6822,7 +6820,7 @@ qboolean ItemParse_feeder( itemDef_t *item, int handle )
// uses textstyle for storage
qboolean ItemParse_elementtype( itemDef_t *item, int handle )
{
- listBoxDef_t * listPtr;
+ listBoxDef_t *listPtr;
Item_ValidateTypeData( item );
@@ -7032,7 +7030,7 @@ qboolean ItemParse_outlinecolor( itemDef_t *item, int handle )
qboolean ItemParse_background( itemDef_t *item, int handle )
{
- const char * temp;
+ const char *temp;
if( !PC_String_Parse( handle, &temp ) )
return qfalse;
@@ -7051,7 +7049,7 @@ qboolean ItemParse_cinematic( itemDef_t *item, int handle )
qboolean ItemParse_doubleClick( itemDef_t *item, int handle )
{
- listBoxDef_t * listPtr;
+ listBoxDef_t *listPtr;
Item_ValidateTypeData( item );
@@ -7148,7 +7146,7 @@ qboolean ItemParse_cvarTest( itemDef_t *item, int handle )
qboolean ItemParse_cvar( itemDef_t *item, int handle )
{
- editFieldDef_t * editPtr;
+ editFieldDef_t *editPtr;
Item_ValidateTypeData( item );
@@ -7168,7 +7166,7 @@ qboolean ItemParse_cvar( itemDef_t *item, int handle )
qboolean ItemParse_maxChars( itemDef_t *item, int handle )
{
- editFieldDef_t * editPtr;
+ editFieldDef_t *editPtr;
int maxChars;
Item_ValidateTypeData( item );
@@ -7186,7 +7184,7 @@ qboolean ItemParse_maxChars( itemDef_t *item, int handle )
qboolean ItemParse_maxPaintChars( itemDef_t *item, int handle )
{
- editFieldDef_t * editPtr;
+ editFieldDef_t *editPtr;
int maxChars;
Item_ValidateTypeData( item );
@@ -7204,7 +7202,7 @@ qboolean ItemParse_maxPaintChars( itemDef_t *item, int handle )
qboolean ItemParse_maxFieldWidth( itemDef_t *item, int handle )
{
- editFieldDef_t * editPtr;
+ editFieldDef_t *editPtr;
int maxFieldWidth;
Item_ValidateTypeData( item );
@@ -7229,7 +7227,7 @@ qboolean ItemParse_maxFieldWidth( itemDef_t *item, int handle )
qboolean ItemParse_cvarFloat( itemDef_t *item, int handle )
{
- editFieldDef_t * editPtr;
+ editFieldDef_t *editPtr;
Item_ValidateTypeData( item );
@@ -7578,7 +7576,7 @@ void Item_InitControls( itemDef_t *item )
if( item->type == ITEM_TYPE_LISTBOX )
{
- listBoxDef_t * listPtr = ( listBoxDef_t* )item->typeData;
+ listBoxDef_t *listPtr = ( listBoxDef_t* )item->typeData;
item->cursorPos = 0;
if( listPtr )
@@ -7599,7 +7597,7 @@ Menu Keyword Parse functions
qboolean MenuParse_font( itemDef_t *item, int handle )
{
- menuDef_t * menu = ( menuDef_t* )item;
+ menuDef_t *menu = ( menuDef_t* )item;
if( !PC_String_Parse( handle, &menu->font ) )
return qfalse;
@@ -7615,7 +7613,7 @@ qboolean MenuParse_font( itemDef_t *item, int handle )
qboolean MenuParse_name( itemDef_t *item, int handle )
{
- menuDef_t * menu = ( menuDef_t* )item;
+ menuDef_t *menu = ( menuDef_t* )item;
if( !PC_String_Parse( handle, &menu->window.name ) )
return qfalse;
@@ -7625,7 +7623,7 @@ qboolean MenuParse_name( itemDef_t *item, int handle )
qboolean MenuParse_fullscreen( itemDef_t *item, int handle )
{
- menuDef_t * menu = ( menuDef_t* )item;
+ menuDef_t *menu = ( menuDef_t* )item;
if( !PC_Int_Parse( handle, ( int* ) & menu->fullScreen ) )
return qfalse;
@@ -7635,7 +7633,7 @@ qboolean MenuParse_fullscreen( itemDef_t *item, int handle )
qboolean MenuParse_rect( itemDef_t *item, int handle )
{
- menuDef_t * menu = ( menuDef_t* )item;
+ menuDef_t *menu = ( menuDef_t* )item;
if( !PC_Rect_Parse( handle, &menu->window.rect ) )
return qfalse;
@@ -7645,7 +7643,7 @@ qboolean MenuParse_rect( itemDef_t *item, int handle )
qboolean MenuParse_aspectBias( itemDef_t *item, int handle )
{
- menuDef_t * menu = ( menuDef_t* )item;
+ menuDef_t *menu = ( menuDef_t* )item;
if( !PC_Int_Parse( handle, &menu->window.aspectBias ) )
return qfalse;
@@ -7655,7 +7653,7 @@ qboolean MenuParse_aspectBias( itemDef_t *item, int handle )
qboolean MenuParse_style( itemDef_t *item, int handle )
{
- menuDef_t * menu = ( menuDef_t* )item;
+ menuDef_t *menu = ( menuDef_t* )item;
if( !PC_Int_Parse( handle, &menu->window.style ) )
return qfalse;
@@ -7693,7 +7691,7 @@ qboolean MenuParse_dontCloseAll( itemDef_t *item, int handle )
qboolean MenuParse_onOpen( itemDef_t *item, int handle )
{
- menuDef_t * menu = ( menuDef_t* )item;
+ menuDef_t *menu = ( menuDef_t* )item;
if( !PC_Script_Parse( handle, &menu->onOpen ) )
return qfalse;
@@ -7703,7 +7701,7 @@ qboolean MenuParse_onOpen( itemDef_t *item, int handle )
qboolean MenuParse_onClose( itemDef_t *item, int handle )
{
- menuDef_t * menu = ( menuDef_t* )item;
+ menuDef_t *menu = ( menuDef_t* )item;
if( !PC_Script_Parse( handle, &menu->onClose ) )
return qfalse;
@@ -7713,7 +7711,7 @@ qboolean MenuParse_onClose( itemDef_t *item, int handle )
qboolean MenuParse_onESC( itemDef_t *item, int handle )
{
- menuDef_t * menu = ( menuDef_t* )item;
+ menuDef_t *menu = ( menuDef_t* )item;
if( !PC_Script_Parse( handle, &menu->onESC ) )
return qfalse;
@@ -7725,7 +7723,7 @@ qboolean MenuParse_onESC( itemDef_t *item, int handle )
qboolean MenuParse_border( itemDef_t *item, int handle )
{
- menuDef_t * menu = ( menuDef_t* )item;
+ menuDef_t *menu = ( menuDef_t* )item;
if( !PC_Int_Parse( handle, &menu->window.border ) )
return qfalse;
@@ -7735,7 +7733,7 @@ qboolean MenuParse_border( itemDef_t *item, int handle )
qboolean MenuParse_borderSize( itemDef_t *item, int handle )
{
- menuDef_t * menu = ( menuDef_t* )item;
+ menuDef_t *menu = ( menuDef_t* )item;
if( !PC_Float_Parse( handle, &menu->window.borderSize ) )
return qfalse;
@@ -7832,7 +7830,7 @@ qboolean MenuParse_disablecolor( itemDef_t *item, int handle )
qboolean MenuParse_outlinecolor( itemDef_t *item, int handle )
{
- menuDef_t * menu = ( menuDef_t* )item;
+ menuDef_t *menu = ( menuDef_t* )item;
if( !PC_Color_Parse( handle, &menu->window.outlineColor ) )
return qfalse;
@@ -7842,7 +7840,7 @@ qboolean MenuParse_outlinecolor( itemDef_t *item, int handle )
qboolean MenuParse_background( itemDef_t *item, int handle )
{
- const char * buff;
+ const char *buff;
menuDef_t *menu = ( menuDef_t* )item;
if( !PC_String_Parse( handle, &buff ) )
@@ -7854,7 +7852,7 @@ qboolean MenuParse_background( itemDef_t *item, int handle )
qboolean MenuParse_cinematic( itemDef_t *item, int handle )
{
- menuDef_t * menu = ( menuDef_t* )item;
+ menuDef_t *menu = ( menuDef_t* )item;
if( !PC_String_Parse( handle, &menu->window.cinematicName ) )
return qfalse;
@@ -7876,7 +7874,7 @@ qboolean MenuParse_ownerdrawFlag( itemDef_t *item, int handle )
qboolean MenuParse_ownerdraw( itemDef_t *item, int handle )
{
- menuDef_t * menu = ( menuDef_t* )item;
+ menuDef_t *menu = ( menuDef_t* )item;
if( !PC_Int_Parse( handle, &menu->window.ownerDraw ) )
return qfalse;
@@ -7888,7 +7886,7 @@ qboolean MenuParse_ownerdraw( itemDef_t *item, int handle )
// decoration
qboolean MenuParse_popup( itemDef_t *item, int handle )
{
- menuDef_t * menu = ( menuDef_t* )item;
+ menuDef_t *menu = ( menuDef_t* )item;
menu->window.flags |= WINDOW_POPUP;
return qtrue;
}
@@ -7896,7 +7894,7 @@ qboolean MenuParse_popup( itemDef_t *item, int handle )
qboolean MenuParse_outOfBounds( itemDef_t *item, int handle )
{
- menuDef_t * menu = ( menuDef_t* )item;
+ menuDef_t *menu = ( menuDef_t* )item;
menu->window.flags |= WINDOW_OOB_CLICK;
return qtrue;
@@ -7904,7 +7902,7 @@ qboolean MenuParse_outOfBounds( itemDef_t *item, int handle )
qboolean MenuParse_soundLoop( itemDef_t *item, int handle )
{
- menuDef_t * menu = ( menuDef_t* )item;
+ menuDef_t *menu = ( menuDef_t* )item;
if( !PC_String_Parse( handle, &menu->soundName ) )
return qfalse;
@@ -7914,7 +7912,7 @@ qboolean MenuParse_soundLoop( itemDef_t *item, int handle )
qboolean MenuParse_fadeClamp( itemDef_t *item, int handle )
{
- menuDef_t * menu = ( menuDef_t* )item;
+ menuDef_t *menu = ( menuDef_t* )item;
if( !PC_Float_Parse( handle, &menu->fadeClamp ) )
return qfalse;
@@ -7924,7 +7922,7 @@ qboolean MenuParse_fadeClamp( itemDef_t *item, int handle )
qboolean MenuParse_fadeAmount( itemDef_t *item, int handle )
{
- menuDef_t * menu = ( menuDef_t* )item;
+ menuDef_t *menu = ( menuDef_t* )item;
if( !PC_Float_Parse( handle, &menu->fadeAmount ) )
return qfalse;
@@ -7935,7 +7933,7 @@ qboolean MenuParse_fadeAmount( itemDef_t *item, int handle )
qboolean MenuParse_fadeCycle( itemDef_t *item, int handle )
{
- menuDef_t * menu = ( menuDef_t* )item;
+ menuDef_t *menu = ( menuDef_t* )item;
if( !PC_Int_Parse( handle, &menu->fadeCycle ) )
return qfalse;
@@ -7946,7 +7944,7 @@ qboolean MenuParse_fadeCycle( itemDef_t *item, int handle )
qboolean MenuParse_itemDef( itemDef_t *item, int handle )
{
- menuDef_t * menu = ( menuDef_t* )item;
+ menuDef_t *menu = ( menuDef_t* )item;
if( menu->itemCount < MAX_MENUITEMS )
{
@@ -8068,7 +8066,7 @@ Menu_New
*/
void Menu_New( int handle )
{
- menuDef_t * menu = &Menus[menuCount];
+ menuDef_t *menu = &Menus[menuCount];
if( menuCount < MAX_MENUS )
{
@@ -8192,7 +8190,7 @@ int Display_CursorType( int x, int y )
void Display_HandleKey( int key, qboolean down, int x, int y )
{
- menuDef_t * menu = Display_CaptureItem( x, y );
+ menuDef_t *menu = Display_CaptureItem( x, y );
if( menu == NULL )
menu = Menu_GetFocused();