12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970 |
- #ifndef __TITLE_TIP__
- #define __TITLE_TIP__
- #define TITLETIP_CLASSNAME _T("ZTitleTip")
- class CTitleTip : public CWnd
- {
-
- public:
- CTitleTip();
- virtual ~CTitleTip();
- virtual BOOL Create(CWnd *pParentWnd);
-
- public:
- void SetParentWnd(CWnd* pParentWnd) { m_pParentWnd = pParentWnd; }
- CWnd* GetParentWnd() { return m_pParentWnd; }
-
- public:
- void Show(CRect rectTitle, LPCTSTR lpszTitleText,
- int xoffset = 0, LPRECT lpHoverRect = NULL,
- const LOGFONT* lpLogFont = NULL,
- COLORREF crTextClr = CLR_DEFAULT, COLORREF crBackClr = CLR_DEFAULT);
- void Hide();
-
-
-
- public:
- virtual BOOL PreTranslateMessage(MSG* pMsg);
- virtual BOOL DestroyWindow();
-
-
- protected:
- CWnd *m_pParentWnd;
- CRect m_rectTitle;
- CRect m_rectHover;
- DWORD m_dwLastLButtonDown;
- DWORD m_dwDblClickMsecs;
- BOOL m_bCreated;
-
- protected:
-
- afx_msg void OnMouseMove(UINT nFlags, CPoint point);
-
- DECLARE_MESSAGE_MAP()
- };
- #endif
|