Bug 5094 - Code cleanup, patch by Zack Middleton and DevHC. Fixes unused-but-set gcc warnings
This commit is contained in:
parent
1ea7ab1f42
commit
23f6fd1633
85 changed files with 246 additions and 496 deletions
|
@ -82,7 +82,7 @@ static void UI_DisplayDownloadInfo( const char *downloadName ) {
|
|||
downloadCount = trap_Cvar_VariableValue( "cl_downloadCount" );
|
||||
downloadTime = trap_Cvar_VariableValue( "cl_downloadTime" );
|
||||
|
||||
leftWidth = width = UI_ProportionalStringWidth( dlText ) * UI_ProportionalSizeScale( style );
|
||||
leftWidth = UI_ProportionalStringWidth( dlText ) * UI_ProportionalSizeScale( style );
|
||||
width = UI_ProportionalStringWidth( etaText ) * UI_ProportionalSizeScale( style );
|
||||
if (width > leftWidth) leftWidth = width;
|
||||
width = UI_ProportionalStringWidth( xferText ) * UI_ProportionalSizeScale( style );
|
||||
|
|
|
@ -111,20 +111,6 @@ static void Demos_MenuEvent( void *ptr, int event ) {
|
|||
}
|
||||
|
||||
|
||||
/*
|
||||
=================
|
||||
UI_DemosMenu_Key
|
||||
=================
|
||||
*/
|
||||
static sfxHandle_t UI_DemosMenu_Key( int key ) {
|
||||
menucommon_s *item;
|
||||
|
||||
item = Menu_ItemAtCursor( &s_demos.menu );
|
||||
|
||||
return Menu_DefaultKey( &s_demos.menu, key );
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
===============
|
||||
Demos_MenuInit
|
||||
|
@ -137,7 +123,6 @@ static void Demos_MenuInit( void ) {
|
|||
int protocol, protocolLegacy;
|
||||
|
||||
memset( &s_demos, 0 ,sizeof(demos_t) );
|
||||
s_demos.menu.key = UI_DemosMenu_Key;
|
||||
|
||||
Demos_Cache();
|
||||
|
||||
|
|
|
@ -623,7 +623,7 @@ void UI_SPSkillMenu_Cache( void );
|
|||
// ui_syscalls.c
|
||||
//
|
||||
void trap_Print( const char *string );
|
||||
void trap_Error( const char *string );
|
||||
void trap_Error( const char *string ) __attribute__((noreturn));
|
||||
int trap_Milliseconds( void );
|
||||
void trap_Cvar_Register( vmCvar_t *vmCvar, const char *varName, const char *defaultValue, int flags );
|
||||
void trap_Cvar_Update( vmCvar_t *vmCvar );
|
||||
|
|
|
@ -334,7 +334,6 @@ void MenuField_Draw( menufield_s *f )
|
|||
int x;
|
||||
int y;
|
||||
int w;
|
||||
int h;
|
||||
int style;
|
||||
qboolean focus;
|
||||
float *color;
|
||||
|
@ -345,13 +344,11 @@ void MenuField_Draw( menufield_s *f )
|
|||
if (f->generic.flags & QMF_SMALLFONT)
|
||||
{
|
||||
w = SMALLCHAR_WIDTH;
|
||||
h = SMALLCHAR_HEIGHT;
|
||||
style = UI_SMALLFONT;
|
||||
}
|
||||
else
|
||||
{
|
||||
w = BIGCHAR_WIDTH;
|
||||
h = BIGCHAR_HEIGHT;
|
||||
style = UI_BIGFONT;
|
||||
}
|
||||
|
||||
|
|
|
@ -739,13 +739,11 @@ void ArenaServers_LoadFavorites( void )
|
|||
int i;
|
||||
int j;
|
||||
int numtempitems;
|
||||
char emptyinfo[MAX_INFO_STRING];
|
||||
char adrstr[MAX_ADDRESSLENGTH];
|
||||
servernode_t templist[MAX_FAVORITESERVERS];
|
||||
qboolean found;
|
||||
|
||||
found = qfalse;
|
||||
emptyinfo[0] = '\0';
|
||||
|
||||
// copy the old
|
||||
memcpy( templist, g_favoriteserverlist, sizeof(servernode_t)*MAX_FAVORITESERVERS );
|
||||
|
|
|
@ -725,7 +725,6 @@ static void UI_SPLevelMenu_Init( void ) {
|
|||
skill = (int)trap_Cvar_VariableValue( "g_spSkill" );
|
||||
if( skill < 1 || skill > 5 ) {
|
||||
trap_Cvar_Set( "g_spSkill", "2" );
|
||||
skill = 2;
|
||||
}
|
||||
|
||||
memset( &levelMenuInfo, 0, sizeof(levelMenuInfo) );
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue