Counter Strike : Global Offensive Source Code
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.

62 lines
1.2 KiB

  1. //========= Copyright � 1996-2005, Valve Corporation, All rights reserved. ============//
  2. //
  3. // Purpose:
  4. //
  5. // $NoKeywords: $
  6. //=============================================================================//
  7. #ifndef MXSTATUSWINDOW_H
  8. #define MXSTATUSWINDOW_H
  9. #ifdef _WIN32
  10. #pragma once
  11. #endif
  12. #include "faceposertoolwindow.h"
  13. #include "color.h"
  14. class mxScrollbar;
  15. #define IDC_STATUS_SCROLL 1000
  16. class mxStatusWindow : public mxWindow, public IFacePoserToolWindow
  17. {
  18. public:
  19. mxStatusWindow (mxWindow *parent, int x, int y, int w, int h, const char *label = 0 );
  20. ~mxStatusWindow();
  21. void StatusPrint(const Color& clr, bool overwrite, const char *text );
  22. virtual void DrawActiveTool();
  23. virtual void redraw();
  24. virtual bool PaintBackground( void );
  25. virtual int handleEvent( mxEvent *event );
  26. virtual void Think( float dt );
  27. private:
  28. void PositionSliders( int sboffset );
  29. enum
  30. {
  31. MAX_TEXT_LINES = 1024,
  32. TEXT_LINE_MASK = MAX_TEXT_LINES - 1,
  33. };
  34. struct TextLine
  35. {
  36. char m_szText[ 512 ];
  37. Color rgb;
  38. float curtime;
  39. };
  40. TextLine m_rgTextLines[ MAX_TEXT_LINES ];
  41. int m_nCurrentLine;
  42. mxScrollbar *m_pScrollbar;
  43. };
  44. extern mxStatusWindow *g_pStatusWindow;
  45. #endif // MXSTATUSWINDOW_H