]>
Commit | Line | Data |
---|---|---|
3fa28b58 UJ |
1 | /////////////////////////////////////////////////////////////////////////////// |
2 | // Name: mac/tooltip.h | |
3 | // Purpose: wxToolTip class - tooltip control | |
05adb9d2 | 4 | // Author: Stefan Csomor |
3fa28b58 UJ |
5 | // Modified by: |
6 | // Created: 31.01.99 | |
7 | // RCS-ID: $Id$ | |
05adb9d2 | 8 | // Copyright: (c) 1999 Robert Roebling, Vadim Zeitlin, Stefan Csomor |
371a5b4e | 9 | // Licence: wxWindows licence |
3fa28b58 UJ |
10 | /////////////////////////////////////////////////////////////////////////////// |
11 | ||
12 | ||
3fa28b58 UJ |
13 | class wxToolTip : public wxObject |
14 | { | |
15 | public: | |
16 | // ctor & dtor | |
17 | wxToolTip(const wxString &tip); | |
18 | virtual ~wxToolTip(); | |
19 | ||
20 | // accessors | |
21 | // tip text | |
22 | void SetTip(const wxString& tip); | |
23 | const wxString& GetTip() const { return m_text; } | |
24 | ||
25 | // the window we're associated with | |
26 | void SetWindow(wxWindow *win); | |
27 | wxWindow *GetWindow() const { return m_window; } | |
28 | ||
29 | // controlling tooltip behaviour: globally change tooltip parameters | |
30 | // enable or disable the tooltips globally | |
31 | static void Enable(bool flag); | |
32 | // set the delay after which the tooltip appears | |
33 | static void SetDelay(long milliseconds); | |
5273bf2f | 34 | static void NotifyWindowDelete( WXHWND win ) ; |
3fa28b58 | 35 | |
05adb9d2 SC |
36 | // implementation only from now on |
37 | // ------------------------------- | |
3fa28b58 | 38 | |
05adb9d2 SC |
39 | // should be called in response to mouse events |
40 | static void RelayEvent(wxWindow *win , wxMouseEvent &event); | |
41 | static void RemoveToolTips(); | |
3fa28b58 | 42 | |
05adb9d2 | 43 | private: |
3fa28b58 UJ |
44 | wxString m_text; // tooltip text |
45 | wxWindow *m_window; // window we're associated with | |
8481948e | 46 | DECLARE_ABSTRACT_CLASS(wxToolTip) |
3fa28b58 UJ |
47 | }; |
48 |