// GUIMessageBox.h: interface for the CGUIMessageBox class. // ////////////////////////////////////////////////////////////////////// #if !defined(AFX_GUIMESSAGEBOX_H__F81A1529_1603_4C04_94BF_02E10D1898E7__INCLUDED_) #define AFX_GUIMESSAGEBOX_H__F81A1529_1603_4C04_94BF_02E10D1898E7__INCLUDED_ #if _MSC_VER > 1000 #pragma once #endif // _MSC_VER > 1000 #include #include #include "GUIButton.h" using namespace std; #define MB_NORMAL 0x00000000 #define MB_EXIT 0x00000001 #define MB_CONFIRM 0x00000002 #define MB_CANCEL 0x00000004 #define MB_YES 0x00000008 #define MB_NO 0x00000010 #define MB_PREV 0x00000020 #define MB_NEXT 0x00000040 #define MB_NUMBER 0x00000080 #define MB_STRING 0x00000100 class CGUIMessageBox { typedef struct WORDNode { unsigned long m_dwNum; BOOL m_bFirstLink; vector m_lstMessage; } WORDNode, *LPWORDNode; public: unsigned long *m_lpResultValue; TLVertex m_Vertexes[16]; unsigned short m_wIndex[54]; unsigned long *m_lpValue; char *m_lpstrValue; CGUIButton m_btnButton[5]; CSprite m_spNumber; vector m_lstMessage; CGUIMessageBox *m_lpParent; long m_lTick; float m_fPosX, m_fPosY; RECT m_rcRect; BOOL m_bWordBreak; BOOL m_bShow; unsigned long m_dwFlag; BOOL m_bEnableEnter; CGUIMessageBox(); ~CGUIMessageBox(); void Create(const char *strMessage, unsigned long dwFlag = MB_NORMAL, float posX = 248.0f, float posY = 200.0f); BOOL ShowDialog(unsigned long dwChrID, unsigned long dwPage); void Destroy(); void SetWordBreak(BOOL bWordBreak) { m_bWordBreak = bWordBreak; } void SetEnableEnter(BOOL bEnableEnter) { m_bEnableEnter = bEnableEnter; } void SetResult(unsigned long *lpValue) { m_lpResultValue = lpValue; } void SetValue(unsigned long *lpValue) { m_lpValue = lpValue; } void SetValue(char *lpstrValue) { m_lpstrValue = lpstrValue; } void SetText(const char *strMessage); void SetPosition(float fPosX, float fPosY); //x, y´Â ¸Þ½ÃÁö ¹Ú½ºÀÇ left topÀÌ ¾Æ´Ñ Á¤°¡¿îµ¥Á¡. void Show(BOOL bShow) { m_bShow = bShow; } void SetTimer(long lTick) { m_lTick = lTick; } BOOL Update(float fTick, BOOL &bClick, BOOL bAble); void Render(LPDIRECT3DDEVICE8 lpD3DDevice); }; #endif // !defined(AFX_GUIMESSAGEBOX_H__F81A1529_1603_4C04_94BF_02E10D1898E7__INCLUDED_)