diff options
| author | FluorescentCIAAfricanAmerican <[email protected]> | 2020-04-22 12:56:21 -0400 |
|---|---|---|
| committer | FluorescentCIAAfricanAmerican <[email protected]> | 2020-04-22 12:56:21 -0400 |
| commit | 3bf9df6b2785fa6d951086978a3e66f49427166a (patch) | |
| tree | 2c0f1f0c63c4832882bc93814ebd2c2b1c6224e5 /game/client/dod/VGUI/dodteammenu.h | |
| download | archived-source-engine-2018-hl2-src-master.tar.xz archived-source-engine-2018-hl2-src-master.zip | |
Diffstat (limited to 'game/client/dod/VGUI/dodteammenu.h')
| -rw-r--r-- | game/client/dod/VGUI/dodteammenu.h | 67 |
1 files changed, 67 insertions, 0 deletions
diff --git a/game/client/dod/VGUI/dodteammenu.h b/game/client/dod/VGUI/dodteammenu.h new file mode 100644 index 0000000..6df7bc1 --- /dev/null +++ b/game/client/dod/VGUI/dodteammenu.h @@ -0,0 +1,67 @@ +//========= Copyright Valve Corporation, All rights reserved. ============// +// +// Purpose: +// +// $NoKeywords: $ +//=============================================================================// + +#ifndef DODTEAMMENU_H +#define DODTEAMMENU_H +#ifdef _WIN32 +#pragma once +#endif + +#include "teammenu.h" +#include "dodmenubackground.h" +#include "dodbutton.h" +#include "dodmouseoverpanelbutton.h" +#include "IconPanel.h" + +//----------------------------------------------------------------------------- +// Purpose: Displays the team menu +//----------------------------------------------------------------------------- +class CDODTeamMenu : public CTeamMenu +{ +private: + DECLARE_CLASS_SIMPLE( CDODTeamMenu, CTeamMenu ); + +public: + CDODTeamMenu(IViewPort *pViewPort); + ~CDODTeamMenu(); + + virtual void Update(); + virtual void OnTick(); + void ShowPanel( bool bShow ); + virtual void SetVisible( bool state ); + + virtual void PaintBackground(); + virtual Panel *CreateControlByName( const char *controlName ); + + virtual void ApplySchemeSettings( IScheme *pScheme ); + + virtual void OnKeyCodePressed(KeyCode code); + +private: + enum { NUM_TEAMS = 3 }; + + MESSAGE_FUNC_CHARPTR( OnShowPage, "ShowPage", page ); + + // VGUI2 override + void OnCommand( const char *command); + // helper functions + void SetVisibleButton(const char *textEntryName, bool state); + + CDODMenuBackground *m_pBackground; + + vgui::EditablePanel *m_pPanel; + + CDODMouseOverButton<vgui::EditablePanel> *m_pFirstButton; + + int m_iLastPlayerCount; + + int m_iActiveTeam; + + ButtonCode_t m_iTeamMenuKey; +}; + +#endif // DODTEAMMENU_H |