[MC] Add messages 4400-4440 to netmsg.dll.
[reactos.git] / sdk / include / psdk / commoncontrols.idl
1 /*
2 * Common controls v6 interface definitions
3 *
4 * Copyright 2009 Owen Rudge for CodeWeavers
5 *
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License as published by the Free Software Foundation; either
9 * version 2.1 of the License, or (at your option) any later version.
10 *
11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Lesser General Public License for more details.
15 *
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with this library; if not, write to the Free Software
18 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
19 */
20
21 import "oaidl.idl";
22 import "ocidl.idl";
23
24 /* Definitions required for widl, but already defined in commctrl.h for C */
25 cpp_quote("#if 0")
26 typedef DWORD RGBQUAD;
27 typedef IUnknown* HIMAGELIST;
28
29 typedef struct
30 {
31 HBITMAP hbmImage;
32 HBITMAP hbmMask;
33 int Unused1;
34 int Unused2;
35 RECT rcImage;
36 } IMAGEINFO;
37
38 typedef IMAGEINFO* LPIMAGEINFO;
39
40 typedef struct
41 {
42 DWORD cbSize;
43 HIMAGELIST himl;
44 int i;
45 HDC hdcDst;
46 int x;
47 int y;
48 int cx;
49 int cy;
50 int xBitmap;
51 int yBitmap;
52 COLORREF rgbBk;
53 COLORREF rgbFg;
54 UINT fStyle;
55 DWORD dwRop;
56 DWORD fState;
57 DWORD Frame;
58 COLORREF crEffect;
59 } IMAGELISTDRAWPARAMS;
60
61 typedef IMAGELISTDRAWPARAMS* LPIMAGELISTDRAWPARAMS;
62 cpp_quote("#endif")
63
64 cpp_quote("HRESULT WINAPI ImageList_CoCreateInstance(REFCLSID,const IUnknown *, REFIID,void **);")
65
66 const UINT ILIF_ALPHA = 1;
67
68 [
69 uuid(46eb5926-582e-4017-9fdf-e8998daa0950),
70 local
71 ]
72 interface IImageList : IUnknown
73 {
74 HRESULT Add(
75 [in] HBITMAP hbmImage,
76 [in] HBITMAP hbmMask,
77 [out] int* pi);
78
79 HRESULT ReplaceIcon(
80 [in] int i,
81 [in] HICON hicon,
82 [out] int* pi);
83
84 HRESULT SetOverlayImage(
85 [in] int iImage,
86 [in] int iOverlay);
87
88 HRESULT Replace(
89 [in] int i,
90 [in] HBITMAP hbmImage,
91 [in] HBITMAP hbmMask);
92
93 HRESULT AddMasked(
94 [in] HBITMAP hbmImage,
95 [in] COLORREF crMask,
96 [out] int* pi);
97
98 HRESULT Draw(
99 [in] IMAGELISTDRAWPARAMS* pimldp);
100
101 HRESULT Remove(
102 [in] int i);
103
104 HRESULT GetIcon(
105 [in] int i,
106 [in] UINT flags,
107 [out] HICON* picon);
108
109 HRESULT GetImageInfo(
110 [in] int i,
111 [out] IMAGEINFO* pImageInfo);
112
113 HRESULT Copy(
114 [in] int iDst,
115 [in] IUnknown* punkSrc,
116 [in] int iSrc,
117 [in] UINT uFlags);
118
119 HRESULT Merge(
120 [in] int i1,
121 [in] IUnknown* punk2,
122 [in] int i2,
123 [in] int dx,
124 [in] int dy,
125 [out] REFIID riid,
126 [out] PVOID* ppv);
127
128 HRESULT Clone(
129 [in] REFIID riid,
130 [out] PVOID* ppv);
131
132 HRESULT GetImageRect(
133 [in] int i,
134 [out] RECT* prc);
135
136 HRESULT GetIconSize(
137 [out] int* cx,
138 [out] int* cy);
139
140 HRESULT SetIconSize(
141 [in] int cx,
142 [in] int cy);
143
144 HRESULT GetImageCount(
145 [out] int* pi);
146
147 HRESULT SetImageCount(
148 [in] UINT uNewCount);
149
150 HRESULT SetBkColor(
151 [in] COLORREF clrBk,
152 [out] COLORREF* pclr);
153
154 HRESULT GetBkColor(
155 [out] COLORREF* pclr);
156
157 HRESULT BeginDrag(
158 [in] int iTrack,
159 [in] int dxHotspot,
160 [in] int dyHotspot);
161
162 HRESULT EndDrag();
163
164 HRESULT DragEnter(
165 [in] HWND hwndLock,
166 [in] int x,
167 [in] int y);
168
169 HRESULT DragLeave(
170 [in] HWND hwndLock);
171
172 HRESULT DragMove(
173 [in] int x,
174 [in] int y);
175
176 HRESULT SetDragCursorImage(
177 [in] IUnknown* punk,
178 [in] int iDrag,
179 [in] int dxHotspot,
180 [in] int dyHotspot);
181
182 HRESULT DragShowNolock(
183 [in] BOOL fShow);
184
185 HRESULT GetDragImage(
186 [out] POINT * ppt,
187 [out] POINT * pptHotspot,
188 [out] REFIID riid,
189 [out] PVOID* ppv);
190
191 HRESULT GetItemFlags(
192 [in] int i,
193 [out] DWORD *dwFlags);
194
195 HRESULT GetOverlayImage(
196 [in] int iOverlay,
197 [out] int* piIndex);
198 }
199
200 [
201 uuid(192b9d83-50fc-457b-90a0-2b82a8b5dae1),
202 local
203 ]
204 interface IImageList2 : IImageList
205 {
206 typedef struct tagIMAGELISTSTATS
207 {
208 DWORD cbSize;
209 INT cAlloc;
210 INT cUsed;
211 INT cStandby;
212 } IMAGELISTSTATS;
213
214 HRESULT Resize(INT x_size, INT y_size);
215 HRESULT GetOriginalSize([in] INT image, [in] DWORD flags, [out] INT *cx, [out] INT *cy);
216 HRESULT SetOriginalSize([in] INT image, [in] INT cx, [in] INT cy);
217 HRESULT SetCallback([in, unique] IUnknown *callback);
218 HRESULT GetCallback([in] REFIID riid, [out, iid_is(riid)] void** ppv);
219 HRESULT ForceImagePresent([in] INT image, DWORD flags);
220 HRESULT DiscardImages([in] INT first_image, [in] INT last_image, [in] DWORD flags);
221 HRESULT PreloadImages([in] IMAGELISTDRAWPARAMS *params);
222 HRESULT GetStatistics([in, out] IMAGELISTSTATS *stats);
223 HRESULT Initialize([in] INT cx, [in] INT cy, [in] UINT flags, [in] INT initial, [in] INT grow);
224 HRESULT Replace2([in] INT i, [in] HBITMAP image, [in, unique] HBITMAP mask, [in, unique] IUnknown *unk, [in] DWORD flags);
225 HRESULT ReplaceFromImageList([in] INT i, [in] IImageList *imagelist, [in] INT src, [in, unique] IUnknown *unk, [in] DWORD flags);
226 }
227
228 [
229 uuid(bcada15B-b428-420c-8d28-023590924c9f)
230 ]
231 library CommonControlObjects
232 {
233 [
234 uuid(7c476ba2-02b1-48f4-8048-b24619ddc058)
235 ]
236 coclass ImageList
237 {
238 interface IImageList;
239 interface IImageList2;
240 }
241 }