mirror of
https://github.com/nillerusr/source-engine.git
synced 2024-12-22 06:06:50 +00:00
serverbrowser: copy gametype to map name in quicklist
This commit is contained in:
parent
e10f29854e
commit
e4f5549cbd
@ -165,16 +165,16 @@ void CQuickListPanel::SetMapName( const char *pMapName )
|
|||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
void CQuickListPanel::SetGameType( const char *pGameType )
|
void CQuickListPanel::SetGameType( const char *pGameType )
|
||||||
{
|
{
|
||||||
if ( strlen ( pGameType ) == 0 )
|
m_pGameTypeLabel->SetVisible( false );
|
||||||
{
|
|
||||||
m_pGameTypeLabel->SetVisible( false );
|
if ( strlen ( pGameType ) == 0 || !m_pMapNameLabel )
|
||||||
return;
|
return;
|
||||||
}
|
|
||||||
|
|
||||||
char gametype[ 512 ];
|
char gametype[ 512 ];
|
||||||
Q_snprintf( gametype, sizeof( gametype ), "(%s)", pGameType );
|
Q_snprintf( gametype, sizeof( gametype ), "%s (%s)", m_szMapName, pGameType );
|
||||||
|
|
||||||
m_pGameTypeLabel->SetText( gametype );
|
m_pMapNameLabel->SetText( gametype );
|
||||||
|
m_pMapNameLabel->SizeToContents();
|
||||||
}
|
}
|
||||||
|
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
|
Loading…
Reference in New Issue
Block a user