]> git.saurik.com Git - wxWidgets.git/blob - include/wx/generic/notifmsg.h
Fix wxOSX warnings about int-to-void* casts.
[wxWidgets.git] / include / wx / generic / notifmsg.h
1 ///////////////////////////////////////////////////////////////////////////////
2 // Name: wx/generic/notifmsg.h
3 // Purpose: generic implementation of wxGenericNotificationMessage
4 // Author: Vadim Zeitlin
5 // Created: 2007-11-24
6 // Copyright: (c) 2007 Vadim Zeitlin <vadim@wxwindows.org>
7 // Licence: wxWindows licence
8 ///////////////////////////////////////////////////////////////////////////////
9
10 #ifndef _WX_GENERIC_NOTIFMSG_H_
11 #define _WX_GENERIC_NOTIFMSG_H_
12
13 class wxNotificationMessageDialog;
14
15 // ----------------------------------------------------------------------------
16 // wxGenericNotificationMessage
17 // ----------------------------------------------------------------------------
18
19 class WXDLLIMPEXP_ADV wxGenericNotificationMessage : public wxNotificationMessageBase
20 {
21 public:
22 wxGenericNotificationMessage() { Init(); }
23 wxGenericNotificationMessage(const wxString& title,
24 const wxString& message = wxString(),
25 wxWindow *parent = NULL,
26 int flags = wxICON_INFORMATION)
27 : wxNotificationMessageBase(title, message, parent, flags)
28 {
29 Init();
30 }
31
32 virtual ~wxGenericNotificationMessage();
33
34
35 virtual bool Show(int timeout = Timeout_Auto);
36 virtual bool Close();
37
38 // generic implementation-specific methods
39
40 // get/set the default timeout (used if Timeout_Auto is specified)
41 static int GetDefaultTimeout() { return ms_timeout; }
42 static void SetDefaultTimeout(int timeout);
43
44 private:
45 void Init();
46
47
48 // default timeout
49 static int ms_timeout;
50
51 // notification message is represented by a modeless dialog in this
52 // implementation
53 wxNotificationMessageDialog *m_dialog;
54
55
56 wxDECLARE_NO_COPY_CLASS(wxGenericNotificationMessage);
57 };
58
59 #endif // _WX_GENERIC_NOTIFMSG_H_
60