aboutsummaryrefslogtreecommitdiff
path: root/sp/src/game/client/vgui_schemevisualizer.h
diff options
context:
space:
mode:
authorJoe Ludwig <[email protected]>2013-06-26 15:22:04 -0700
committerJoe Ludwig <[email protected]>2013-06-26 15:22:04 -0700
commit39ed87570bdb2f86969d4be821c94b722dc71179 (patch)
treeabc53757f75f40c80278e87650ea92808274aa59 /sp/src/game/client/vgui_schemevisualizer.h
downloadsource-sdk-2013-39ed87570bdb2f86969d4be821c94b722dc71179.tar.xz
source-sdk-2013-39ed87570bdb2f86969d4be821c94b722dc71179.zip
First version of the SOurce SDK 2013
Diffstat (limited to 'sp/src/game/client/vgui_schemevisualizer.h')
-rw-r--r--sp/src/game/client/vgui_schemevisualizer.h55
1 files changed, 55 insertions, 0 deletions
diff --git a/sp/src/game/client/vgui_schemevisualizer.h b/sp/src/game/client/vgui_schemevisualizer.h
new file mode 100644
index 00000000..2d876528
--- /dev/null
+++ b/sp/src/game/client/vgui_schemevisualizer.h
@@ -0,0 +1,55 @@
+//========= Copyright Valve Corporation, All rights reserved. ============//
+//
+//=======================================================================================//
+
+#ifndef VGUI_CLIENTSCHEMEVISUALIZER_H
+#define VGUI_CLIENTSCHEMEVISUALIZER_H
+
+//----------------------------------------------------------------------------------------
+
+#include "vgui_controls/Frame.h"
+#include "vgui_controls/PanelListPanel.h"
+
+//----------------------------------------------------------------------------------------
+
+class CSchemeVisualizer : public vgui::Frame
+{
+ DECLARE_CLASS_SIMPLE( CSchemeVisualizer, vgui::Frame );
+
+public:
+ CSchemeVisualizer( vgui::Panel *pParent, vgui::IScheme *pViewScheme, const char *pSchemeName );
+ virtual ~CSchemeVisualizer();
+
+private:
+ virtual void PerformLayout();
+
+private:
+ virtual void OnTick();
+
+ enum ListDataType_t
+ {
+ LISTDATATYPE_INVALID = -1,
+ LISTDATATYPE_BORDERS,
+ LISTDATATYPE_FONTS,
+ LISTDATATYPE_COLORS,
+ NUM_TYPES
+ };
+
+ int m_aComboDataTypeToItemIDMap[NUM_TYPES]; // [ data type ] = < item id >
+
+ void UpdateList( ListDataType_t nType );
+ void AddBordersToList();
+ void AddFontsToList();
+ void AddColorsToList();
+
+ vgui::PanelListPanel *m_pList;
+ ListDataType_t m_nListDataType; // Currently selected data type
+ int m_nSelectedComboItem;
+
+ vgui::IScheme *m_pViewScheme; // The scheme we're visualizing
+ vgui::ComboBox *m_pListDataTypeCombo;
+};
+
+//----------------------------------------------------------------------------------------
+
+#endif // VGUI_CLIENTSCHEMEVISUALIZER_H \ No newline at end of file