Team Fortress 2 Source Code as on 22/4/2020
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

56 lines
1.4 KiB

  1. //========= Copyright Valve Corporation, All rights reserved. ============//
  2. //
  3. // Purpose:
  4. //
  5. // $NoKeywords: $
  6. //=============================================================================//
  7. #ifndef C_CSRootPanel_H
  8. #define C_CSRootPanel_H
  9. #ifdef _WIN32
  10. #pragma once
  11. #endif
  12. #include <vgui_controls/Panel.h>
  13. #include <vgui_controls/EditablePanel.h>
  14. #include "utlvector.h"
  15. class CPanelEffect;
  16. class ITFHintItem;
  17. // Serial under of effect, for safe lookup
  18. typedef unsigned int EFFECT_HANDLE;
  19. //-----------------------------------------------------------------------------
  20. // Purpose: Sits between engine and client .dll panels
  21. // Responsible for drawing screen overlays
  22. //-----------------------------------------------------------------------------
  23. class C_CSRootPanel : public vgui::Panel
  24. {
  25. typedef vgui::Panel BaseClass;
  26. public:
  27. C_CSRootPanel( vgui::VPANEL parent );
  28. virtual ~C_CSRootPanel( void );
  29. // Draw Panel effects here
  30. virtual void PostChildPaint();
  31. // Clear list of Panel Effects
  32. virtual void LevelInit( void );
  33. virtual void LevelShutdown( void );
  34. // Run effects and let them decide whether to remove themselves
  35. void OnTick( void );
  36. private:
  37. // Render all panel effects
  38. void RenderPanelEffects( void );
  39. // List of current panel effects
  40. CUtlVector< CPanelEffect *> m_Effects;
  41. };
  42. extern C_CSRootPanel *g_pTF2RootPanel;
  43. #endif // C_CSRootPanel_H