#pragma once

#include "dllinterface.h"
#include "panel.h"
#include "label.h"

class GAMEGUI_API Button : public GUIElement
{	
	Label *m_Caption;
	Panel *m_Image;

	D3DXCOLOR m_NColor,m_AColor,m_IColor;

protected:
	virtual ~Button(void);

public:
	Button(MenuManager*manager,DWORD id);

	virtual void OnUpdate(void);

	void SetTexture(DXTexture*tex);
	void SetCaption(const XString&cap);
	void SetFont(Font*fnt);
	//void SetBorder(float b,float tb);
	void SetFixedBorder(const int border) { m_Image->SetFixedBorder(border); }
	void SetAlphaBlend(bool ab);
	void SetColors(D3DXCOLOR normal,D3DXCOLOR active,D3DXCOLOR inactive){m_NColor = normal;m_AColor = active;m_IColor = inactive;}

	virtual void SetSize(const float xl, const float yl);
};
