1 // MyWindowsNew.h
2 
3 #ifndef __MY_WINDOWS_NEW_H
4 #define __MY_WINDOWS_NEW_H
5 
6 #ifdef _MSC_VER
7 
8 #include <ShObjIdl.h>
9 
10 #ifndef __ITaskbarList3_INTERFACE_DEFINED__
11 #define __ITaskbarList3_INTERFACE_DEFINED__
12 
13 typedef enum THUMBBUTTONFLAGS
14 {
15   THBF_ENABLED = 0,
16   THBF_DISABLED = 0x1,
17   THBF_DISMISSONCLICK = 0x2,
18   THBF_NOBACKGROUND = 0x4,
19   THBF_HIDDEN = 0x8,
20   THBF_NONINTERACTIVE = 0x10
21 } THUMBBUTTONFLAGS;
22 
23 typedef enum THUMBBUTTONMASK
24 {
25   THB_BITMAP = 0x1,
26   THB_ICON = 0x2,
27   THB_TOOLTIP = 0x4,
28   THB_FLAGS = 0x8
29 } THUMBBUTTONMASK;
30 
31 // #include <pshpack8.h>
32 
33 typedef struct THUMBBUTTON
34 {
35   THUMBBUTTONMASK dwMask;
36   UINT iId;
37   UINT iBitmap;
38   HICON hIcon;
39   WCHAR szTip[260];
40   THUMBBUTTONFLAGS dwFlags;
41 } THUMBBUTTON;
42 
43 typedef struct THUMBBUTTON *LPTHUMBBUTTON;
44 
45 typedef enum TBPFLAG
46 {
47   TBPF_NOPROGRESS = 0,
48   TBPF_INDETERMINATE = 0x1,
49   TBPF_NORMAL = 0x2,
50   TBPF_ERROR = 0x4,
51   TBPF_PAUSED = 0x8
52 } TBPFLAG;
53 
54 DEFINE_GUID(IID_ITaskbarList3, 0xEA1AFB91, 0x9E28, 0x4B86, 0x90, 0xE9, 0x9E, 0x9F, 0x8A, 0x5E, 0xEF, 0xAF);
55 
56 struct ITaskbarList3: public ITaskbarList2
57 {
58   STDMETHOD(SetProgressValue)(HWND hwnd, ULONGLONG ullCompleted, ULONGLONG ullTotal) = 0;
59   STDMETHOD(SetProgressState)(HWND hwnd, TBPFLAG tbpFlags) = 0;
60   STDMETHOD(RegisterTab)(HWND hwndTab, HWND hwndMDI) = 0;
61   STDMETHOD(UnregisterTab)(HWND hwndTab) = 0;
62   STDMETHOD(SetTabOrder)(HWND hwndTab, HWND hwndInsertBefore) = 0;
63   STDMETHOD(SetTabActive)(HWND hwndTab, HWND hwndMDI, DWORD dwReserved) = 0;
64   STDMETHOD(ThumbBarAddButtons)(HWND hwnd, UINT cButtons, LPTHUMBBUTTON pButton) = 0;
65   STDMETHOD(ThumbBarUpdateButtons)(HWND hwnd, UINT cButtons, LPTHUMBBUTTON pButton) = 0;
66   STDMETHOD(ThumbBarSetImageList)(HWND hwnd, HIMAGELIST himl) = 0;
67   STDMETHOD(SetOverlayIcon)(HWND hwnd, HICON hIcon, LPCWSTR pszDescription) = 0;
68   STDMETHOD(SetThumbnailTooltip)(HWND hwnd, LPCWSTR pszTip) = 0;
69   STDMETHOD(SetThumbnailClip)(HWND hwnd, RECT *prcClip) = 0;
70 };
71 
72 #endif
73 
74 #endif
75 
76 #endif
77