1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: wxTaskBarIcon sample
4 // Author: Julian Smart
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
12 class MyTaskBarIcon
: public wxTaskBarIcon
15 #if defined(__WXCOCOA__)
16 MyTaskBarIcon(wxTaskBarIconType iconType
= DEFAULT_TYPE
)
17 : wxTaskBarIcon(iconType
)
23 void OnLeftButtonDClick(wxTaskBarIconEvent
&);
24 void OnMenuRestore(wxCommandEvent
&);
25 void OnMenuExit(wxCommandEvent
&);
26 void OnMenuSetNewIcon(wxCommandEvent
&);
28 virtual wxMenu
*CreatePopupMenu();
34 // Define a new application
35 class MyApp
: public wxApp
41 class MyDialog
: public wxDialog
44 MyDialog(wxWindow
* parent
, const wxWindowID id
, const wxString
& title
,
45 const wxPoint
& pos
, const wxSize
& size
, const long windowStyle
= wxDEFAULT_DIALOG_STYLE
);
48 void OnOK(wxCommandEvent
& event
);
49 void OnExit(wxCommandEvent
& event
);
50 void OnCloseWindow(wxCloseEvent
& event
);
54 MyTaskBarIcon
*m_taskBarIcon
;
55 #if defined(__WXCOCOA__)
56 MyTaskBarIcon
*m_dockIcon
;