]> git.saurik.com Git - wxWidgets.git/blob - include/wx/msw/taskbar.h
added wxUpdateUI generation
[wxWidgets.git] / include / wx / msw / taskbar.h
1 /////////////////////////////////////////////////////////////////////////
2 // File: taskbar.h
3 // Purpose: Defines wxTaskBarIcon class for manipulating icons on the
4 // Windows task bar.
5 // Author: Julian Smart
6 // Modified by:
7 // Created: 24/3/98
8 // RCS-ID: $Id$
9 // Copyright: (c)
10 // Licence: wxWindows licence
11 /////////////////////////////////////////////////////////////////////////
12
13 #ifndef _TASKBAR_H_
14 #define _TASKBAR_H_
15
16 #ifdef __GNUG__
17 #pragma interface "taskbar.h"
18 #endif
19
20 #include <wx/list.h>
21 #include <wx/icon.h>
22
23 class wxTaskBarIcon: public wxObject
24 {
25 public:
26 wxTaskBarIcon(void);
27 virtual ~wxTaskBarIcon(void);
28
29 // Accessors
30 inline WXHWND GetHWND() const { return m_hWnd; }
31 inline bool IsOK() const { return (m_hWnd != 0) ; }
32 inline bool IsIconInstalled() const { return m_iconAdded; }
33
34 // Operations
35 bool SetIcon(const wxIcon& icon, const wxString& tooltip = "");
36 bool RemoveIcon(void);
37
38 // Overridables
39 virtual void OnMouseMove(void);
40 virtual void OnLButtonDown(void);
41 virtual void OnLButtonUp(void);
42 virtual void OnRButtonDown(void);
43 virtual void OnRButtonUp(void);
44 virtual void OnLButtonDClick(void);
45 virtual void OnRButtonDClick(void);
46
47 // Implementation
48 static wxTaskBarIcon* FindObjectForHWND(WXHWND hWnd);
49 static void AddObject(wxTaskBarIcon* obj);
50 static void RemoveObject(wxTaskBarIcon* obj);
51 static bool RegisterWindowClass();
52 static WXHWND CreateTaskBarWindow();
53 long WindowProc( WXHWND hWnd, unsigned int msg, unsigned int wParam, long lParam );
54
55 // Data members
56 protected:
57 WXHWND m_hWnd;
58 bool m_iconAdded;
59 static wxList sm_taskBarIcons;
60 static bool sm_registeredClass;
61 static unsigned int sm_taskbarMsg;
62 };
63
64 #endif
65 // _TASKBAR_H_
66