diff options
Diffstat (limited to '')
-rw-r--r-- | src/T2DLL/T2DlgItem.h | 67 |
1 files changed, 67 insertions, 0 deletions
diff --git a/src/T2DLL/T2DlgItem.h b/src/T2DLL/T2DlgItem.h new file mode 100644 index 0000000..ee0ffdf --- /dev/null +++ b/src/T2DLL/T2DlgItem.h @@ -0,0 +1,67 @@ +#pragma once +#include "common.h" +#include "LBroadcaster.h" + +class T2DlgItem : public CWnd, private LBroadcaster { +protected: + T2DlgItem(); +public: + T2DlgItem(T2TowerDoc*, T2ImageObj*, CPalette*); + virtual ~T2DlgItem(); +public: + virtual BOOL Create(const char* windowName, DWORD style, const RECT& rect, CWnd* parentWnd, UINT nId); + virtual void SetFont(HFONT font); + virtual void CreateSubItem(void*); + virtual void SetValue(int value); + virtual int GetValue(); + virtual void GetDescriptor(CString& outStr) const; + virtual void SetDescriptor(const CString& str); +protected: + virtual void PostNcDestroy(); + virtual void DestroySelf(); + virtual T2BitImage* GetObjectImage(RECT&, const char*, int, int, int, int) const; + + virtual int OnT2DlgItemEraseBkgnd(CDC*); + virtual void OnT2DlgItemLButtonDown(UINT nFlags, CPoint pt); + virtual void OnT2DlgItemLButtonUp(UINT nFlags, CPoint pt); + virtual void OnT2DlgItemRButtonDown(UINT nFlags, CPoint pt); + virtual void OnT2DlgItemRButtonUp(UINT nFlags, CPoint pt); + virtual void OnT2DlgItemMouseMove(UINT nFlags, CPoint pt); + virtual void OnT2DlgItemEnable(int); + virtual int OnT2DlgItemCreate(CREATESTRUCT*); + virtual void OnT2Size(UINT nType, int cx, int cy); + virtual void OnT2SetFocus(CWnd* wnd); + virtual void OnT2KillFocus(CWnd* wnd); + virtual void OnT2Timer(UINT id); + virtual void OnT2Close(); + + int OnEraseBkgnd(CDC*); + void OnLButtonDown(UINT nFlags, CPoint pt); + void OnLButtonUp(UINT nFlags, CPoint pt); + void OnRButtonDown(UINT nFlags, CPoint pt); + void OnRButtonUp(UINT nFlags, CPoint pt); + void OnMouseMove(UINT nFlags, CPoint pt); + void OnEnable(int); + int OnCreate(CREATESTRUCT*); + void Notify(unsigned short, void*); + void Notify(unsigned short, unsigned short, void*); + int GetPattern() const; + void SetPattern(int pattern); + void OnSize(UINT nType, int cx, int cy); + void OnSetFocus(CWnd* wnd); + void OnKillFocus(CWnd* wnd); + void OnTimer(UINT id); + void OnClose(); + + DECLARE_MESSAGE_MAP() + +protected: + T2TowerDoc *mTowerDoc; + T2ImageObj *mImageObj; + CPalette *mPalette; + int m74; + HFONT mFont; + int m7C; + int mValue; + int mPattern; +}; |