1 ///////////////////////////////////////////////////////////////////////////////
2 // Name:        wx/os2/tooltip.h
3 // Purpose:     wxToolTip class - tooltip control
4 // Author:      David Webster
5 // Modified by:
6 // Created:     10/17/99
7 // Copyright:   (c) David Webster
8 // Licence:     wxWindows licence
9 ///////////////////////////////////////////////////////////////////////////////
10 
11 #ifndef _WX_OS2_TOOLTIP_H_
12 #define _WX_OS2_TOOLTIP_H_
13 
14 class wxToolTip : public wxObject
15 {
16 public:
17     // ctor & dtor
18     wxToolTip(const wxString &rsTip);
19     virtual ~wxToolTip();
20 
21     //
22     // Accessors
23     //
GetTip(void)24     inline const wxString& GetTip(void) const { return m_sText; }
GetWindow(void)25     inline wxWindow*       GetWindow(void) const { return m_pWindow; }
26 
27            void            SetTip(const wxString& rsTip);
SetWindow(wxWindow * pWin)28     inline void            SetWindow(wxWindow* pWin) { m_pWindow = pWin; }
29 
30     // controlling tooltip behaviour: globally change tooltip parameters
31         // enable or disable the tooltips globally
Enable(bool WXUNUSED (flag))32     static void Enable(bool WXUNUSED(flag)) {}
33         // set the delay after which the tooltip appears
SetDelay(long WXUNUSED (milliseconds))34     static void SetDelay(long WXUNUSED(milliseconds)) {}
35         // set the delay after which the tooltip disappears or how long the tooltip remains visible
SetAutoPop(long WXUNUSED (milliseconds))36     static void SetAutoPop(long WXUNUSED(milliseconds)) {}
37         // set the delay between subsequent tooltips to appear
SetReshow(long WXUNUSED (milliseconds))38     static void SetReshow(long WXUNUSED(milliseconds)) {}
39 
40     //
41     // Implementation
42     //
43     void DisplayToolTipWindow(const wxPoint& rPos);
44     void HideToolTipWindow(void);
45 
46 private:
47     void Create(const wxString &rsTip);
48 
49     HWND                            m_hWnd;
50     wxString                        m_sText;           // tooltip text
51     wxWindow*                       m_pWindow;         // window we're associated with
52 }; // end of CLASS wxToolTip
53 
54 #endif // _WX_OS2_TOOLTIP_H_
55