//========= Copyright © 1996-2005, Valve Corporation, All rights reserved. ============// // // Purpose: // // $NoKeywords: $ //=============================================================================// #ifndef HudImagePanel_H #define HudImagePanel_H #ifdef _WIN32 #pragma once #endif #include "hudelement.h" #include #include namespace vgui { class IImage; //----------------------------------------------------------------------------- // Purpose: Panel that holds a single image //----------------------------------------------------------------------------- class HudImagePanel : public CHudElement, public Panel { DECLARE_CLASS_SIMPLE( HudImagePanel, Panel ); public: HudImagePanel(Panel *parent, const char *name); ~HudImagePanel(); virtual void OnThink( void ); virtual void SetImage(const char *imageName); // virtual const char *GetImageName(); // set the color to fill with, if no image is specified void SetFillColor( Color col ); Color GetFillColor(); protected: virtual void PaintBackground( void ); virtual void Paint( void ); private: int m_nImage; char *m_pszImageName; char *m_pszColorName; bool m_bScaleImage; Color m_FillColor; }; } // namespace vgui #endif // HudImagePanel_H