include: Remote parameter should be a pointer not an array.
[wine/multimedia.git] / include / commctrl.h
blob8673ba9d2411d7bac1abeb9b3f616f5fe3b03140
1 /*
2 * Common controls definitions
4 * Copyright (C) the Wine project
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.
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.
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
21 #ifndef __WINE_COMMCTRL_H
22 #define __WINE_COMMCTRL_H
24 #include <prsht.h>
26 #ifdef __cplusplus
27 extern "C" {
28 #endif
30 BOOL WINAPI ShowHideMenuCtl (HWND, UINT_PTR, LPINT);
31 VOID WINAPI GetEffectiveClientRect (HWND, LPRECT, const INT*);
32 VOID WINAPI InitCommonControls (VOID);
34 typedef struct tagINITCOMMONCONTROLSEX {
35 DWORD dwSize;
36 DWORD dwICC;
37 } INITCOMMONCONTROLSEX, *LPINITCOMMONCONTROLSEX;
39 BOOL WINAPI InitCommonControlsEx (const INITCOMMONCONTROLSEX*);
41 LANGID WINAPI GetMUILanguage (VOID);
42 VOID WINAPI InitMUILanguage (LANGID uiLang);
45 #define COMCTL32_VERSION 5 /* dll version */
47 #ifndef _WIN32_IE
48 #define _WIN32_IE 0x0400
49 #endif
51 #define ICC_LISTVIEW_CLASSES 0x00000001 /* listview, header */
52 #define ICC_TREEVIEW_CLASSES 0x00000002 /* treeview, tooltips */
53 #define ICC_BAR_CLASSES 0x00000004 /* toolbar, statusbar, trackbar, tooltips */
54 #define ICC_TAB_CLASSES 0x00000008 /* tab, tooltips */
55 #define ICC_UPDOWN_CLASS 0x00000010 /* updown */
56 #define ICC_PROGRESS_CLASS 0x00000020 /* progress */
57 #define ICC_HOTKEY_CLASS 0x00000040 /* hotkey */
58 #define ICC_ANIMATE_CLASS 0x00000080 /* animate */
59 #define ICC_WIN95_CLASSES 0x000000FF
60 #define ICC_DATE_CLASSES 0x00000100 /* month picker, date picker, time picker, updown */
61 #define ICC_USEREX_CLASSES 0x00000200 /* comboex */
62 #define ICC_COOL_CLASSES 0x00000400 /* rebar (coolbar) */
63 #define ICC_INTERNET_CLASSES 0x00000800 /* IP address, ... */
64 #define ICC_PAGESCROLLER_CLASS 0x00001000 /* page scroller */
65 #define ICC_NATIVEFNTCTL_CLASS 0x00002000 /* native font control ???*/
66 #define ICC_STANDARD_CLASSES 0x00004000
67 #define ICC_LINK_CLASS 0x00008000
70 /* common control styles */
71 #define CCS_TOP 0x00000001L
72 #define CCS_NOMOVEY 0x00000002L
73 #define CCS_BOTTOM 0x00000003L
74 #define CCS_NORESIZE 0x00000004L
75 #define CCS_NOPARENTALIGN 0x00000008L
76 #define CCS_ADJUSTABLE 0x00000020L
77 #define CCS_NODIVIDER 0x00000040L
78 #define CCS_VERT 0x00000080L
79 #define CCS_LEFT (CCS_VERT|CCS_TOP)
80 #define CCS_RIGHT (CCS_VERT|CCS_BOTTOM)
81 #define CCS_NOMOVEX (CCS_VERT|CCS_NOMOVEY)
84 /* common control shared messages */
85 #define CCM_FIRST 0x2000
87 #define CCM_SETBKCOLOR (CCM_FIRST+0x1) /* lParam = bkColor */
88 #define CCM_SETCOLORSCHEME (CCM_FIRST+0x2) /* lParam = COLORSCHEME struct ptr */
89 #define CCM_GETCOLORSCHEME (CCM_FIRST+0x3) /* lParam = COLORSCHEME struct ptr */
90 #define CCM_GETDROPTARGET (CCM_FIRST+0x4)
91 #define CCM_SETUNICODEFORMAT (CCM_FIRST+0x5)
92 #define CCM_GETUNICODEFORMAT (CCM_FIRST+0x6)
93 #define CCM_SETVERSION (CCM_FIRST+0x7)
94 #define CCM_GETVERSION (CCM_FIRST+0x8)
95 #define CCM_SETNOTIFYWINDOW (CCM_FIRST+0x9) /* wParam = hwndParent */
96 #define CCM_SETWINDOWTHEME (CCM_FIRST+0xb)
97 #define CCM_DPISCALE (CCM_FIRST+0xc)
100 /* common notification codes (WM_NOTIFY)*/
101 #define NM_FIRST (0U- 0U)
102 #define NM_LAST (0U- 99U)
103 #define NM_OUTOFMEMORY (NM_FIRST-1)
104 #define NM_CLICK (NM_FIRST-2)
105 #define NM_DBLCLK (NM_FIRST-3)
106 #define NM_RETURN (NM_FIRST-4)
107 #define NM_RCLICK (NM_FIRST-5)
108 #define NM_RDBLCLK (NM_FIRST-6)
109 #define NM_SETFOCUS (NM_FIRST-7)
110 #define NM_KILLFOCUS (NM_FIRST-8)
111 #define NM_CUSTOMDRAW (NM_FIRST-12)
112 #define NM_HOVER (NM_FIRST-13)
113 #define NM_NCHITTEST (NM_FIRST-14)
114 #define NM_KEYDOWN (NM_FIRST-15)
115 #define NM_RELEASEDCAPTURE (NM_FIRST-16)
116 #define NM_SETCURSOR (NM_FIRST-17)
117 #define NM_CHAR (NM_FIRST-18)
118 #define NM_TOOLTIPSCREATED (NM_FIRST-19)
119 #define NM_LDOWN (NM_FIRST-20)
120 #define NM_RDOWN (NM_FIRST-21)
121 #define NM_THEMECHANGED (NM_FIRST-22)
122 #define NM_FONTCHANGED (NM_FIRST-23)
123 #define NM_CUSTOMTEXT (NM_FIRST-24)
124 #define NM_TVSTATEIMAGECHANGING (NM_FIRST-24)
126 #define HANDLE_WM_NOTIFY(hwnd, wParam, lParam, fn) \
127 (fn)((hwnd), (int)(wParam), (NMHDR*)(lParam))
128 #define FORWARD_WM_NOTIFY(hwnd, idFrom, pnmhdr, fn) \
129 (LRESULT)(fn)((hwnd), WM_NOTIFY, (WPARAM)(int)(idFrom), (LPARAM)(NMHDR*)(pnmhdr))
132 /* callback constants */
133 #define LPSTR_TEXTCALLBACKA ((LPSTR)-1L)
134 #define LPSTR_TEXTCALLBACKW ((LPWSTR)-1L)
135 #define LPSTR_TEXTCALLBACK WINELIB_NAME_AW(LPSTR_TEXTCALLBACK)
137 #define I_IMAGECALLBACK (-1)
138 #define I_IMAGENONE (-2)
139 #define I_INDENTCALLBACK (-1)
140 #define I_CHILDRENCALLBACK (-1)
141 #define I_GROUPIDCALLBACK (-1)
142 #define I_GROUPIDNONE (-2)
143 #define I_COLUMNSCALLBACK ((UINT)-1)
145 /* owner drawn types */
146 #define ODT_HEADER 100
147 #define ODT_TAB 101
148 #define ODT_LISTVIEW 102
150 /* common notification structures */
151 typedef struct tagNMTOOLTIPSCREATED
153 NMHDR hdr;
154 HWND hwndToolTips;
155 } NMTOOLTIPSCREATED, *LPNMTOOLTIPSCREATED;
157 typedef struct tagNMMOUSE
159 NMHDR hdr;
160 DWORD_PTR dwItemSpec;
161 DWORD_PTR dwItemData;
162 POINT pt;
163 DWORD dwHitInfo; /* info where on item or control the mouse is */
164 } NMMOUSE, *LPNMMOUSE;
166 typedef struct tagNMOBJECTNOTIFY
168 NMHDR hdr;
169 int iItem;
170 #ifdef __IID_DEFINED__
171 const IID *piid;
172 #else
173 const void *piid;
174 #endif
175 void *pObject;
176 HRESULT hResult;
177 DWORD dwFlags;
178 } NMOBJECTNOTIFY, *LPNMOBJECTNOTIFY;
180 typedef struct tagNMKEY
182 NMHDR hdr;
183 UINT nVKey;
184 UINT uFlags;
185 } NMKEY, *LPNMKEY;
187 typedef struct tagNMCHAR
189 NMHDR hdr;
190 UINT ch;
191 DWORD dwItemPrev; /* Item previously selected */
192 DWORD dwItemNext; /* Item to be selected */
193 } NMCHAR, *LPNMCHAR;
195 #ifndef CCSIZEOF_STRUCT
196 #define CCSIZEOF_STRUCT(name, member) \
197 (((INT)((LPBYTE)(&((name*)0)->member)-((LPBYTE)((name*)0))))+ \
198 sizeof(((name*)0)->member))
199 #endif
202 /* This is only for Winelib applications. DON't use it wine itself!!! */
203 #ifndef SNDMSG
204 #ifdef __cplusplus
205 #define SNDMSG ::SendMessage
206 #else /* __cplusplus */
207 #define SNDMSG SendMessage
208 #endif /* __cplusplus */
209 #endif /* SNDMSG */
212 #ifdef __cplusplus
213 #define SNDMSGA ::SendMessageA
214 #define SNDMSGW ::SendMessageW
215 #else
216 #define SNDMSGA SendMessageA
217 #define SNDMSGW SendMessageW
218 #endif
220 /* Custom Draw messages */
222 #define CDRF_DODEFAULT 0x0
223 #define CDRF_NEWFONT 0x00000002
224 #define CDRF_SKIPDEFAULT 0x00000004
225 #define CDRF_NOTIFYPOSTPAINT 0x00000010
226 #define CDRF_NOTIFYITEMDRAW 0x00000020
227 #define CDRF_NOTIFYSUBITEMDRAW 0x00000020
228 #define CDRF_NOTIFYPOSTERASE 0x00000040
229 #define CDRF_NOTIFYITEMERASE 0x00000080 /* obsolete ??? */
232 /* drawstage flags */
234 #define CDDS_PREPAINT 1
235 #define CDDS_POSTPAINT 2
236 #define CDDS_PREERASE 3
237 #define CDDS_POSTERASE 4
239 #define CDDS_ITEM 0x00010000
240 #define CDDS_ITEMPREPAINT (CDDS_ITEM | CDDS_PREPAINT)
241 #define CDDS_ITEMPOSTPAINT (CDDS_ITEM | CDDS_POSTPAINT)
242 #define CDDS_ITEMPREERASE (CDDS_ITEM | CDDS_PREERASE)
243 #define CDDS_ITEMPOSTERASE (CDDS_ITEM | CDDS_POSTERASE)
244 #define CDDS_SUBITEM 0x00020000
246 /* itemState flags */
248 #define CDIS_SELECTED 0x0001
249 #define CDIS_GRAYED 0x0002
250 #define CDIS_DISABLED 0x0004
251 #define CDIS_CHECKED 0x0008
252 #define CDIS_FOCUS 0x0010
253 #define CDIS_DEFAULT 0x0020
254 #define CDIS_HOT 0x0040
255 #define CDIS_MARKED 0x0080
256 #define CDIS_INDETERMINATE 0x0100
257 #define CDIS_SHOWKEYBOARDCUES 0x0200
258 #define CDIS_NEARHOT 0x0400
259 #define CDIS_OTHERSIDEHOT 0x0800
260 #define CDIS_DROPHILITED 0x1000
263 typedef struct tagNMCUSTOMDRAWINFO
265 NMHDR hdr;
266 DWORD dwDrawStage;
267 HDC hdc;
268 RECT rc;
269 DWORD_PTR dwItemSpec;
270 UINT uItemState;
271 LPARAM lItemlParam;
272 } NMCUSTOMDRAW, *LPNMCUSTOMDRAW;
274 typedef struct tagNMTTCUSTOMDRAW
276 NMCUSTOMDRAW nmcd;
277 UINT uDrawFlags;
278 } NMTTCUSTOMDRAW, *LPNMTTCUSTOMDRAW;
283 /* StatusWindow */
285 #define STATUSCLASSNAMEA "msctls_statusbar32"
286 #if defined(__GNUC__)
287 # define STATUSCLASSNAMEW (const WCHAR []){ 'm','s','c','t','l','s','_', \
288 's','t','a','t','u','s','b','a','r','3','2',0 }
289 #elif defined(_MSC_VER)
290 # define STATUSCLASSNAMEW L"msctls_statusbar32"
291 #else
292 static const WCHAR STATUSCLASSNAMEW[] = { 'm','s','c','t','l','s','_',
293 's','t','a','t','u','s','b','a','r','3','2',0 };
294 #endif
295 #define STATUSCLASSNAME WINELIB_NAME_AW(STATUSCLASSNAME)
297 #define SBT_NOBORDERS 0x0100
298 #define SBT_POPOUT 0x0200
299 #define SBT_RTLREADING 0x0400 /* not supported */
300 #define SBT_TOOLTIPS 0x0800
301 #define SBT_OWNERDRAW 0x1000
303 #define SBARS_SIZEGRIP 0x0100
305 #define SB_SIMPLEID 0x00ff
307 #define SB_SETTEXTA (WM_USER+1)
308 #define SB_SETTEXTW (WM_USER+11)
309 #define SB_SETTEXT WINELIB_NAME_AW(SB_SETTEXT)
310 #define SB_GETTEXTA (WM_USER+2)
311 #define SB_GETTEXTW (WM_USER+13)
312 #define SB_GETTEXT WINELIB_NAME_AW(SB_GETTEXT)
313 #define SB_GETTEXTLENGTHA (WM_USER+3)
314 #define SB_GETTEXTLENGTHW (WM_USER+12)
315 #define SB_GETTEXTLENGTH WINELIB_NAME_AW(SB_GETTEXTLENGTH)
316 #define SB_SETPARTS (WM_USER+4)
317 #define SB_SETBORDERS (WM_USER+5)
318 #define SB_GETPARTS (WM_USER+6)
319 #define SB_GETBORDERS (WM_USER+7)
320 #define SB_SETMINHEIGHT (WM_USER+8)
321 #define SB_SIMPLE (WM_USER+9)
322 #define SB_GETRECT (WM_USER+10)
323 #define SB_ISSIMPLE (WM_USER+14)
324 #define SB_SETICON (WM_USER+15)
325 #define SB_SETTIPTEXTA (WM_USER+16)
326 #define SB_SETTIPTEXTW (WM_USER+17)
327 #define SB_SETTIPTEXT WINELIB_NAME_AW(SB_SETTIPTEXT)
328 #define SB_GETTIPTEXTA (WM_USER+18)
329 #define SB_GETTIPTEXTW (WM_USER+19)
330 #define SB_GETTIPTEXT WINELIB_NAME_AW(SB_GETTIPTEXT)
331 #define SB_GETICON (WM_USER+20)
332 #define SB_SETBKCOLOR CCM_SETBKCOLOR /* lParam = bkColor */
333 #define SB_GETUNICODEFORMAT CCM_GETUNICODEFORMAT
334 #define SB_SETUNICODEFORMAT CCM_SETUNICODEFORMAT
336 #define SBN_FIRST (0U-880U)
337 #define SBN_LAST (0U-899U)
338 #define SBN_SIMPLEMODECHANGE (SBN_FIRST-0)
340 HWND WINAPI CreateStatusWindowA (LONG, LPCSTR, HWND, UINT);
341 HWND WINAPI CreateStatusWindowW (LONG, LPCWSTR, HWND, UINT);
342 #define CreateStatusWindow WINELIB_NAME_AW(CreateStatusWindow)
343 VOID WINAPI DrawStatusTextA (HDC, LPCRECT, LPCSTR, UINT);
344 VOID WINAPI DrawStatusTextW (HDC, LPCRECT, LPCWSTR, UINT);
345 #define DrawStatusText WINELIB_NAME_AW(DrawStatusText)
346 VOID WINAPI MenuHelp (UINT, WPARAM, LPARAM, HMENU,
347 HINSTANCE, HWND, UINT*);
349 typedef struct tagCOLORSCHEME
351 DWORD dwSize;
352 COLORREF clrBtnHighlight; /* highlight color */
353 COLORREF clrBtnShadow; /* shadow color */
354 } COLORSCHEME, *LPCOLORSCHEME;
356 /**************************************************************************
357 * Drag List control
360 typedef struct tagDRAGLISTINFO
362 UINT uNotification;
363 HWND hWnd;
364 POINT ptCursor;
365 } DRAGLISTINFO, *LPDRAGLISTINFO;
367 #define DL_BEGINDRAG (WM_USER+133)
368 #define DL_DRAGGING (WM_USER+134)
369 #define DL_DROPPED (WM_USER+135)
370 #define DL_CANCELDRAG (WM_USER+136)
372 #define DL_CURSORSET 0
373 #define DL_STOPCURSOR 1
374 #define DL_COPYCURSOR 2
375 #define DL_MOVECURSOR 3
377 #define DRAGLISTMSGSTRINGA "commctrl_DragListMsg"
378 #if defined(__GNUC__)
379 # define DRAGLISTMSGSTRINGW (const WCHAR []){ 'c','o','m','m','c','t','r','l', \
380 '_','D','r','a','g','L','i','s','t','M','s','g',0 }
381 #elif defined(_MSC_VER)
382 # define DRAGLISTMSGSTRINGW L"commctrl_DragListMsg"
383 #else
384 static const WCHAR DRAGLISTMSGSTRINGW[] = { 'c','o','m','m','c','t','r','l',
385 '_','D','r','a','g','L','i','s','t','M','s','g',0 };
386 #endif
387 #define DRAGLISTMSGSTRING WINELIB_NAME_AW(DRAGLISTMSGSTRING)
389 BOOL WINAPI MakeDragList (HWND);
390 VOID WINAPI DrawInsert (HWND, HWND, INT);
391 INT WINAPI LBItemFromPt (HWND, POINT, BOOL);
394 /* UpDown */
396 #define UPDOWN_CLASSA "msctls_updown32"
397 #if defined(__GNUC__)
398 # define UPDOWN_CLASSW (const WCHAR []){ 'm','s','c','t','l','s','_', \
399 'u','p','d','o','w','n','3','2',0 }
400 #elif defined(_MSC_VER)
401 # define UPDOWN_CLASSW L"msctls_updown32"
402 #else
403 static const WCHAR UPDOWN_CLASSW[] = { 'm','s','c','t','l','s','_',
404 'u','p','d','o','w','n','3','2',0 };
405 #endif
406 #define UPDOWN_CLASS WINELIB_NAME_AW(UPDOWN_CLASS)
408 typedef struct _UDACCEL
410 UINT nSec;
411 UINT nInc;
412 } UDACCEL, *LPUDACCEL;
414 #define UD_MAXVAL 0x7fff
415 #define UD_MINVAL 0x8001
417 #define UDS_WRAP 0x0001
418 #define UDS_SETBUDDYINT 0x0002
419 #define UDS_ALIGNRIGHT 0x0004
420 #define UDS_ALIGNLEFT 0x0008
421 #define UDS_AUTOBUDDY 0x0010
422 #define UDS_ARROWKEYS 0x0020
423 #define UDS_HORZ 0x0040
424 #define UDS_NOTHOUSANDS 0x0080
425 #define UDS_HOTTRACK 0x0100
427 #define UDN_FIRST (0U-721)
428 #define UDN_LAST (0U-740)
429 #define UDN_DELTAPOS (UDN_FIRST-1)
431 #define UDM_SETRANGE (WM_USER+101)
432 #define UDM_GETRANGE (WM_USER+102)
433 #define UDM_SETPOS (WM_USER+103)
434 #define UDM_GETPOS (WM_USER+104)
435 #define UDM_SETBUDDY (WM_USER+105)
436 #define UDM_GETBUDDY (WM_USER+106)
437 #define UDM_SETACCEL (WM_USER+107)
438 #define UDM_GETACCEL (WM_USER+108)
439 #define UDM_SETBASE (WM_USER+109)
440 #define UDM_GETBASE (WM_USER+110)
441 #define UDM_SETRANGE32 (WM_USER+111)
442 #define UDM_GETRANGE32 (WM_USER+112)
443 #define UDM_SETUNICODEFORMAT CCM_SETUNICODEFORMAT
444 #define UDM_GETUNICODEFORMAT CCM_GETUNICODEFORMAT
445 #define UDM_SETPOS32 (WM_USER+113)
446 #define UDM_GETPOS32 (WM_USER+114)
449 #define NMUPDOWN NM_UPDOWN
450 #define LPNMUPDOWN LPNM_UPDOWN
452 typedef struct tagNM_UPDOWN
454 NMHDR hdr;
455 int iPos;
456 int iDelta;
457 } NM_UPDOWN, *LPNM_UPDOWN;
459 HWND WINAPI CreateUpDownControl (DWORD, INT, INT, INT, INT,
460 HWND, INT, HINSTANCE, HWND,
461 INT, INT, INT);
463 /* Progress Bar */
465 #define PROGRESS_CLASSA "msctls_progress32"
466 #if defined(__GNUC__)
467 # define PROGRESS_CLASSW (const WCHAR []){ 'm','s','c','t','l','s','_', \
468 'p','r','o','g','r','e','s','s','3','2',0 }
469 #elif defined(_MSC_VER)
470 # define PROGRESS_CLASSW L"msctls_progress32"
471 #else
472 static const WCHAR PROGRESS_CLASSW[] = { 'm','s','c','t','l','s','_',
473 'p','r','o','g','r','e','s','s','3','2',0 };
474 #endif
475 #define PROGRESS_CLASS WINELIB_NAME_AW(PROGRESS_CLASS)
477 #define PBM_SETRANGE (WM_USER+1)
478 #define PBM_SETPOS (WM_USER+2)
479 #define PBM_DELTAPOS (WM_USER+3)
480 #define PBM_SETSTEP (WM_USER+4)
481 #define PBM_STEPIT (WM_USER+5)
482 #define PBM_SETRANGE32 (WM_USER+6)
483 #define PBM_GETRANGE (WM_USER+7)
484 #define PBM_GETPOS (WM_USER+8)
485 #define PBM_SETBARCOLOR (WM_USER+9)
486 #define PBM_SETMARQUEE (WM_USER+10)
487 #define PBM_GETBKCOLOR (WM_USER+14)
488 #define PBM_GETBARCOLOR (WM_USER+15)
489 #define PBM_SETBKCOLOR CCM_SETBKCOLOR
491 #define PBS_SMOOTH 0x01
492 #define PBS_VERTICAL 0x04
493 #define PBS_MARQUEE 0x08
495 typedef struct
497 INT iLow;
498 INT iHigh;
499 } PBRANGE, *PPBRANGE;
502 /* ImageList */
504 struct _IMAGELIST;
505 typedef struct _IMAGELIST *HIMAGELIST;
507 #define CLR_NONE 0xFFFFFFFF
508 #define CLR_DEFAULT 0xFF000000
509 #define CLR_HILIGHT CLR_DEFAULT
511 #define ILC_MASK 0x0001
512 #define ILC_COLOR 0x0000
513 #define ILC_COLORDDB 0x00FE
514 #define ILC_COLOR4 0x0004
515 #define ILC_COLOR8 0x0008
516 #define ILC_COLOR16 0x0010
517 #define ILC_COLOR24 0x0018
518 #define ILC_COLOR32 0x0020
519 #define ILC_PALETTE 0x0800 /* no longer supported by M$ */
520 #define ILC_MIRROR 0x2000
521 #define ILC_PERITEMMIRROR 0x8000
523 #define ILD_NORMAL 0x0000
524 #define ILD_TRANSPARENT 0x0001
525 #define ILD_BLEND25 0x0002
526 #define ILD_BLEND50 0x0004
527 #define ILD_MASK 0x0010
528 #define ILD_IMAGE 0x0020
529 #define ILD_ROP 0x0040
530 #define ILD_OVERLAYMASK 0x0F00
531 #define ILD_PRESERVEALPHA 0x1000
532 #define ILD_SCALE 0x2000
533 #define ILD_DPISCALE 0x4000
534 #define ILD_ASYNC 0x8000
536 #define ILD_SELECTED ILD_BLEND50
537 #define ILD_FOCUS ILD_BLEND25
538 #define ILD_BLEND ILD_BLEND50
540 #define INDEXTOOVERLAYMASK(i) ((i)<<8)
541 #define INDEXTOSTATEIMAGEMASK(i) ((i)<<12)
543 #define ILCF_MOVE (0x00000000)
544 #define ILCF_SWAP (0x00000001)
546 #define ILGT_NORMAL 0x0000
547 #define ILGT_ASYNC 0x0001
549 #define ILS_NORMAL 0x0000
550 #define ILS_GLOW 0x0001
551 #define ILS_SHADOW 0x0002
552 #define ILS_SATURATE 0x0004
553 #define ILS_ALPHA 0x0008
555 typedef struct _IMAGEINFO
557 HBITMAP hbmImage;
558 HBITMAP hbmMask;
559 INT Unused1;
560 INT Unused2;
561 RECT rcImage;
562 } IMAGEINFO, *LPIMAGEINFO;
565 typedef struct _IMAGELISTDRAWPARAMS
567 DWORD cbSize;
568 HIMAGELIST himl;
569 INT i;
570 HDC hdcDst;
571 INT x;
572 INT y;
573 INT cx;
574 INT cy;
575 INT xBitmap; /* x offest from the upperleft of bitmap */
576 INT yBitmap; /* y offset from the upperleft of bitmap */
577 COLORREF rgbBk;
578 COLORREF rgbFg;
579 UINT fStyle;
580 DWORD dwRop;
581 DWORD fState;
582 DWORD Frame;
583 DWORD crEffect;
584 } IMAGELISTDRAWPARAMS, *LPIMAGELISTDRAWPARAMS;
587 INT WINAPI ImageList_Add(HIMAGELIST,HBITMAP,HBITMAP);
588 INT WINAPI ImageList_AddMasked(HIMAGELIST,HBITMAP,COLORREF);
589 BOOL WINAPI ImageList_BeginDrag(HIMAGELIST,INT,INT,INT);
590 BOOL WINAPI ImageList_Copy(HIMAGELIST,INT,HIMAGELIST,INT,UINT);
591 HIMAGELIST WINAPI ImageList_Create(INT,INT,UINT,INT,INT);
592 BOOL WINAPI ImageList_Destroy(HIMAGELIST);
593 BOOL WINAPI ImageList_DragEnter(HWND,INT,INT);
594 BOOL WINAPI ImageList_DragLeave(HWND);
595 BOOL WINAPI ImageList_DragMove(INT,INT);
596 BOOL WINAPI ImageList_DragShowNolock (BOOL);
597 BOOL WINAPI ImageList_Draw(HIMAGELIST,INT,HDC,INT,INT,UINT);
598 BOOL WINAPI ImageList_DrawEx(HIMAGELIST,INT,HDC,INT,INT,INT,
599 INT,COLORREF,COLORREF,UINT);
600 BOOL WINAPI ImageList_DrawIndirect(IMAGELISTDRAWPARAMS*);
601 HIMAGELIST WINAPI ImageList_Duplicate(HIMAGELIST);
602 VOID WINAPI ImageList_EndDrag(VOID);
603 COLORREF WINAPI ImageList_GetBkColor(HIMAGELIST);
604 HIMAGELIST WINAPI ImageList_GetDragImage(POINT*,POINT*);
605 HICON WINAPI ImageList_GetIcon(HIMAGELIST,INT,UINT);
606 BOOL WINAPI ImageList_GetIconSize(HIMAGELIST,INT*,INT*);
607 INT WINAPI ImageList_GetImageCount(HIMAGELIST);
608 BOOL WINAPI ImageList_GetImageInfo(HIMAGELIST,INT,IMAGEINFO*);
609 BOOL WINAPI ImageList_GetImageRect(HIMAGELIST,INT,LPRECT);
610 HIMAGELIST WINAPI ImageList_LoadImageA(HINSTANCE,LPCSTR,INT,INT,
611 COLORREF,UINT,UINT);
612 HIMAGELIST WINAPI ImageList_LoadImageW(HINSTANCE,LPCWSTR,INT,INT,
613 COLORREF,UINT,UINT);
614 #define ImageList_LoadImage WINELIB_NAME_AW(ImageList_LoadImage)
615 HIMAGELIST WINAPI ImageList_Merge(HIMAGELIST,INT,HIMAGELIST,INT,INT,INT);
616 BOOL WINAPI ImageList_Remove(HIMAGELIST,INT);
617 BOOL WINAPI ImageList_Replace(HIMAGELIST,INT,HBITMAP,HBITMAP);
618 INT WINAPI ImageList_ReplaceIcon(HIMAGELIST,INT,HICON);
619 COLORREF WINAPI ImageList_SetBkColor(HIMAGELIST,COLORREF);
620 BOOL WINAPI ImageList_SetDragCursorImage(HIMAGELIST,INT,INT,INT);
622 BOOL WINAPI ImageList_SetIconSize(HIMAGELIST,INT,INT);
623 BOOL WINAPI ImageList_SetImageCount(HIMAGELIST,UINT);
624 BOOL WINAPI ImageList_SetOverlayImage(HIMAGELIST,INT,INT);
626 #ifdef __IStream_INTERFACE_DEFINED__
627 HIMAGELIST WINAPI ImageList_Read(LPSTREAM);
628 BOOL WINAPI ImageList_Write(HIMAGELIST, LPSTREAM);
629 #endif
631 #define ImageList_AddIcon(himl,hicon) ImageList_ReplaceIcon(himl,-1,hicon)
632 #define ImageList_ExtractIcon(hi,himl,i) ImageList_GetIcon(himl,i,0)
633 #define ImageList_LoadBitmap(hi,lpbmp,cx,cGrow,crMask) \
634 ImageList_LoadImage(hi,lpbmp,cx,cGrow,crMask,IMAGE_BITMAP,0)
635 #define ImageList_RemoveAll(himl) ImageList_Remove(himl,-1)
638 #ifndef WM_MOUSEHOVER
639 #define WM_MOUSEHOVER 0x02A1
640 #define WM_MOUSELEAVE 0x02A3
641 #endif
643 #ifndef TME_HOVER
645 #define TME_HOVER 0x00000001
646 #define TME_LEAVE 0x00000002
647 #define TME_NONCLIENT 0x00000010
648 #define TME_QUERY 0x40000000
649 #define TME_CANCEL 0x80000000
652 #define HOVER_DEFAULT 0xFFFFFFFF
654 typedef struct tagTRACKMOUSEEVENT {
655 DWORD cbSize;
656 DWORD dwFlags;
657 HWND hwndTrack;
658 DWORD dwHoverTime;
659 } TRACKMOUSEEVENT, *LPTRACKMOUSEEVENT;
661 #endif
663 BOOL WINAPI _TrackMouseEvent(LPTRACKMOUSEEVENT lpEventTrack);
665 /* Flat Scrollbar control */
667 #define FLATSB_CLASSA "flatsb_class32"
668 #if defined(__GNUC__)
669 # define FLATSB_CLASSW (const WCHAR []){ 'f','l','a','t','s','b','_', \
670 'c','l','a','s','s','3','2',0 }
671 #elif defined(_MSC_VER)
672 # define FLATSB_CLASSW L"flatsb_class32"
673 #else
674 static const WCHAR FLATSB_CLASSW[] = { 'f','l','a','t','s','b','_',
675 'c','l','a','s','s','3','2',0 };
676 #endif
677 #define FLATSB_CLASS WINELIB_NAME_AW(FLATSB_CLASS)
679 #define WSB_PROP_CYVSCROLL 0x00000001L
680 #define WSB_PROP_CXHSCROLL 0x00000002L
681 #define WSB_PROP_CYHSCROLL 0x00000004L
682 #define WSB_PROP_CXVSCROLL 0x00000008L
683 #define WSB_PROP_CXHTHUMB 0x00000010L
684 #define WSB_PROP_CYVTHUMB 0x00000020L
685 #define WSB_PROP_VBKGCOLOR 0x00000040L
686 #define WSB_PROP_HBKGCOLOR 0x00000080L
687 #define WSB_PROP_VSTYLE 0x00000100L
688 #define WSB_PROP_HSTYLE 0x00000200L
689 #define WSB_PROP_WINSTYLE 0x00000400L
690 #define WSB_PROP_PALETTE 0x00000800L
691 #define WSB_PROP_MASK 0x00000FFFL
693 #define FSB_REGULAR_MODE 0
694 #define FSB_ENCARTA_MODE 1
695 #define FSB_FLAT_MODE 2
698 BOOL WINAPI FlatSB_EnableScrollBar(HWND, INT, UINT);
699 BOOL WINAPI FlatSB_ShowScrollBar(HWND, INT, BOOL);
700 BOOL WINAPI FlatSB_GetScrollRange(HWND, INT, LPINT, LPINT);
701 BOOL WINAPI FlatSB_GetScrollInfo(HWND, INT, LPSCROLLINFO);
702 INT WINAPI FlatSB_GetScrollPos(HWND, INT);
703 BOOL WINAPI FlatSB_GetScrollProp(HWND, INT, LPINT);
704 INT WINAPI FlatSB_SetScrollPos(HWND, INT, INT, BOOL);
705 INT WINAPI FlatSB_SetScrollInfo(HWND, INT, LPSCROLLINFO, BOOL);
706 INT WINAPI FlatSB_SetScrollRange(HWND, INT, INT, INT, BOOL);
707 BOOL WINAPI FlatSB_SetScrollProp(HWND, UINT, INT, BOOL);
708 BOOL WINAPI InitializeFlatSB(HWND);
709 HRESULT WINAPI UninitializeFlatSB(HWND);
711 /* Subclassing stuff */
712 typedef LRESULT (CALLBACK *SUBCLASSPROC)(HWND, UINT, WPARAM, LPARAM, UINT_PTR, DWORD_PTR);
713 BOOL WINAPI SetWindowSubclass(HWND, SUBCLASSPROC, UINT_PTR, DWORD_PTR);
714 BOOL WINAPI GetWindowSubclass(HWND, SUBCLASSPROC, UINT_PTR, DWORD_PTR*);
715 BOOL WINAPI RemoveWindowSubclass(HWND, SUBCLASSPROC, UINT_PTR);
716 LRESULT WINAPI DefSubclassProc(HWND, UINT, WPARAM, LPARAM);
718 int WINAPI DrawShadowText(HDC, LPCWSTR, UINT, RECT*, DWORD, COLORREF, COLORREF, int, int);
720 /* Header control */
722 #define WC_HEADERA "SysHeader32"
723 #if defined(__GNUC__)
724 # define WC_HEADERW (const WCHAR []){ 'S','y','s','H','e','a','d','e','r','3','2',0 }
725 #elif defined(_MSC_VER)
726 # define WC_HEADERW L"SysHeader32"
727 #else
728 static const WCHAR WC_HEADERW[] = { 'S','y','s','H','e','a','d','e','r','3','2',0 };
729 #endif
730 #define WC_HEADER WINELIB_NAME_AW(WC_HEADER)
732 #define HDS_HORZ 0x0000
733 #define HDS_BUTTONS 0x0002
734 #define HDS_HOTTRACK 0x0004
735 #define HDS_HIDDEN 0x0008
736 #define HDS_DRAGDROP 0x0040
737 #define HDS_FULLDRAG 0x0080
738 #define HDS_FILTERBAR 0x0100
739 #define HDS_FLAT 0x0200
740 #define HDS_CHECKBOXES 0x0400
741 #define HDS_NOSIZING 0x0800
742 #define HDS_OVERFLOW 0x1000
744 #define HDI_WIDTH 0x0001
745 #define HDI_HEIGHT HDI_WIDTH
746 #define HDI_TEXT 0x0002
747 #define HDI_FORMAT 0x0004
748 #define HDI_LPARAM 0x0008
749 #define HDI_BITMAP 0x0010
750 #define HDI_IMAGE 0x0020
751 #define HDI_DI_SETITEM 0x0040
752 #define HDI_ORDER 0x0080
753 #define HDI_FILTER 0x0100
754 #define HDI_STATE 0x0200
756 #define HDIS_FOCUSED 0x00000001
758 #define HDF_LEFT 0x0000
759 #define HDF_RIGHT 0x0001
760 #define HDF_CENTER 0x0002
761 #define HDF_JUSTIFYMASK 0x0003
762 #define HDF_RTLREADING 0x0004
763 #define HDF_CHECKBOX 0x0040
764 #define HDF_CHECKED 0x0080
765 #define HDF_FIXEDWIDTH 0x0100
766 #define HDF_SORTDOWN 0x0200
767 #define HDF_SORTUP 0x0400
768 #define HDF_IMAGE 0x0800
769 #define HDF_BITMAP_ON_RIGHT 0x1000
770 #define HDF_BITMAP 0x2000
771 #define HDF_STRING 0x4000
772 #define HDF_OWNERDRAW 0x8000
773 #define HDF_SPLITBUTTON 0x1000000
775 #define HHT_NOWHERE 0x0001
776 #define HHT_ONHEADER 0x0002
777 #define HHT_ONDIVIDER 0x0004
778 #define HHT_ONDIVOPEN 0x0008
779 #define HHT_ONFILTER 0x0010
780 #define HHT_ONFILTERBUTTON 0x0020
781 #define HHT_ABOVE 0x0100
782 #define HHT_BELOW 0x0200
783 #define HHT_TORIGHT 0x0400
784 #define HHT_TOLEFT 0x0800
785 #define HHT_ONITEMSTATEICON 0x1000
786 #define HHT_ONDROPDOWN 0x2000
787 #define HHT_ONOVERFLOW 0x4000
789 #define HDM_FIRST 0x1200
790 #define HDM_GETITEMCOUNT (HDM_FIRST+0)
791 #define HDM_INSERTITEMA (HDM_FIRST+1)
792 #define HDM_INSERTITEMW (HDM_FIRST+10)
793 #define HDM_INSERTITEM WINELIB_NAME_AW(HDM_INSERTITEM)
794 #define HDM_DELETEITEM (HDM_FIRST+2)
795 #define HDM_GETITEMA (HDM_FIRST+3)
796 #define HDM_GETITEMW (HDM_FIRST+11)
797 #define HDM_GETITEM WINELIB_NAME_AW(HDM_GETITEM)
798 #define HDM_SETITEMA (HDM_FIRST+4)
799 #define HDM_SETITEMW (HDM_FIRST+12)
800 #define HDM_SETITEM WINELIB_NAME_AW(HDM_SETITEM)
801 #define HDM_LAYOUT (HDM_FIRST+5)
802 #define HDM_HITTEST (HDM_FIRST+6)
803 #define HDM_GETITEMRECT (HDM_FIRST+7)
804 #define HDM_SETIMAGELIST (HDM_FIRST+8)
805 #define HDM_GETIMAGELIST (HDM_FIRST+9)
807 #define HDM_ORDERTOINDEX (HDM_FIRST+15)
808 #define HDM_CREATEDRAGIMAGE (HDM_FIRST+16)
809 #define HDM_GETORDERARRAY (HDM_FIRST+17)
810 #define HDM_SETORDERARRAY (HDM_FIRST+18)
811 #define HDM_SETHOTDIVIDER (HDM_FIRST+19)
812 #define HDM_SETBITMAPMARGIN (HDM_FIRST+20)
813 #define HDM_GETBITMAPMARGIN (HDM_FIRST+21)
814 #define HDM_SETFILTERCHANGETIMEOUT (HDM_FIRST+22)
815 #define HDM_EDITFILTER (HDM_FIRST+23)
816 #define HDM_CLEARFILTER (HDM_FIRST+24)
817 #define HDM_GETUNICODEFORMAT CCM_GETUNICODEFORMAT
818 #define HDM_SETUNICODEFORMAT CCM_SETUNICODEFORMAT
820 #define HDN_FIRST (0U-300U)
821 #define HDN_LAST (0U-399U)
822 #define HDN_ITEMCHANGINGA (HDN_FIRST-0)
823 #define HDN_ITEMCHANGINGW (HDN_FIRST-20)
824 #define HDN_ITEMCHANGING WINELIB_NAME_AW(HDN_ITEMCHANGING)
825 #define HDN_ITEMCHANGEDA (HDN_FIRST-1)
826 #define HDN_ITEMCHANGEDW (HDN_FIRST-21)
827 #define HDN_ITEMCHANGED WINELIB_NAME_AW(HDN_ITEMCHANGED)
828 #define HDN_ITEMCLICKA (HDN_FIRST-2)
829 #define HDN_ITEMCLICKW (HDN_FIRST-22)
830 #define HDN_ITEMCLICK WINELIB_NAME_AW(HDN_ITEMCLICK)
831 #define HDN_ITEMDBLCLICKA (HDN_FIRST-3)
832 #define HDN_ITEMDBLCLICKW (HDN_FIRST-23)
833 #define HDN_ITEMDBLCLICK WINELIB_NAME_AW(HDN_ITEMDBLCLICK)
834 #define HDN_DIVIDERDBLCLICKA (HDN_FIRST-5)
835 #define HDN_DIVIDERDBLCLICKW (HDN_FIRST-25)
836 #define HDN_DIVIDERDBLCLICK WINELIB_NAME_AW(HDN_DIVIDERDBLCLICK)
837 #define HDN_BEGINTRACKA (HDN_FIRST-6)
838 #define HDN_BEGINTRACKW (HDN_FIRST-26)
839 #define HDN_BEGINTRACK WINELIB_NAME_AW(HDN_BEGINTRACK)
840 #define HDN_ENDTRACKA (HDN_FIRST-7)
841 #define HDN_ENDTRACKW (HDN_FIRST-27)
842 #define HDN_ENDTRACK WINELIB_NAME_AW(HDN_ENDTRACK)
843 #define HDN_TRACKA (HDN_FIRST-8)
844 #define HDN_TRACKW (HDN_FIRST-28)
845 #define HDN_TRACK WINELIB_NAME_AW(HDN_TRACK)
846 #define HDN_GETDISPINFOA (HDN_FIRST-9)
847 #define HDN_GETDISPINFOW (HDN_FIRST-29)
848 #define HDN_GETDISPINFO WINELIB_NAME_AW(HDN_GETDISPINFO)
849 #define HDN_BEGINDRAG (HDN_FIRST-10)
850 #define HDN_ENDDRAG (HDN_FIRST-11)
851 #define HDN_FILTERCHANGE (HDN_FIRST-12)
852 #define HDN_FILTERBTNCLICK (HDN_FIRST-13)
853 #define HDN_BEGINFILTEREDIT (HDN_FIRST-14)
854 #define HDN_ENDFILTEREDIT (HDN_FIRST-15)
855 #define HDN_ITEMSTATEICONCLICK (HDN_FIRST-16)
856 #define HDN_ITEMKEYDOWN (HDN_FIRST-17)
858 typedef struct _HD_LAYOUT
860 RECT *prc;
861 WINDOWPOS *pwpos;
862 } HDLAYOUT, *LPHDLAYOUT;
864 #define HD_LAYOUT HDLAYOUT
866 typedef struct _HD_ITEMA
868 UINT mask;
869 INT cxy;
870 LPSTR pszText;
871 HBITMAP hbm;
872 INT cchTextMax;
873 INT fmt;
874 LPARAM lParam;
875 /* (_WIN32_IE >= 0x0300) */
876 INT iImage;
877 INT iOrder;
878 /* (_WIN32_IE >= 0x0500) */
879 UINT type;
880 LPVOID pvFilter;
881 /* (_WIN32_WINNT >= 0x0600) */
882 UINT state;
883 } HDITEMA, *LPHDITEMA;
885 typedef struct _HD_ITEMW
887 UINT mask;
888 INT cxy;
889 LPWSTR pszText;
890 HBITMAP hbm;
891 INT cchTextMax;
892 INT fmt;
893 LPARAM lParam;
894 /* (_WIN32_IE >= 0x0300) */
895 INT iImage;
896 INT iOrder;
897 /* (_WIN32_IE >= 0x0500) */
898 UINT type;
899 LPVOID pvFilter;
900 /* (_WIN32_WINNT >= 0x0600) */
901 UINT state;
902 } HDITEMW, *LPHDITEMW;
904 #define HDITEM WINELIB_NAME_AW(HDITEM)
905 #define LPHDITEM WINELIB_NAME_AW(LPHDITEM)
906 #define HD_ITEM HDITEM
908 #define HDITEM_V1_SIZEA CCSIZEOF_STRUCT(HDITEMA, lParam)
909 #define HDITEM_V1_SIZEW CCSIZEOF_STRUCT(HDITEMW, lParam)
910 #define HDITEM_V1_SIZE WINELIB_NAME_AW(HDITEM_V1_SIZE)
912 #define HDFT_ISSTRING 0x0000
913 #define HDFT_ISNUMBER 0x0001
914 #define HDFT_HASNOVALUE 0x8000
916 typedef struct _HD_TEXTFILTERA
918 LPSTR pszText;
919 INT cchTextMax;
920 } HD_TEXTFILTERA, *LPHD_TEXTFILTERA;
922 typedef struct _HD_TEXTFILTERW
924 LPWSTR pszText;
925 INT cchTextMax;
926 } HD_TEXTFILTERW, *LPHD_TEXTFILTERW;
928 #define HD_TEXTFILTER WINELIB_NAME_AW(HD_TEXTFILTER)
929 #define HDTEXTFILTER WINELIB_NAME_AW(HD_TEXTFILTER)
930 #define LPHD_TEXTFILTER WINELIB_NAME_AW(LPHD_TEXTFILTER)
931 #define LPHDTEXTFILTER WINELIB_NAME_AW(LPHD_TEXTFILTER)
933 typedef struct _HD_HITTESTINFO
935 POINT pt;
936 UINT flags;
937 INT iItem;
938 } HDHITTESTINFO, *LPHDHITTESTINFO;
940 #define HD_HITTESTINFO HDHITTESTINFO
942 typedef struct tagNMHEADERA
944 NMHDR hdr;
945 INT iItem;
946 INT iButton;
947 HDITEMA *pitem;
948 } NMHEADERA, *LPNMHEADERA;
950 typedef struct tagNMHEADERW
952 NMHDR hdr;
953 INT iItem;
954 INT iButton;
955 HDITEMW *pitem;
956 } NMHEADERW, *LPNMHEADERW;
958 #define NMHEADER WINELIB_NAME_AW(NMHEADER)
959 #define LPNMHEADER WINELIB_NAME_AW(LPNMHEADER)
960 #define HD_NOTIFY NMHEADER
962 typedef struct tagNMHDDISPINFOA
964 NMHDR hdr;
965 INT iItem;
966 UINT mask;
967 LPSTR pszText;
968 INT cchTextMax;
969 INT iImage;
970 LPARAM lParam;
971 } NMHDDISPINFOA, *LPNMHDDISPINFOA;
973 typedef struct tagNMHDDISPINFOW
975 NMHDR hdr;
976 INT iItem;
977 UINT mask;
978 LPWSTR pszText;
979 INT cchTextMax;
980 INT iImage;
981 LPARAM lParam;
982 } NMHDDISPINFOW, *LPNMHDDISPINFOW;
984 #define NMHDDISPINFO WINELIB_NAME_AW(NMHDDISPINFO)
985 #define LPNMHDDISPINFO WINELIB_NAME_AW(LPNMHDDISPINFO)
987 typedef struct tagNMHDFILTERBTNCLICK
989 NMHDR hdr;
990 INT iItem;
991 RECT rc;
992 } NMHDFILTERBTNCLICK, *LPNMHDFILTERBTNCLICK;
994 #define Header_GetItemCount(hwndHD) \
995 (INT)SNDMSG((hwndHD),HDM_GETITEMCOUNT,0,0L)
996 #define Header_InsertItemA(hwndHD,i,phdi) \
997 (INT)SNDMSGA((hwndHD),HDM_INSERTITEMA,(WPARAM)(INT)(i),(LPARAM)(const HDITEMA*)(phdi))
998 #define Header_InsertItemW(hwndHD,i,phdi) \
999 (INT)SNDMSGW((hwndHD),HDM_INSERTITEMW,(WPARAM)(INT)(i),(LPARAM)(const HDITEMW*)(phdi))
1000 #define Header_InsertItem WINELIB_NAME_AW(Header_InsertItem)
1001 #define Header_DeleteItem(hwndHD,i) \
1002 (BOOL)SNDMSG((hwndHD),HDM_DELETEITEM,(WPARAM)(INT)(i),0L)
1003 #define Header_GetItemA(hwndHD,i,phdi) \
1004 (BOOL)SNDMSGA((hwndHD),HDM_GETITEMA,(WPARAM)(INT)(i),(LPARAM)(HDITEMA*)(phdi))
1005 #define Header_GetItemW(hwndHD,i,phdi) \
1006 (BOOL)SNDMSGW((hwndHD),HDM_GETITEMW,(WPARAM)(INT)(i),(LPARAM)(HDITEMW*)(phdi))
1007 #define Header_GetItem WINELIB_NAME_AW(Header_GetItem)
1008 #define Header_SetItemA(hwndHD,i,phdi) \
1009 (BOOL)SNDMSGA((hwndHD),HDM_SETITEMA,(WPARAM)(INT)(i),(LPARAM)(const HDITEMA*)(phdi))
1010 #define Header_SetItemW(hwndHD,i,phdi) \
1011 (BOOL)SNDMSGW((hwndHD),HDM_SETITEMW,(WPARAM)(INT)(i),(LPARAM)(const HDITEMW*)(phdi))
1012 #define Header_SetItem WINELIB_NAME_AW(Header_SetItem)
1013 #define Header_Layout(hwndHD,playout) \
1014 (BOOL)SNDMSG((hwndHD),HDM_LAYOUT,0,(LPARAM)(LPHDLAYOUT)(playout))
1015 #define Header_GetItemRect(hwnd,iItem,lprc) \
1016 (BOOL)SNDMSG((hwnd),HDM_GETITEMRECT,(WPARAM)iItem,(LPARAM)lprc)
1017 #define Header_SetImageList(hwnd,himl) \
1018 (HIMAGELIST)SNDMSG((hwnd),HDM_SETIMAGELIST,0,(LPARAM)himl)
1019 #define Header_GetImageList(hwnd) \
1020 (HIMAGELIST)SNDMSG((hwnd),HDM_GETIMAGELIST,0,0)
1021 #define Header_OrderToIndex(hwnd,i) \
1022 (INT)SNDMSG((hwnd),HDM_ORDERTOINDEX,(WPARAM)i,0)
1023 #define Header_CreateDragImage(hwnd,i) \
1024 (HIMAGELIST)SNDMSG((hwnd),HDM_CREATEDRAGIMAGE,(WPARAM)i,0)
1025 #define Header_GetOrderArray(hwnd,iCount,lpi) \
1026 (BOOL)SNDMSG((hwnd),HDM_GETORDERARRAY,(WPARAM)iCount,(LPARAM)lpi)
1027 #define Header_SetOrderArray(hwnd,iCount,lpi) \
1028 (BOOL)SNDMSG((hwnd),HDM_SETORDERARRAY,(WPARAM)iCount,(LPARAM)lpi)
1029 #define Header_SetHotDivider(hwnd,fPos,dw) \
1030 (INT)SNDMSG((hwnd),HDM_SETHOTDIVIDER,(WPARAM)fPos,(LPARAM)dw)
1031 #define Header_SetUnicodeFormat(hwnd,fUnicode) \
1032 (BOOL)SNDMSG((hwnd),HDM_SETUNICODEFORMAT,(WPARAM)(fUnicode),0)
1033 #define Header_GetUnicodeFormat(hwnd) \
1034 (BOOL)SNDMSG((hwnd),HDM_GETUNICODEFORMAT,0,0)
1036 /* Win32 5.1 Button Theme */
1037 #define WC_BUTTONA "Button"
1038 #if defined(__GNUC__)
1039 # define WC_BUTTONW (const WCHAR []){ 'B','u','t','t','o','n',0 }
1040 #elif defined(_MSC_VER)
1041 # define WC_BUTTONW L"Button"
1042 #else
1043 static const WCHAR WC_BUTTONW[] = { 'B','u','t','t','o','n',0 };
1044 #endif
1045 #define WC_BUTTON WINELIB_NAME_AW(WC_BUTTON)
1047 #define BCN_FIRST (0U-1250U)
1048 #define BCN_LAST (0U-1350U)
1050 #define BCN_HOTITEMCHANGE (BCN_FIRST + 0x0001)
1052 typedef struct tagNMBCHOTITEM
1054 NMHDR hdr;
1055 DWORD dwFlags;
1056 } NMBCHOTITEM, *LPNMBCHOTITEM;
1058 #define BST_HOT 0x0200
1060 /* Toolbar */
1062 #define TOOLBARCLASSNAMEA "ToolbarWindow32"
1063 #if defined(__GNUC__)
1064 # define TOOLBARCLASSNAMEW (const WCHAR []){ 'T','o','o','l','b','a','r', \
1065 'W','i','n','d','o','w','3','2',0 }
1066 #elif defined(_MSC_VER)
1067 # define TOOLBARCLASSNAMEW L"ToolbarWindow32"
1068 #else
1069 static const WCHAR TOOLBARCLASSNAMEW[] = { 'T','o','o','l','b','a','r',
1070 'W','i','n','d','o','w','3','2',0 };
1071 #endif
1072 #define TOOLBARCLASSNAME WINELIB_NAME_AW(TOOLBARCLASSNAME)
1074 #define CMB_MASKED 0x02
1076 #define TBSTATE_CHECKED 0x01
1077 #define TBSTATE_PRESSED 0x02
1078 #define TBSTATE_ENABLED 0x04
1079 #define TBSTATE_HIDDEN 0x08
1080 #define TBSTATE_INDETERMINATE 0x10
1081 #define TBSTATE_WRAP 0x20
1082 #define TBSTATE_ELLIPSES 0x40
1083 #define TBSTATE_MARKED 0x80
1086 /* as of _WIN32_IE >= 0x0500 the following symbols are obsolete,
1087 * "everyone" should use the BTNS_... stuff below
1089 #define TBSTYLE_BUTTON 0x00
1090 #define TBSTYLE_SEP 0x01
1091 #define TBSTYLE_CHECK 0x02
1092 #define TBSTYLE_GROUP 0x04
1093 #define TBSTYLE_CHECKGROUP (TBSTYLE_GROUP | TBSTYLE_CHECK)
1094 #define TBSTYLE_DROPDOWN 0x08
1095 #define TBSTYLE_AUTOSIZE 0x10
1096 #define TBSTYLE_NOPREFIX 0x20
1097 #define BTNS_BUTTON TBSTYLE_BUTTON
1098 #define BTNS_SEP TBSTYLE_SEP
1099 #define BTNS_CHECK TBSTYLE_CHECK
1100 #define BTNS_GROUP TBSTYLE_GROUP
1101 #define BTNS_CHECKGROUP TBSTYLE_CHECKGROUP
1102 #define BTNS_DROPDOWN TBSTYLE_DROPDOWN
1103 #define BTNS_AUTOSIZE TBSTYLE_AUTOSIZE
1104 #define BTNS_NOPREFIX TBSTYLE_NOPREFIX
1105 #define BTNS_SHOWTEXT 0x40 /* ignored unless TBSTYLE_EX_MIXEDB set */
1106 #define BTNS_WHOLEDROPDOWN 0x80 /* draw dropdown arrow, but without split arrow section */
1108 #define TBSTYLE_TOOLTIPS 0x0100
1109 #define TBSTYLE_WRAPABLE 0x0200
1110 #define TBSTYLE_ALTDRAG 0x0400
1111 #define TBSTYLE_FLAT 0x0800
1112 #define TBSTYLE_LIST 0x1000
1113 #define TBSTYLE_CUSTOMERASE 0x2000
1114 #define TBSTYLE_REGISTERDROP 0x4000
1115 #define TBSTYLE_TRANSPARENT 0x8000
1116 #define TBSTYLE_EX_DRAWDDARROWS 0x00000001
1117 #define TBSTYLE_EX_UNDOC1 0x00000004 /* similar to TBSTYLE_WRAPABLE */
1118 #define TBSTYLE_EX_MIXEDBUTTONS 0x00000008
1119 #define TBSTYLE_EX_HIDECLIPPEDBUTTONS 0x00000010 /* don't show partially obscured buttons */
1120 #define TBSTYLE_EX_DOUBLEBUFFER 0x00000080 /* Double Buffer the toolbar */
1122 #define TBIF_IMAGE 0x00000001
1123 #define TBIF_TEXT 0x00000002
1124 #define TBIF_STATE 0x00000004
1125 #define TBIF_STYLE 0x00000008
1126 #define TBIF_LPARAM 0x00000010
1127 #define TBIF_COMMAND 0x00000020
1128 #define TBIF_SIZE 0x00000040
1129 #define TBIF_BYINDEX 0x80000000
1131 #define TBBF_LARGE 0x0001
1133 #define TB_ENABLEBUTTON (WM_USER+1)
1134 #define TB_CHECKBUTTON (WM_USER+2)
1135 #define TB_PRESSBUTTON (WM_USER+3)
1136 #define TB_HIDEBUTTON (WM_USER+4)
1137 #define TB_INDETERMINATE (WM_USER+5)
1138 #define TB_MARKBUTTON (WM_USER+6)
1139 #define TB_ISBUTTONENABLED (WM_USER+9)
1140 #define TB_ISBUTTONCHECKED (WM_USER+10)
1141 #define TB_ISBUTTONPRESSED (WM_USER+11)
1142 #define TB_ISBUTTONHIDDEN (WM_USER+12)
1143 #define TB_ISBUTTONINDETERMINATE (WM_USER+13)
1144 #define TB_ISBUTTONHIGHLIGHTED (WM_USER+14)
1145 #define TB_SETSTATE (WM_USER+17)
1146 #define TB_GETSTATE (WM_USER+18)
1147 #define TB_ADDBITMAP (WM_USER+19)
1148 #define TB_ADDBUTTONSA (WM_USER+20)
1149 #define TB_ADDBUTTONSW (WM_USER+68)
1150 #define TB_ADDBUTTONS WINELIB_NAME_AW(TB_ADDBUTTONS)
1151 #define TB_HITTEST (WM_USER+69)
1152 #define TB_INSERTBUTTONA (WM_USER+21)
1153 #define TB_INSERTBUTTONW (WM_USER+67)
1154 #define TB_INSERTBUTTON WINELIB_NAME_AW(TB_INSERTBUTTON)
1155 #define TB_DELETEBUTTON (WM_USER+22)
1156 #define TB_GETBUTTON (WM_USER+23)
1157 #define TB_BUTTONCOUNT (WM_USER+24)
1158 #define TB_COMMANDTOINDEX (WM_USER+25)
1159 #define TB_SAVERESTOREA (WM_USER+26)
1160 #define TB_SAVERESTOREW (WM_USER+76)
1161 #define TB_SAVERESTORE WINELIB_NAME_AW(TB_SAVERESTORE)
1162 #define TB_CUSTOMIZE (WM_USER+27)
1163 #define TB_ADDSTRINGA (WM_USER+28)
1164 #define TB_ADDSTRINGW (WM_USER+77)
1165 #define TB_ADDSTRING WINELIB_NAME_AW(TB_ADDSTRING)
1166 #define TB_GETITEMRECT (WM_USER+29)
1167 #define TB_BUTTONSTRUCTSIZE (WM_USER+30)
1168 #define TB_SETBUTTONSIZE (WM_USER+31)
1169 #define TB_SETBITMAPSIZE (WM_USER+32)
1170 #define TB_AUTOSIZE (WM_USER+33)
1171 #define TB_GETTOOLTIPS (WM_USER+35)
1172 #define TB_SETTOOLTIPS (WM_USER+36)
1173 #define TB_SETPARENT (WM_USER+37)
1174 #define TB_SETROWS (WM_USER+39)
1175 #define TB_GETROWS (WM_USER+40)
1176 #define TB_GETBITMAPFLAGS (WM_USER+41)
1177 #define TB_SETCMDID (WM_USER+42)
1178 #define TB_CHANGEBITMAP (WM_USER+43)
1179 #define TB_GETBITMAP (WM_USER+44)
1180 #define TB_GETBUTTONTEXTA (WM_USER+45)
1181 #define TB_GETBUTTONTEXTW (WM_USER+75)
1182 #define TB_GETBUTTONTEXT WINELIB_NAME_AW(TB_GETBUTTONTEXT)
1183 #define TB_REPLACEBITMAP (WM_USER+46)
1184 #define TB_SETINDENT (WM_USER+47)
1185 #define TB_SETIMAGELIST (WM_USER+48)
1186 #define TB_GETIMAGELIST (WM_USER+49)
1187 #define TB_LOADIMAGES (WM_USER+50)
1188 #define TB_GETRECT (WM_USER+51) /* wParam is the Cmd instead of index */
1189 #define TB_SETHOTIMAGELIST (WM_USER+52)
1190 #define TB_GETHOTIMAGELIST (WM_USER+53)
1191 #define TB_SETDISABLEDIMAGELIST (WM_USER+54)
1192 #define TB_GETDISABLEDIMAGELIST (WM_USER+55)
1193 #define TB_SETSTYLE (WM_USER+56)
1194 #define TB_GETSTYLE (WM_USER+57)
1195 #define TB_GETBUTTONSIZE (WM_USER+58)
1196 #define TB_SETBUTTONWIDTH (WM_USER+59)
1197 #define TB_SETMAXTEXTROWS (WM_USER+60)
1198 #define TB_GETTEXTROWS (WM_USER+61)
1199 #define TB_GETOBJECT (WM_USER+62)
1200 #define TB_GETBUTTONINFOW (WM_USER+63)
1201 #define TB_GETBUTTONINFOA (WM_USER+65)
1202 #define TB_GETBUTTONINFO WINELIB_NAME_AW(TB_GETBUTTONINFO)
1203 #define TB_SETBUTTONINFOW (WM_USER+64)
1204 #define TB_SETBUTTONINFOA (WM_USER+66)
1205 #define TB_SETBUTTONINFO WINELIB_NAME_AW(TB_SETBUTTONINFO)
1206 #define TB_SETDRAWTEXTFLAGS (WM_USER+70)
1207 #define TB_GETHOTITEM (WM_USER+71)
1208 #define TB_SETHOTITEM (WM_USER+72)
1209 #define TB_SETANCHORHIGHLIGHT (WM_USER+73)
1210 #define TB_GETANCHORHIGHLIGHT (WM_USER+74)
1211 #define TB_MAPACCELERATORA (WM_USER+78)
1212 #define TB_MAPACCELERATORW (WM_USER+90)
1213 #define TB_MAPACCELERATOR WINELIB_NAME_AW(TB_MAPACCELERATOR)
1214 #define TB_GETINSERTMARK (WM_USER+79)
1215 #define TB_SETINSERTMARK (WM_USER+80)
1216 #define TB_INSERTMARKHITTEST (WM_USER+81)
1217 #define TB_MOVEBUTTON (WM_USER+82)
1218 #define TB_GETMAXSIZE (WM_USER+83)
1219 #define TB_SETEXTENDEDSTYLE (WM_USER+84)
1220 #define TB_GETEXTENDEDSTYLE (WM_USER+85)
1221 #define TB_GETPADDING (WM_USER+86)
1222 #define TB_SETPADDING (WM_USER+87)
1223 #define TB_SETINSERTMARKCOLOR (WM_USER+88)
1224 #define TB_GETINSERTMARKCOLOR (WM_USER+89)
1225 #define TB_SETCOLORSCHEME CCM_SETCOLORSCHEME
1226 #define TB_GETCOLORSCHEME CCM_GETCOLORSCHEME
1227 #define TB_SETUNICODEFORMAT CCM_SETUNICODEFORMAT
1228 #define TB_GETUNICODEFORMAT CCM_GETUNICODEFORMAT
1229 #define TB_GETSTRINGW (WM_USER+91)
1230 #define TB_GETSTRINGA (WM_USER+92)
1231 #define TB_GETSTRING WINELIB_NAME_AW(TB_GETSTRING)
1233 /* undocumented messages in Toolbar */
1234 #ifdef __WINESRC__
1235 #define TB_UNKWN45D (WM_USER+93)
1236 #define TB_SETHOTITEM2 (WM_USER+94)
1237 #define TB_SETLISTGAP (WM_USER+96)
1238 #define TB_GETIMAGELISTCOUNT (WM_USER+98)
1239 #define TB_GETIDEALSIZE (WM_USER+99)
1240 #define TB_UNKWN464 (WM_USER+100)
1241 #endif
1243 #define TB_GETMETRICS (WM_USER+101)
1244 #define TB_SETMETRICS (WM_USER+102)
1245 #define TB_SETWINDOWTHEME CCM_SETWINDOWTHEME
1247 #define TBN_FIRST (0U-700U)
1248 #define TBN_LAST (0U-720U)
1249 #define TBN_GETBUTTONINFOA (TBN_FIRST-0)
1250 #define TBN_GETBUTTONINFOW (TBN_FIRST-20)
1251 #define TBN_GETBUTTONINFO WINELIB_NAME_AW(TBN_GETBUTTONINFO)
1252 #define TBN_BEGINDRAG (TBN_FIRST-1)
1253 #define TBN_ENDDRAG (TBN_FIRST-2)
1254 #define TBN_BEGINADJUST (TBN_FIRST-3)
1255 #define TBN_ENDADJUST (TBN_FIRST-4)
1256 #define TBN_RESET (TBN_FIRST-5)
1257 #define TBN_QUERYINSERT (TBN_FIRST-6)
1258 #define TBN_QUERYDELETE (TBN_FIRST-7)
1259 #define TBN_TOOLBARCHANGE (TBN_FIRST-8)
1260 #define TBN_CUSTHELP (TBN_FIRST-9)
1261 #define TBN_DROPDOWN (TBN_FIRST-10)
1262 #define TBN_GETOBJECT (TBN_FIRST-12)
1263 #define TBN_HOTITEMCHANGE (TBN_FIRST-13)
1264 #define TBN_DRAGOUT (TBN_FIRST-14)
1265 #define TBN_DELETINGBUTTON (TBN_FIRST-15)
1266 #define TBN_GETDISPINFOA (TBN_FIRST-16)
1267 #define TBN_GETDISPINFOW (TBN_FIRST-17)
1268 #define TBN_GETDISPINFO WINELIB_NAME_AW(TBN_GETDISPINFO)
1269 #define TBN_GETINFOTIPA (TBN_FIRST-18)
1270 #define TBN_GETINFOTIPW (TBN_FIRST-19)
1271 #define TBN_GETINFOTIP WINELIB_NAME_AW(TBN_GETINFOTIP)
1272 #define TBN_RESTORE (TBN_FIRST-21)
1273 #define TBN_SAVE (TBN_FIRST-22)
1274 #define TBN_INITCUSTOMIZE (TBN_FIRST-23)
1275 #define TBN_WRAPHOTITEM (TBN_FIRST-24) /* this is undocumented and the name is a guess */
1276 #define TBNRF_HIDEHELP 0x00000001
1279 /* Return values from TBN_DROPDOWN */
1280 #define TBDDRET_DEFAULT 0
1281 #define TBDDRET_NODEFAULT 1
1282 #define TBDDRET_TREATPRESSED 2
1284 typedef struct _NMTBCUSTOMDRAW
1286 NMCUSTOMDRAW nmcd;
1287 HBRUSH hbrMonoDither;
1288 HBRUSH hbrLines;
1289 HPEN hpenLines;
1290 COLORREF clrText;
1291 COLORREF clrMark;
1292 COLORREF clrTextHighlight;
1293 COLORREF clrBtnFace;
1294 COLORREF clrBtnHighlight;
1295 COLORREF clrHighlightHotTrack;
1296 RECT rcText;
1297 int nStringBkMode;
1298 int nHLStringBkMode;
1299 int iListGap;
1300 } NMTBCUSTOMDRAW, *LPNMTBCUSTOMDRAW;
1302 /* return flags for Toolbar NM_CUSTOMDRAW notifications */
1303 #define TBCDRF_NOEDGES 0x00010000 /* Don't draw button edges */
1304 #define TBCDRF_HILITEHOTTRACK 0x00020000 /* Use color of the button bkgnd */
1305 /* when hottracked */
1306 #define TBCDRF_NOOFFSET 0x00040000 /* No offset button if pressed */
1307 #define TBCDRF_NOMARK 0x00080000 /* Don't draw default highlight */
1308 /* for TBSTATE_MARKED */
1309 #define TBCDRF_NOETCHEDEFFECT 0x00100000 /* No etched effect for */
1310 /* disabled items */
1311 #define TBCDRF_BLENDICON 0x00200000 /* ILD_BLEND50 on the icon image */
1312 #define TBCDRF_NOBACKGROUND 0x00400000 /* ILD_BLEND50 on the icon image */
1313 #define TBCDRF_USECDCOLORS 0x00800000
1316 /* This is just for old CreateToolbar. */
1317 /* Don't use it in new programs. */
1318 typedef struct _OLDTBBUTTON {
1319 INT iBitmap;
1320 INT idCommand;
1321 BYTE fsState;
1322 BYTE fsStyle;
1323 BYTE bReserved[2];
1324 DWORD dwData;
1325 } OLDTBBUTTON, *POLDTBBUTTON, *LPOLDTBBUTTON;
1326 typedef const OLDTBBUTTON *LPCOLDTBBUTTON;
1329 typedef struct _TBBUTTON {
1330 INT iBitmap;
1331 INT idCommand;
1332 BYTE fsState;
1333 BYTE fsStyle;
1334 #ifdef _WIN64
1335 BYTE bReserved[6];
1336 #else
1337 BYTE bReserved[2];
1338 #endif
1339 DWORD_PTR dwData;
1340 INT_PTR iString;
1341 } TBBUTTON, *PTBBUTTON, *LPTBBUTTON;
1342 typedef const TBBUTTON *LPCTBBUTTON;
1345 typedef struct _COLORMAP {
1346 COLORREF from;
1347 COLORREF to;
1348 } COLORMAP, *LPCOLORMAP;
1351 typedef struct tagTBADDBITMAP {
1352 HINSTANCE hInst;
1353 UINT_PTR nID;
1354 } TBADDBITMAP, *LPTBADDBITMAP;
1356 #define HINST_COMMCTRL ((HINSTANCE)-1)
1357 #define IDB_STD_SMALL_COLOR 0
1358 #define IDB_STD_LARGE_COLOR 1
1359 #define IDB_VIEW_SMALL_COLOR 4
1360 #define IDB_VIEW_LARGE_COLOR 5
1361 #define IDB_HIST_SMALL_COLOR 8
1362 #define IDB_HIST_LARGE_COLOR 9
1364 #define STD_CUT 0
1365 #define STD_COPY 1
1366 #define STD_PASTE 2
1367 #define STD_UNDO 3
1368 #define STD_REDOW 4
1369 #define STD_DELETE 5
1370 #define STD_FILENEW 6
1371 #define STD_FILEOPEN 7
1372 #define STD_FILESAVE 8
1373 #define STD_PRINTPRE 9
1374 #define STD_PROPERTIES 10
1375 #define STD_HELP 11
1376 #define STD_FIND 12
1377 #define STD_REPLACE 13
1378 #define STD_PRINT 14
1380 #define VIEW_LARGEICONS 0
1381 #define VIEW_SMALLICONS 1
1382 #define VIEW_LIST 2
1383 #define VIEW_DETAILS 3
1384 #define VIEW_SORTNAME 4
1385 #define VIEW_SORTSIZE 5
1386 #define VIEW_SORTDATE 6
1387 #define VIEW_SORTTYPE 7
1388 #define VIEW_PARENTFOLDER 8
1389 #define VIEW_NETCONNECT 9
1390 #define VIEW_NETDISCONNECT 10
1391 #define VIEW_NEWFOLDER 11
1392 #define VIEW_VIEWMENU 12
1394 #define HIST_BACK 0
1395 #define HIST_FORWARD 1
1396 #define HIST_FAVORITES 2
1397 #define HIST_ADDTOFAVORITES 3
1398 #define HIST_VIEWTREE 4
1400 typedef struct tagTBSAVEPARAMSA {
1401 HKEY hkr;
1402 LPCSTR pszSubKey;
1403 LPCSTR pszValueName;
1404 } TBSAVEPARAMSA, *LPTBSAVEPARAMSA;
1406 typedef struct tagTBSAVEPARAMSW {
1407 HKEY hkr;
1408 LPCWSTR pszSubKey;
1409 LPCWSTR pszValueName;
1410 } TBSAVEPARAMSW, *LPTBSAVEPARAMSW;
1412 #define TBSAVEPARAMS WINELIB_NAME_AW(TBSAVEPARAMS)
1413 #define LPTBSAVEPARAMS WINELIB_NAME_AW(LPTBSAVEPARAMS)
1415 typedef struct
1417 UINT cbSize;
1418 DWORD dwMask;
1419 INT idCommand;
1420 INT iImage;
1421 BYTE fsState;
1422 BYTE fsStyle;
1423 WORD cx;
1424 DWORD_PTR lParam;
1425 LPSTR pszText;
1426 INT cchText;
1427 } TBBUTTONINFOA, *LPTBBUTTONINFOA;
1429 typedef struct
1431 UINT cbSize;
1432 DWORD dwMask;
1433 INT idCommand;
1434 INT iImage;
1435 BYTE fsState;
1436 BYTE fsStyle;
1437 WORD cx;
1438 DWORD_PTR lParam;
1439 LPWSTR pszText;
1440 INT cchText;
1441 } TBBUTTONINFOW, *LPTBBUTTONINFOW;
1443 #define TBBUTTONINFO WINELIB_NAME_AW(TBBUTTONINFO)
1444 #define LPTBBUTTONINFO WINELIB_NAME_AW(LPTBBUTTONINFO)
1446 typedef struct tagNMTBHOTITEM
1448 NMHDR hdr;
1449 int idOld;
1450 int idNew;
1451 DWORD dwFlags;
1452 } NMTBHOTITEM, *LPNMTBHOTITEM;
1454 typedef struct tagNMTBGETINFOTIPA
1456 NMHDR hdr;
1457 LPSTR pszText;
1458 INT cchTextMax;
1459 INT iItem;
1460 LPARAM lParam;
1461 } NMTBGETINFOTIPA, *LPNMTBGETINFOTIPA;
1463 typedef struct tagNMTBGETINFOTIPW
1465 NMHDR hdr;
1466 LPWSTR pszText;
1467 INT cchTextMax;
1468 INT iItem;
1469 LPARAM lParam;
1470 } NMTBGETINFOTIPW, *LPNMTBGETINFOTIPW;
1472 #define NMTBGETINFOTIP WINELIB_NAME_AW(NMTBGETINFOTIP)
1473 #define LPNMTBGETINFOTIP WINELIB_NAME_AW(LPNMTBGETINFOTIP)
1475 typedef struct
1477 NMHDR hdr;
1478 DWORD dwMask;
1479 int idCommand;
1480 DWORD_PTR lParam;
1481 int iImage;
1482 LPSTR pszText;
1483 int cchText;
1484 } NMTBDISPINFOA, *LPNMTBDISPINFOA;
1486 typedef struct
1488 NMHDR hdr;
1489 DWORD dwMask;
1490 int idCommand;
1491 DWORD_PTR lParam;
1492 int iImage;
1493 LPWSTR pszText;
1494 int cchText;
1495 } NMTBDISPINFOW, *LPNMTBDISPINFOW;
1497 #define NMTBDISPINFO WINELIB_NAME_AW(NMTBDISPINFO)
1498 #define LPNMTBDISPINFO WINELIB_NAME_AW(LPNMTBDISPINFO)
1500 /* contents of dwMask in the NMTBDISPINFO structure */
1501 #define TBNF_IMAGE 0x00000001
1502 #define TBNF_TEXT 0x00000002
1503 #define TBNF_DI_SETITEM 0x10000000
1506 typedef struct tagNMTOOLBARA
1508 NMHDR hdr;
1509 INT iItem;
1510 TBBUTTON tbButton;
1511 INT cchText;
1512 LPSTR pszText;
1513 RECT rcButton; /* Version 5.80 */
1514 } NMTOOLBARA, *LPNMTOOLBARA, TBNOTIFYA, *LPTBNOTIFYA;
1516 typedef struct tagNMTOOLBARW
1518 NMHDR hdr;
1519 INT iItem;
1520 TBBUTTON tbButton;
1521 INT cchText;
1522 LPWSTR pszText;
1523 RECT rcButton; /* Version 5.80 */
1524 } NMTOOLBARW, *LPNMTOOLBARW, TBNOTIFYW, *LPTBNOTIFYW;
1526 #define NMTOOLBAR WINELIB_NAME_AW(NMTOOLBAR)
1527 #define LPNMTOOLBAR WINELIB_NAME_AW(LPNMTOOLBAR)
1528 #define TBNOTIFY WINELIB_NAME_AW(TBNOTIFY)
1529 #define LPTBNOTIFY WINELIB_NAME_AW(LPTBNOTIFY)
1531 typedef struct
1533 HINSTANCE hInstOld;
1534 UINT_PTR nIDOld;
1535 HINSTANCE hInstNew;
1536 UINT_PTR nIDNew;
1537 INT nButtons;
1538 } TBREPLACEBITMAP, *LPTBREPLACEBITMAP;
1540 #define HICF_OTHER 0x00000000
1541 #define HICF_MOUSE 0x00000001 /* Triggered by mouse */
1542 #define HICF_ARROWKEYS 0x00000002 /* Triggered by arrow keys */
1543 #define HICF_ACCELERATOR 0x00000004 /* Triggered by accelerator */
1544 #define HICF_DUPACCEL 0x00000008 /* This accelerator is not unique */
1545 #define HICF_ENTERING 0x00000010 /* idOld is invalid */
1546 #define HICF_LEAVING 0x00000020 /* idNew is invalid */
1547 #define HICF_RESELECT 0x00000040 /* hot item reselected */
1548 #define HICF_LMOUSE 0x00000080 /* left mouse button selected */
1549 #define HICF_TOGGLEDROPDOWN 0x00000100 /* Toggle button's dropdown state */
1551 typedef struct
1553 int iButton;
1554 DWORD dwFlags;
1555 } TBINSERTMARK, *LPTBINSERTMARK;
1556 #define TBIMHT_AFTER 0x00000001 /* TRUE = insert After iButton, otherwise before */
1557 #define TBIMHT_BACKGROUND 0x00000002 /* TRUE if and only if missed buttons completely */
1559 typedef struct tagNMTBSAVE
1561 NMHDR hdr;
1562 DWORD* pData;
1563 DWORD* pCurrent;
1564 UINT cbData;
1565 int iItem;
1566 int cButtons;
1567 TBBUTTON tbButton;
1568 } NMTBSAVE, *LPNMTBSAVE;
1570 typedef struct tagNMTBRESTORE
1572 NMHDR hdr;
1573 DWORD* pData;
1574 DWORD* pCurrent;
1575 UINT cbData;
1576 int iItem;
1577 int cButtons;
1578 int cbBytesPerRecord;
1579 TBBUTTON tbButton;
1580 } NMTBRESTORE, *LPNMTBRESTORE;
1582 #define TBMF_PAD 0x00000001
1583 #define TBMF_BARPAD 0x00000002
1584 #define TBMF_BUTTONSPACING 0x00000004
1586 typedef struct
1588 UINT cbSize;
1589 DWORD dwMask;
1590 INT cxPad;
1591 INT cyPad;
1592 INT cxBarPad;
1593 INT cyBarPad;
1594 INT cxButtonSpacing;
1595 INT cyButtonSpacing;
1596 } TBMETRICS, *LPTBMETRICS;
1598 /* these are undocumented and the names are guesses */
1599 typedef struct
1601 NMHDR hdr;
1602 HWND hwndDialog;
1603 } NMTBINITCUSTOMIZE;
1605 typedef struct
1607 NMHDR hdr;
1608 INT idNew;
1609 INT iDirection; /* left is -1, right is 1 */
1610 DWORD dwReason; /* HICF_* */
1611 } NMTBWRAPHOTITEM;
1614 HWND WINAPI
1615 CreateToolbar(HWND, DWORD, UINT, INT, HINSTANCE,
1616 UINT, LPCTBBUTTON, INT);
1618 HWND WINAPI
1619 CreateToolbarEx(HWND, DWORD, UINT, INT,
1620 HINSTANCE, UINT_PTR, LPCTBBUTTON,
1621 INT, INT, INT, INT, INT, UINT);
1623 HBITMAP WINAPI
1624 CreateMappedBitmap (HINSTANCE, INT_PTR, UINT, LPCOLORMAP, INT);
1627 /* Tool tips */
1629 #define TOOLTIPS_CLASSA "tooltips_class32"
1630 #if defined(__GNUC__)
1631 # define TOOLTIPS_CLASSW (const WCHAR []){ 't','o','o','l','t','i','p','s','_', \
1632 'c','l','a','s','s','3','2',0 }
1633 #elif defined(_MSC_VER)
1634 # define TOOLTIPS_CLASSW L"tooltips_class32"
1635 #else
1636 static const WCHAR TOOLTIPS_CLASSW[] = { 't','o','o','l','t','i','p','s','_',
1637 'c','l','a','s','s','3','2',0 };
1638 #endif
1639 #define TOOLTIPS_CLASS WINELIB_NAME_AW(TOOLTIPS_CLASS)
1641 #define INFOTIPSIZE 1024
1643 #define TTS_ALWAYSTIP 0x01
1644 #define TTS_NOPREFIX 0x02
1645 #define TTS_NOANIMATE 0x10
1646 #define TTS_NOFADE 0x20
1647 #define TTS_BALLOON 0x40
1648 #define TTS_CLOSE 0x80
1649 #define TTS_USEVISUALSTYLE 0x100
1651 #define TTF_IDISHWND 0x0001
1652 #define TTF_CENTERTIP 0x0002
1653 #define TTF_RTLREADING 0x0004
1654 #define TTF_SUBCLASS 0x0010
1655 #define TTF_TRACK 0x0020
1656 #define TTF_ABSOLUTE 0x0080
1657 #define TTF_TRANSPARENT 0x0100
1658 #define TTF_DI_SETITEM 0x8000 /* valid only on the TTN_NEEDTEXT callback */
1661 #define TTDT_AUTOMATIC 0
1662 #define TTDT_RESHOW 1
1663 #define TTDT_AUTOPOP 2
1664 #define TTDT_INITIAL 3
1667 #define TTI_NONE 0
1668 #define TTI_INFO 1
1669 #define TTI_WARNING 2
1670 #define TTI_ERROR 3
1673 #define TTM_ACTIVATE (WM_USER+1)
1674 #define TTM_SETDELAYTIME (WM_USER+3)
1675 #define TTM_ADDTOOLA (WM_USER+4)
1676 #define TTM_ADDTOOLW (WM_USER+50)
1677 #define TTM_ADDTOOL WINELIB_NAME_AW(TTM_ADDTOOL)
1678 #define TTM_DELTOOLA (WM_USER+5)
1679 #define TTM_DELTOOLW (WM_USER+51)
1680 #define TTM_DELTOOL WINELIB_NAME_AW(TTM_DELTOOL)
1681 #define TTM_NEWTOOLRECTA (WM_USER+6)
1682 #define TTM_NEWTOOLRECTW (WM_USER+52)
1683 #define TTM_NEWTOOLRECT WINELIB_NAME_AW(TTM_NEWTOOLRECT)
1684 #define TTM_RELAYEVENT (WM_USER+7)
1685 #define TTM_GETTOOLINFOA (WM_USER+8)
1686 #define TTM_GETTOOLINFOW (WM_USER+53)
1687 #define TTM_GETTOOLINFO WINELIB_NAME_AW(TTM_GETTOOLINFO)
1688 #define TTM_SETTOOLINFOA (WM_USER+9)
1689 #define TTM_SETTOOLINFOW (WM_USER+54)
1690 #define TTM_SETTOOLINFO WINELIB_NAME_AW(TTM_SETTOOLINFO)
1691 #define TTM_HITTESTA (WM_USER+10)
1692 #define TTM_HITTESTW (WM_USER+55)
1693 #define TTM_HITTEST WINELIB_NAME_AW(TTM_HITTEST)
1694 #define TTM_GETTEXTA (WM_USER+11)
1695 #define TTM_GETTEXTW (WM_USER+56)
1696 #define TTM_GETTEXT WINELIB_NAME_AW(TTM_GETTEXT)
1697 #define TTM_UPDATETIPTEXTA (WM_USER+12)
1698 #define TTM_UPDATETIPTEXTW (WM_USER+57)
1699 #define TTM_UPDATETIPTEXT WINELIB_NAME_AW(TTM_UPDATETIPTEXT)
1700 #define TTM_GETTOOLCOUNT (WM_USER+13)
1701 #define TTM_ENUMTOOLSA (WM_USER+14)
1702 #define TTM_ENUMTOOLSW (WM_USER+58)
1703 #define TTM_ENUMTOOLS WINELIB_NAME_AW(TTM_ENUMTOOLS)
1704 #define TTM_GETCURRENTTOOLA (WM_USER+15)
1705 #define TTM_GETCURRENTTOOLW (WM_USER+59)
1706 #define TTM_GETCURRENTTOOL WINELIB_NAME_AW(TTM_GETCURRENTTOOL)
1707 #define TTM_WINDOWFROMPOINT (WM_USER+16)
1708 #define TTM_TRACKACTIVATE (WM_USER+17)
1709 #define TTM_TRACKPOSITION (WM_USER+18)
1710 #define TTM_SETTIPBKCOLOR (WM_USER+19)
1711 #define TTM_SETTIPTEXTCOLOR (WM_USER+20)
1712 #define TTM_GETDELAYTIME (WM_USER+21)
1713 #define TTM_GETTIPBKCOLOR (WM_USER+22)
1714 #define TTM_GETTIPTEXTCOLOR (WM_USER+23)
1715 #define TTM_SETMAXTIPWIDTH (WM_USER+24)
1716 #define TTM_GETMAXTIPWIDTH (WM_USER+25)
1717 #define TTM_SETMARGIN (WM_USER+26)
1718 #define TTM_GETMARGIN (WM_USER+27)
1719 #define TTM_POP (WM_USER+28)
1720 #define TTM_UPDATE (WM_USER+29)
1721 #define TTM_GETBUBBLESIZE (WM_USER+30)
1722 #define TTM_ADJUSTRECT (WM_USER+31)
1723 #define TTM_SETTITLEA (WM_USER+32)
1724 #define TTM_SETTITLEW (WM_USER+33)
1725 #define TTM_SETTITLE WINELIB_NAME_AW(TTM_SETTITLE)
1726 #define TTM_POPUP (WM_USER+34)
1727 #define TTM_GETTITLE (WM_USER+35)
1728 #define TTM_SETWINDOWTHEME CCM_SETWINDOWTHEME
1731 #define TTN_FIRST (0U-520U)
1732 #define TTN_LAST (0U-549U)
1733 #define TTN_GETDISPINFOA (TTN_FIRST-0)
1734 #define TTN_GETDISPINFOW (TTN_FIRST-10)
1735 #define TTN_GETDISPINFO WINELIB_NAME_AW(TTN_GETDISPINFO)
1736 #define TTN_SHOW (TTN_FIRST-1)
1737 #define TTN_POP (TTN_FIRST-2)
1739 #define TTN_NEEDTEXT TTN_GETDISPINFO
1740 #define TTN_NEEDTEXTA TTN_GETDISPINFOA
1741 #define TTN_NEEDTEXTW TTN_GETDISPINFOW
1743 typedef struct tagTOOLINFOA {
1744 UINT cbSize;
1745 UINT uFlags;
1746 HWND hwnd;
1747 UINT_PTR uId;
1748 RECT rect;
1749 HINSTANCE hinst;
1750 LPSTR lpszText;
1751 LPARAM lParam;
1752 void *lpReserved;
1753 } TTTOOLINFOA, *LPTOOLINFOA, *PTOOLINFOA, *LPTTTOOLINFOA;
1755 typedef struct tagTOOLINFOW {
1756 UINT cbSize;
1757 UINT uFlags;
1758 HWND hwnd;
1759 UINT_PTR uId;
1760 RECT rect;
1761 HINSTANCE hinst;
1762 LPWSTR lpszText;
1763 LPARAM lParam;
1764 void *lpReserved;
1765 } TTTOOLINFOW, *LPTOOLINFOW, *PTOOLINFOW, *LPTTTOOLINFOW;
1767 #define TTTOOLINFO WINELIB_NAME_AW(TTTOOLINFO)
1768 #define TOOLINFO WINELIB_NAME_AW(TTTOOLINFO)
1769 #define PTOOLINFO WINELIB_NAME_AW(PTOOLINFO)
1770 #define LPTTTOOLINFO WINELIB_NAME_AW(LPTTTOOLINFO)
1771 #define LPTOOLINFO WINELIB_NAME_AW(LPTOOLINFO)
1773 #define TTTOOLINFOA_V1_SIZE CCSIZEOF_STRUCT(TTTOOLINFOA, lpszText)
1774 #define TTTOOLINFOW_V1_SIZE CCSIZEOF_STRUCT(TTTOOLINFOW, lpszText)
1775 #define TTTOOLINFO_V1_SIZE CCSIZEOF_STRUCT(WINELIB_NAME_AW(TTTOOLINFO), lpszText)
1777 typedef struct _TT_HITTESTINFOA
1779 HWND hwnd;
1780 POINT pt;
1781 TTTOOLINFOA ti;
1782 } TTHITTESTINFOA, *LPTTHITTESTINFOA;
1783 #define LPHITTESTINFOA LPTTHITTESTINFOA
1785 typedef struct _TT_HITTESTINFOW
1787 HWND hwnd;
1788 POINT pt;
1789 TTTOOLINFOW ti;
1790 } TTHITTESTINFOW, *LPTTHITTESTINFOW;
1791 #define LPHITTESTINFOW LPTTHITTESTINFOW
1793 #define TTHITTESTINFO WINELIB_NAME_AW(TTHITTESTINFO)
1794 #define LPTTHITTESTINFO WINELIB_NAME_AW(LPTTHITTESTINFO)
1795 #define LPHITTESTINFO WINELIB_NAME_AW(LPHITTESTINFO)
1797 typedef struct tagNMTTDISPINFOA
1799 NMHDR hdr;
1800 LPSTR lpszText;
1801 CHAR szText[80];
1802 HINSTANCE hinst;
1803 UINT uFlags;
1804 LPARAM lParam;
1805 } NMTTDISPINFOA, *LPNMTTDISPINFOA;
1807 typedef struct tagNMTTDISPINFOW
1809 NMHDR hdr;
1810 LPWSTR lpszText;
1811 WCHAR szText[80];
1812 HINSTANCE hinst;
1813 UINT uFlags;
1814 LPARAM lParam;
1815 } NMTTDISPINFOW, *LPNMTTDISPINFOW;
1817 #define NMTTDISPINFO WINELIB_NAME_AW(NMTTDISPINFO)
1818 #define LPNMTTDISPINFO WINELIB_NAME_AW(LPNMTTDISPINFO)
1820 #define NMTTDISPINFO_V1_SIZEA CCSIZEOF_STRUCT(NMTTDISPINFOA, uFlags)
1821 #define NMTTDISPINFO_V1_SIZEW CCSIZEOF_STRUCT(NMTTDISPINFOW, uFlags)
1822 #define NMTTDISPINFO_V1_SIZE WINELIB_NAME_AW(NMTTDISPINFO_V1_SIZE)
1824 typedef struct _TTGETTITLE
1826 DWORD dwSize;
1827 UINT uTitleBitmap;
1828 UINT cch;
1829 WCHAR* pszTitle;
1830 } TTGETTITLE, *PTTGETTITLE;
1832 #define TOOLTIPTEXTW NMTTDISPINFOW
1833 #define TOOLTIPTEXTA NMTTDISPINFOA
1834 #define TOOLTIPTEXT NMTTDISPINFO
1835 #define LPTOOLTIPTEXTW LPNMTTDISPINFOW
1836 #define LPTOOLTIPTEXTA LPNMTTDISPINFOA
1837 #define LPTOOLTIPTEXT LPNMTTDISPINFO
1840 /* Rebar control */
1842 #define REBARCLASSNAMEA "ReBarWindow32"
1843 #if defined(__GNUC__)
1844 # define REBARCLASSNAMEW (const WCHAR []){ 'R','e','B','a','r', \
1845 'W','i','n','d','o','w','3','2',0 }
1846 #elif defined(_MSC_VER)
1847 # define REBARCLASSNAMEW L"ReBarWindow32"
1848 #else
1849 static const WCHAR REBARCLASSNAMEW[] = { 'R','e','B','a','r',
1850 'W','i','n','d','o','w','3','2',0 };
1851 #endif
1852 #define REBARCLASSNAME WINELIB_NAME_AW(REBARCLASSNAME)
1854 #define RBS_TOOLTIPS 0x0100
1855 #define RBS_VARHEIGHT 0x0200
1856 #define RBS_BANDBORDERS 0x0400
1857 #define RBS_FIXEDORDER 0x0800
1858 #define RBS_REGISTERDROP 0x1000
1859 #define RBS_AUTOSIZE 0x2000
1860 #define RBS_VERTICALGRIPPER 0x4000
1861 #define RBS_DBLCLKTOGGLE 0x8000
1863 #define RBIM_IMAGELIST 0x00000001
1865 #define RBBIM_STYLE 0x00000001
1866 #define RBBIM_COLORS 0x00000002
1867 #define RBBIM_TEXT 0x00000004
1868 #define RBBIM_IMAGE 0x00000008
1869 #define RBBIM_CHILD 0x00000010
1870 #define RBBIM_CHILDSIZE 0x00000020
1871 #define RBBIM_SIZE 0x00000040
1872 #define RBBIM_BACKGROUND 0x00000080
1873 #define RBBIM_ID 0x00000100
1874 #define RBBIM_IDEALSIZE 0x00000200
1875 #define RBBIM_LPARAM 0x00000400
1876 #define RBBIM_HEADERSIZE 0x00000800
1878 #define RBBS_BREAK 0x00000001
1879 #define RBBS_FIXEDSIZE 0x00000002
1880 #define RBBS_CHILDEDGE 0x00000004
1881 #define RBBS_HIDDEN 0x00000008
1882 #define RBBS_NOVERT 0x00000010
1883 #define RBBS_FIXEDBMP 0x00000020
1884 #define RBBS_VARIABLEHEIGHT 0x00000040
1885 #define RBBS_GRIPPERALWAYS 0x00000080
1886 #define RBBS_NOGRIPPER 0x00000100
1887 #define RBBS_USECHEVRON 0x00000200
1888 #define RBBS_HIDETITLE 0x00000400
1889 #define RBBS_TOPALIGN 0x00000800
1891 #define RBNM_ID 0x00000001
1892 #define RBNM_STYLE 0x00000002
1893 #define RBNM_LPARAM 0x00000004
1895 #define RBHT_NOWHERE 0x0001
1896 #define RBHT_CAPTION 0x0002
1897 #define RBHT_CLIENT 0x0003
1898 #define RBHT_GRABBER 0x0004
1899 #define RBHT_CHEVRON 0x0008
1901 #define RB_INSERTBANDA (WM_USER+1)
1902 #define RB_INSERTBANDW (WM_USER+10)
1903 #define RB_INSERTBAND WINELIB_NAME_AW(RB_INSERTBAND)
1904 #define RB_DELETEBAND (WM_USER+2)
1905 #define RB_GETBARINFO (WM_USER+3)
1906 #define RB_SETBARINFO (WM_USER+4)
1907 #define RB_SETBANDINFOA (WM_USER+6)
1908 #define RB_SETBANDINFOW (WM_USER+11)
1909 #define RB_SETBANDINFO WINELIB_NAME_AW(RB_SETBANDINFO)
1910 #define RB_SETPARENT (WM_USER+7)
1911 #define RB_HITTEST (WM_USER+8)
1912 #define RB_GETRECT (WM_USER+9)
1913 #define RB_GETBANDCOUNT (WM_USER+12)
1914 #define RB_GETROWCOUNT (WM_USER+13)
1915 #define RB_GETROWHEIGHT (WM_USER+14)
1916 #define RB_IDTOINDEX (WM_USER+16)
1917 #define RB_GETTOOLTIPS (WM_USER+17)
1918 #define RB_SETTOOLTIPS (WM_USER+18)
1919 #define RB_SETBKCOLOR (WM_USER+19)
1920 #define RB_GETBKCOLOR (WM_USER+20)
1921 #define RB_SETTEXTCOLOR (WM_USER+21)
1922 #define RB_GETTEXTCOLOR (WM_USER+22)
1923 #define RB_SIZETORECT (WM_USER+23)
1924 #define RB_BEGINDRAG (WM_USER+24)
1925 #define RB_ENDDRAG (WM_USER+25)
1926 #define RB_DRAGMOVE (WM_USER+26)
1927 #define RB_GETBARHEIGHT (WM_USER+27)
1928 #define RB_GETBANDINFOW (WM_USER+28)
1929 #define RB_GETBANDINFOA (WM_USER+29)
1930 #define RB_GETBANDINFO WINELIB_NAME_AW(RB_GETBANDINFO)
1931 #define RB_MINIMIZEBAND (WM_USER+30)
1932 #define RB_MAXIMIZEBAND (WM_USER+31)
1933 #define RB_GETBANDBORDERS (WM_USER+34)
1934 #define RB_SHOWBAND (WM_USER+35)
1935 #define RB_SETPALETTE (WM_USER+37)
1936 #define RB_GETPALETTE (WM_USER+38)
1937 #define RB_MOVEBAND (WM_USER+39)
1938 #define RB_GETBANDMARGINS (WM_USER+40)
1939 #define RB_PUSHCHEVRON (WM_USER+43)
1940 #define RB_GETDROPTARGET CCM_GETDROPTARGET
1941 #define RB_SETCOLORSCHEME CCM_SETCOLORSCHEME
1942 #define RB_GETCOLORSCHEME CCM_GETCOLORSCHEME
1943 #define RB_SETUNICODEFORMAT CCM_SETUNICODEFORMAT
1944 #define RB_GETUNICODEFORMAT CCM_GETUNICODEFORMAT
1945 #define RB_SETWINDOWTHEME CCM_SETWINDOWTHEME
1947 #define RBN_FIRST (0U-831U)
1948 #define RBN_LAST (0U-859U)
1949 #define RBN_HEIGHTCHANGE (RBN_FIRST-0)
1950 #define RBN_GETOBJECT (RBN_FIRST-1)
1951 #define RBN_LAYOUTCHANGED (RBN_FIRST-2)
1952 #define RBN_AUTOSIZE (RBN_FIRST-3)
1953 #define RBN_BEGINDRAG (RBN_FIRST-4)
1954 #define RBN_ENDDRAG (RBN_FIRST-5)
1955 #define RBN_DELETINGBAND (RBN_FIRST-6)
1956 #define RBN_DELETEDBAND (RBN_FIRST-7)
1957 #define RBN_CHILDSIZE (RBN_FIRST-8)
1958 #define RBN_CHEVRONPUSHED (RBN_FIRST-10)
1959 #define RBN_MINMAX (RBN_FIRST-21)
1960 #define RBN_AUTOBREAK (RBN_FIRST-22)
1962 typedef struct tagREBARINFO
1964 UINT cbSize;
1965 UINT fMask;
1966 HIMAGELIST himl;
1967 } REBARINFO, *LPREBARINFO;
1969 typedef struct tagREBARBANDINFOA
1971 UINT cbSize;
1972 UINT fMask;
1973 UINT fStyle;
1974 COLORREF clrFore;
1975 COLORREF clrBack;
1976 LPSTR lpText;
1977 UINT cch;
1978 INT iImage;
1979 HWND hwndChild;
1980 UINT cxMinChild;
1981 UINT cyMinChild;
1982 UINT cx;
1983 HBITMAP hbmBack;
1984 UINT wID;
1985 UINT cyChild;
1986 UINT cyMaxChild;
1987 UINT cyIntegral;
1988 UINT cxIdeal;
1989 LPARAM lParam;
1990 UINT cxHeader;
1991 /* _WIN32_WINNT >= 0x0600 */
1992 RECT rcChevronLocation;
1993 UINT uChevronState;
1994 } REBARBANDINFOA, *LPREBARBANDINFOA;
1996 typedef REBARBANDINFOA const *LPCREBARBANDINFOA;
1998 typedef struct tagREBARBANDINFOW
2000 UINT cbSize;
2001 UINT fMask;
2002 UINT fStyle;
2003 COLORREF clrFore;
2004 COLORREF clrBack;
2005 LPWSTR lpText;
2006 UINT cch;
2007 INT iImage;
2008 HWND hwndChild;
2009 UINT cxMinChild;
2010 UINT cyMinChild;
2011 UINT cx;
2012 HBITMAP hbmBack;
2013 UINT wID;
2014 UINT cyChild;
2015 UINT cyMaxChild;
2016 UINT cyIntegral;
2017 UINT cxIdeal;
2018 LPARAM lParam;
2019 UINT cxHeader;
2020 /* _WIN32_WINNT >= 0x0600 */
2021 RECT rcChevronLocation;
2022 UINT uChevronState;
2023 } REBARBANDINFOW, *LPREBARBANDINFOW;
2025 typedef REBARBANDINFOW const *LPCREBARBANDINFOW;
2027 #define REBARBANDINFO WINELIB_NAME_AW(REBARBANDINFO)
2028 #define LPREBARBANDINFO WINELIB_NAME_AW(LPREBARBANDINFO)
2029 #define LPCREBARBANDINFO WINELIB_NAME_AW(LPCREBARBANDINFO)
2031 #define REBARBANDINFOA_V3_SIZE CCSIZEOF_STRUCT(REBARBANDINFOA, wID)
2032 #define REBARBANDINFOW_V3_SIZE CCSIZEOF_STRUCT(REBARBANDINFOW, wID)
2033 #define REBARBANDINFO_V3_SIZE CCSIZEOF_STRUCT(WINELIB_NAME_AW(REBARBANDINFO), wID)
2034 #define REBARBANDINFOA_V6_SIZE CCSIZEOF_STRUCT(REBARBANDINFOA, cxHeader)
2035 #define REBARBANDINFOW_V6_SIZE CCSIZEOF_STRUCT(REBARBANDINFOW, cxHeader)
2036 #define REBARBANDINFO_V6_SIZE CCSIZEOF_STRUCT(WINELIB_NAME_AW(REBARBANDINFO), cxHeader)
2038 typedef struct tagNMREBARCHILDSIZE
2040 NMHDR hdr;
2041 UINT uBand;
2042 UINT wID;
2043 RECT rcChild;
2044 RECT rcBand;
2045 } NMREBARCHILDSIZE, *LPNMREBARCHILDSIZE;
2047 typedef struct tagNMREBAR
2049 NMHDR hdr;
2050 DWORD dwMask;
2051 UINT uBand;
2052 UINT fStyle;
2053 UINT wID;
2054 LPARAM lParam;
2055 } NMREBAR, *LPNMREBAR;
2057 typedef struct tagNMRBAUTOSIZE
2059 NMHDR hdr;
2060 BOOL fChanged;
2061 RECT rcTarget;
2062 RECT rcActual;
2063 } NMRBAUTOSIZE, *LPNMRBAUTOSIZE;
2065 typedef struct tagNMREBARCHEVRON
2067 NMHDR hdr;
2068 UINT uBand;
2069 UINT wID;
2070 LPARAM lParam;
2071 RECT rc;
2072 LPARAM lParamNM;
2073 } NMREBARCHEVRON, *LPNMREBARCHEVRON;
2075 typedef struct _RB_HITTESTINFO
2077 POINT pt;
2078 UINT flags;
2079 INT iBand;
2080 } RBHITTESTINFO, *LPRBHITTESTINFO;
2082 #define RBAB_AUTOSIZE 0x0001
2083 #define RBAB_ADDBAND 0x0002
2085 typedef struct tagNMREBARAUTOBREAK
2087 NMHDR hdr;
2088 UINT uBand;
2089 UINT wID;
2090 LPARAM lParam;
2091 UINT uMsg;
2092 UINT fStyleCurrent;
2093 BOOL fAutoBreak;
2094 } NMREBARAUTOBREAK, *LPNMREBARAUTOBREAK;
2097 /* Trackbar control */
2099 #define TRACKBAR_CLASSA "msctls_trackbar32"
2100 #if defined(__GNUC__)
2101 # define TRACKBAR_CLASSW (const WCHAR []){ 'm','s','c','t','l','s','_', \
2102 't','r','a','c','k','b','a','r','3','2',0 }
2103 #elif defined(_MSC_VER)
2104 # define TRACKBAR_CLASSW L"msctls_trackbar32"
2105 #else
2106 static const WCHAR TRACKBAR_CLASSW[] = { 'm','s','c','t','l','s','_',
2107 't','r','a','c','k','b','a','r','3','2',0 };
2108 #endif
2109 #define TRACKBAR_CLASS WINELIB_NAME_AW(TRACKBAR_CLASS)
2111 #define TBS_AUTOTICKS 0x0001
2112 #define TBS_VERT 0x0002
2113 #define TBS_HORZ 0x0000
2114 #define TBS_TOP 0x0004
2115 #define TBS_BOTTOM 0x0000
2116 #define TBS_LEFT 0x0004
2117 #define TBS_RIGHT 0x0000
2118 #define TBS_BOTH 0x0008
2119 #define TBS_NOTICKS 0x0010
2120 #define TBS_ENABLESELRANGE 0x0020
2121 #define TBS_FIXEDLENGTH 0x0040
2122 #define TBS_NOTHUMB 0x0080
2123 #define TBS_TOOLTIPS 0x0100
2124 #define TBS_REVERSED 0x0200
2125 #define TBS_DOWNISLEFT 0x0400
2127 #define TBTS_TOP 0
2128 #define TBTS_LEFT 1
2129 #define TBTS_BOTTOM 2
2130 #define TBTS_RIGHT 3
2132 #define TB_LINEUP 0
2133 #define TB_LINEDOWN 1
2134 #define TB_PAGEUP 2
2135 #define TB_PAGEDOWN 3
2136 #define TB_THUMBPOSITION 4
2137 #define TB_THUMBTRACK 5
2138 #define TB_TOP 6
2139 #define TB_BOTTOM 7
2140 #define TB_ENDTRACK 8
2142 #define TBCD_TICS 0x0001
2143 #define TBCD_THUMB 0x0002
2144 #define TBCD_CHANNEL 0x0003
2146 #define TBM_GETPOS (WM_USER)
2147 #define TBM_GETRANGEMIN (WM_USER+1)
2148 #define TBM_GETRANGEMAX (WM_USER+2)
2149 #define TBM_GETTIC (WM_USER+3)
2150 #define TBM_SETTIC (WM_USER+4)
2151 #define TBM_SETPOS (WM_USER+5)
2152 #define TBM_SETRANGE (WM_USER+6)
2153 #define TBM_SETRANGEMIN (WM_USER+7)
2154 #define TBM_SETRANGEMAX (WM_USER+8)
2155 #define TBM_CLEARTICS (WM_USER+9)
2156 #define TBM_SETSEL (WM_USER+10)
2157 #define TBM_SETSELSTART (WM_USER+11)
2158 #define TBM_SETSELEND (WM_USER+12)
2159 #define TBM_GETPTICS (WM_USER+14)
2160 #define TBM_GETTICPOS (WM_USER+15)
2161 #define TBM_GETNUMTICS (WM_USER+16)
2162 #define TBM_GETSELSTART (WM_USER+17)
2163 #define TBM_GETSELEND (WM_USER+18)
2164 #define TBM_CLEARSEL (WM_USER+19)
2165 #define TBM_SETTICFREQ (WM_USER+20)
2166 #define TBM_SETPAGESIZE (WM_USER+21)
2167 #define TBM_GETPAGESIZE (WM_USER+22)
2168 #define TBM_SETLINESIZE (WM_USER+23)
2169 #define TBM_GETLINESIZE (WM_USER+24)
2170 #define TBM_GETTHUMBRECT (WM_USER+25)
2171 #define TBM_GETCHANNELRECT (WM_USER+26)
2172 #define TBM_SETTHUMBLENGTH (WM_USER+27)
2173 #define TBM_GETTHUMBLENGTH (WM_USER+28)
2174 #define TBM_SETTOOLTIPS (WM_USER+29)
2175 #define TBM_GETTOOLTIPS (WM_USER+30)
2176 #define TBM_SETTIPSIDE (WM_USER+31)
2177 #define TBM_SETBUDDY (WM_USER+32)
2178 #define TBM_GETBUDDY (WM_USER+33)
2179 #define TBM_SETUNICODEFORMAT CCM_SETUNICODEFORMAT
2180 #define TBM_GETUNICODEFORMAT CCM_GETUNICODEFORMAT
2183 /* Pager control */
2185 #define WC_PAGESCROLLERA "SysPager"
2186 #if defined(__GNUC__)
2187 # define WC_PAGESCROLLERW (const WCHAR []){ 'S','y','s','P','a','g','e','r',0 }
2188 #elif defined(_MSC_VER)
2189 # define WC_PAGESCROLLERW L"SysPager"
2190 #else
2191 static const WCHAR WC_PAGESCROLLERW[] = { 'S','y','s','P','a','g','e','r',0 };
2192 #endif
2193 #define WC_PAGESCROLLER WINELIB_NAME_AW(WC_PAGESCROLLER)
2195 #define PGS_VERT 0x00000000
2196 #define PGS_HORZ 0x00000001
2197 #define PGS_AUTOSCROLL 0x00000002
2198 #define PGS_DRAGNDROP 0x00000004
2200 #define PGF_INVISIBLE 0
2201 #define PGF_NORMAL 1
2202 #define PGF_GRAYED 2
2203 #define PGF_DEPRESSED 4
2204 #define PGF_HOT 8
2206 #define PGB_TOPORLEFT 0
2207 #define PGB_BOTTOMORRIGHT 1
2209 /* only used with PGN_SCROLL */
2210 #define PGF_SCROLLUP 1
2211 #define PGF_SCROLLDOWN 2
2212 #define PGF_SCROLLLEFT 4
2213 #define PGF_SCROLLRIGHT 8
2215 #define PGK_SHIFT 1
2216 #define PGK_CONTROL 2
2217 #define PGK_MENU 4
2219 /* only used with PGN_CALCSIZE */
2220 #define PGF_CALCWIDTH 1
2221 #define PGF_CALCHEIGHT 2
2223 #define PGM_FIRST 0x1400
2224 #define PGM_SETCHILD (PGM_FIRST+1)
2225 #define PGM_RECALCSIZE (PGM_FIRST+2)
2226 #define PGM_FORWARDMOUSE (PGM_FIRST+3)
2227 #define PGM_SETBKCOLOR (PGM_FIRST+4)
2228 #define PGM_GETBKCOLOR (PGM_FIRST+5)
2229 #define PGM_SETBORDER (PGM_FIRST+6)
2230 #define PGM_GETBORDER (PGM_FIRST+7)
2231 #define PGM_SETPOS (PGM_FIRST+8)
2232 #define PGM_GETPOS (PGM_FIRST+9)
2233 #define PGM_SETBUTTONSIZE (PGM_FIRST+10)
2234 #define PGM_GETBUTTONSIZE (PGM_FIRST+11)
2235 #define PGM_GETBUTTONSTATE (PGM_FIRST+12)
2236 #define PGM_GETDROPTARGET CCM_GETDROPTARGET
2238 #define PGN_FIRST (0U-900U)
2239 #define PGN_LAST (0U-950U)
2240 #define PGN_SCROLL (PGN_FIRST-1)
2241 #define PGN_CALCSIZE (PGN_FIRST-2)
2243 #include <pshpack1.h>
2245 typedef struct
2247 NMHDR hdr;
2248 WORD fwKeys;
2249 RECT rcParent;
2250 INT iDir;
2251 INT iXpos;
2252 INT iYpos;
2253 INT iScroll;
2254 } NMPGSCROLL, *LPNMPGSCROLL;
2256 #include <poppack.h>
2258 typedef struct
2260 NMHDR hdr;
2261 DWORD dwFlag;
2262 INT iWidth;
2263 INT iHeight;
2264 } NMPGCALCSIZE, *LPNMPGCALCSIZE;
2267 /* Treeview control */
2269 #define WC_TREEVIEWA "SysTreeView32"
2270 #if defined(__GNUC__)
2271 # define WC_TREEVIEWW (const WCHAR []){ 'S','y','s', \
2272 'T','r','e','e','V','i','e','w','3','2',0 }
2273 #elif defined(_MSC_VER)
2274 # define WC_TREEVIEWW L"SysTreeView32"
2275 #else
2276 static const WCHAR WC_TREEVIEWW[] = { 'S','y','s',
2277 'T','r','e','e','V','i','e','w','3','2',0 };
2278 #endif
2279 #define WC_TREEVIEW WINELIB_NAME_AW(WC_TREEVIEW)
2281 #define TVSIL_NORMAL 0
2282 #define TVSIL_STATE 2
2284 #define TV_FIRST 0x1100
2285 #define TVM_INSERTITEMA (TV_FIRST+0)
2286 #define TVM_INSERTITEMW (TV_FIRST+50)
2287 #define TVM_INSERTITEM WINELIB_NAME_AW(TVM_INSERTITEM)
2288 #define TVM_DELETEITEM (TV_FIRST+1)
2289 #define TVM_EXPAND (TV_FIRST+2)
2290 #define TVM_GETITEMRECT (TV_FIRST+4)
2291 #define TVM_GETCOUNT (TV_FIRST+5)
2292 #define TVM_GETINDENT (TV_FIRST+6)
2293 #define TVM_SETINDENT (TV_FIRST+7)
2294 #define TVM_GETIMAGELIST (TV_FIRST+8)
2295 #define TVM_SETIMAGELIST (TV_FIRST+9)
2296 #define TVM_GETNEXTITEM (TV_FIRST+10)
2297 #define TVM_SELECTITEM (TV_FIRST+11)
2298 #define TVM_GETITEMA (TV_FIRST+12)
2299 #define TVM_GETITEMW (TV_FIRST+62)
2300 #define TVM_GETITEM WINELIB_NAME_AW(TVM_GETITEM)
2301 #define TVM_SETITEMA (TV_FIRST+13)
2302 #define TVM_SETITEMW (TV_FIRST+63)
2303 #define TVM_SETITEM WINELIB_NAME_AW(TVM_SETITEM)
2304 #define TVM_EDITLABELA (TV_FIRST+14)
2305 #define TVM_EDITLABELW (TV_FIRST+65)
2306 #define TVM_EDITLABEL WINELIB_NAME_AW(TVM_EDITLABEL)
2307 #define TVM_GETEDITCONTROL (TV_FIRST+15)
2308 #define TVM_GETVISIBLECOUNT (TV_FIRST+16)
2309 #define TVM_HITTEST (TV_FIRST+17)
2310 #define TVM_CREATEDRAGIMAGE (TV_FIRST+18)
2311 #define TVM_SORTCHILDREN (TV_FIRST+19)
2312 #define TVM_ENSUREVISIBLE (TV_FIRST+20)
2313 #define TVM_SORTCHILDRENCB (TV_FIRST+21)
2314 #define TVM_ENDEDITLABELNOW (TV_FIRST+22)
2315 #define TVM_GETISEARCHSTRINGA (TV_FIRST+23)
2316 #define TVM_GETISEARCHSTRINGW (TV_FIRST+64)
2317 #define TVM_GETISEARCHSTRING WINELIB_NAME_AW(TVM_GETISEARCHSTRING)
2318 #define TVM_SETTOOLTIPS (TV_FIRST+24)
2319 #define TVM_GETTOOLTIPS (TV_FIRST+25)
2320 #define TVM_SETINSERTMARK (TV_FIRST+26)
2321 #define TVM_SETITEMHEIGHT (TV_FIRST+27)
2322 #define TVM_GETITEMHEIGHT (TV_FIRST+28)
2323 #define TVM_SETBKCOLOR (TV_FIRST+29)
2324 #define TVM_SETTEXTCOLOR (TV_FIRST+30)
2325 #define TVM_GETBKCOLOR (TV_FIRST+31)
2326 #define TVM_GETTEXTCOLOR (TV_FIRST+32)
2327 #define TVM_SETSCROLLTIME (TV_FIRST+33)
2328 #define TVM_GETSCROLLTIME (TV_FIRST+34)
2329 #define TVM_UNKNOWN35 (TV_FIRST+35)
2330 #define TVM_UNKNOWN36 (TV_FIRST+36)
2331 #define TVM_SETINSERTMARKCOLOR (TV_FIRST+37)
2332 #define TVM_GETINSERTMARKCOLOR (TV_FIRST+38)
2333 #define TVM_GETITEMSTATE (TV_FIRST+39)
2334 #define TVM_SETLINECOLOR (TV_FIRST+40)
2335 #define TVM_GETLINECOLOR (TV_FIRST+41)
2336 #define TVM_SETUNICODEFORMAT CCM_SETUNICODEFORMAT
2337 #define TVM_GETUNICODEFORMAT CCM_GETUNICODEFORMAT
2338 #define TVM_MAPACCIDTOHTREEITEM (TV_FIRST + 42)
2339 #define TVM_MAPHTREEITEMTOACCID (TV_FIRST + 43)
2342 #define TVN_FIRST (0U-400U)
2343 #define TVN_LAST (0U-499U)
2345 #define TVN_SELCHANGINGA (TVN_FIRST-1)
2346 #define TVN_SELCHANGINGW (TVN_FIRST-50)
2347 #define TVN_SELCHANGING WINELIB_NAME_AW(TVN_SELCHANGING)
2349 #define TVN_SELCHANGEDA (TVN_FIRST-2)
2350 #define TVN_SELCHANGEDW (TVN_FIRST-51)
2351 #define TVN_SELCHANGED WINELIB_NAME_AW(TVN_SELCHANGED)
2353 #define TVN_GETDISPINFOA (TVN_FIRST-3)
2354 #define TVN_GETDISPINFOW (TVN_FIRST-52)
2355 #define TVN_GETDISPINFO WINELIB_NAME_AW(TVN_GETDISPINFO)
2357 #define TVN_SETDISPINFOA (TVN_FIRST-4)
2358 #define TVN_SETDISPINFOW (TVN_FIRST-53)
2359 #define TVN_SETDISPINFO WINELIB_NAME_AW(TVN_SETDISPINFO)
2361 #define TVN_ITEMEXPANDINGA (TVN_FIRST-5)
2362 #define TVN_ITEMEXPANDINGW (TVN_FIRST-54)
2363 #define TVN_ITEMEXPANDING WINELIB_NAME_AW(TVN_ITEMEXPANDING)
2365 #define TVN_ITEMEXPANDEDA (TVN_FIRST-6)
2366 #define TVN_ITEMEXPANDEDW (TVN_FIRST-55)
2367 #define TVN_ITEMEXPANDED WINELIB_NAME_AW(TVN_ITEMEXPANDED)
2369 #define TVN_BEGINDRAGA (TVN_FIRST-7)
2370 #define TVN_BEGINDRAGW (TVN_FIRST-56)
2371 #define TVN_BEGINDRAG WINELIB_NAME_AW(TVN_BEGINDRAG)
2373 #define TVN_BEGINRDRAGA (TVN_FIRST-8)
2374 #define TVN_BEGINRDRAGW (TVN_FIRST-57)
2375 #define TVN_BEGINRDRAG WINELIB_NAME_AW(TVN_BEGINRDRAG)
2377 #define TVN_DELETEITEMA (TVN_FIRST-9)
2378 #define TVN_DELETEITEMW (TVN_FIRST-58)
2379 #define TVN_DELETEITEM WINELIB_NAME_AW(TVN_DELETEITEM)
2381 #define TVN_BEGINLABELEDITA (TVN_FIRST-10)
2382 #define TVN_BEGINLABELEDITW (TVN_FIRST-59)
2383 #define TVN_BEGINLABELEDIT WINELIB_NAME_AW(TVN_BEGINLABELEDIT)
2385 #define TVN_ENDLABELEDITA (TVN_FIRST-11)
2386 #define TVN_ENDLABELEDITW (TVN_FIRST-60)
2387 #define TVN_ENDLABELEDIT WINELIB_NAME_AW(TVN_ENDLABELEDIT)
2389 #define TVN_KEYDOWN (TVN_FIRST-12)
2391 #define TVN_GETINFOTIPA (TVN_FIRST-13)
2392 #define TVN_GETINFOTIPW (TVN_FIRST-14)
2393 #define TVN_GETINFOTIP WINELIB_NAME_AW(TVN_GETINFOTIP)
2395 #define TVN_SINGLEEXPAND (TVN_FIRST-15)
2401 #define TVIF_TEXT 0x0001
2402 #define TVIF_IMAGE 0x0002
2403 #define TVIF_PARAM 0x0004
2404 #define TVIF_STATE 0x0008
2405 #define TVIF_HANDLE 0x0010
2406 #define TVIF_SELECTEDIMAGE 0x0020
2407 #define TVIF_CHILDREN 0x0040
2408 #define TVIF_INTEGRAL 0x0080
2409 #define TVIF_DI_SETITEM 0x1000
2411 #define TVI_ROOT ((HTREEITEM)-65536)
2412 #define TVI_FIRST ((HTREEITEM)-65535)
2413 #define TVI_LAST ((HTREEITEM)-65534)
2414 #define TVI_SORT ((HTREEITEM)-65533)
2416 #define TVIS_FOCUSED 0x0001
2417 #define TVIS_SELECTED 0x0002
2418 #define TVIS_CUT 0x0004
2419 #define TVIS_DROPHILITED 0x0008
2420 #define TVIS_BOLD 0x0010
2421 #define TVIS_EXPANDED 0x0020
2422 #define TVIS_EXPANDEDONCE 0x0040
2423 #define TVIS_EXPANDPARTIAL 0x0080
2424 #define TVIS_OVERLAYMASK 0x0f00
2425 #define TVIS_STATEIMAGEMASK 0xf000
2426 #define TVIS_USERMASK 0xf000
2428 #define TVHT_NOWHERE 0x0001
2429 #define TVHT_ONITEMICON 0x0002
2430 #define TVHT_ONITEMLABEL 0x0004
2431 #define TVHT_ONITEMINDENT 0x0008
2432 #define TVHT_ONITEMBUTTON 0x0010
2433 #define TVHT_ONITEMRIGHT 0x0020
2434 #define TVHT_ONITEMSTATEICON 0x0040
2435 #define TVHT_ONITEM 0x0046
2436 #define TVHT_ABOVE 0x0100
2437 #define TVHT_BELOW 0x0200
2438 #define TVHT_TORIGHT 0x0400
2439 #define TVHT_TOLEFT 0x0800
2441 #define TVS_HASBUTTONS 0x0001
2442 #define TVS_HASLINES 0x0002
2443 #define TVS_LINESATROOT 0x0004
2444 #define TVS_EDITLABELS 0x0008
2445 #define TVS_DISABLEDRAGDROP 0x0010
2446 #define TVS_SHOWSELALWAYS 0x0020
2447 #define TVS_RTLREADING 0x0040
2448 #define TVS_NOTOOLTIPS 0x0080
2449 #define TVS_CHECKBOXES 0x0100
2450 #define TVS_TRACKSELECT 0x0200
2451 #define TVS_SINGLEEXPAND 0x0400
2452 #define TVS_INFOTIP 0x0800
2453 #define TVS_FULLROWSELECT 0x1000
2454 #define TVS_NOSCROLL 0x2000
2455 #define TVS_NONEVENHEIGHT 0x4000
2456 #define TVS_NOHSCROLL 0x8000
2458 #define TVS_SHAREDIMAGELISTS 0x0000
2459 #define TVS_PRIVATEIMAGELISTS 0x0400
2462 #define TVE_COLLAPSE 0x0001
2463 #define TVE_EXPAND 0x0002
2464 #define TVE_TOGGLE 0x0003
2465 #define TVE_EXPANDPARTIAL 0x4000
2466 #define TVE_COLLAPSERESET 0x8000
2468 #define TVGN_ROOT 0
2469 #define TVGN_NEXT 1
2470 #define TVGN_PREVIOUS 2
2471 #define TVGN_PARENT 3
2472 #define TVGN_CHILD 4
2473 #define TVGN_FIRSTVISIBLE 5
2474 #define TVGN_NEXTVISIBLE 6
2475 #define TVGN_PREVIOUSVISIBLE 7
2476 #define TVGN_DROPHILITE 8
2477 #define TVGN_CARET 9
2478 #define TVGN_LASTVISIBLE 10
2479 #define TVSI_NOSINGLEEXPAND 0x8000
2481 #define TVC_UNKNOWN 0x00
2482 #define TVC_BYMOUSE 0x01
2483 #define TVC_BYKEYBOARD 0x02
2486 typedef struct _TREEITEM *HTREEITEM;
2488 typedef struct {
2489 UINT mask;
2490 HTREEITEM hItem;
2491 UINT state;
2492 UINT stateMask;
2493 LPSTR pszText;
2494 INT cchTextMax;
2495 INT iImage;
2496 INT iSelectedImage;
2497 INT cChildren;
2498 LPARAM lParam;
2499 } TVITEMA, *LPTVITEMA;
2501 typedef struct {
2502 UINT mask;
2503 HTREEITEM hItem;
2504 UINT state;
2505 UINT stateMask;
2506 LPWSTR pszText;
2507 INT cchTextMax;
2508 INT iImage;
2509 INT iSelectedImage;
2510 INT cChildren;
2511 LPARAM lParam;
2512 } TVITEMW, *LPTVITEMW;
2514 #define TV_ITEMA TVITEMA
2515 #define TV_ITEMW TVITEMW
2516 #define LPTV_ITEMA LPTVITEMA
2517 #define LPTV_ITEMW LPTVITEMW
2519 #define TVITEM WINELIB_NAME_AW(TVITEM)
2520 #define LPTVITEM WINELIB_NAME_AW(LPTVITEM)
2521 #define TV_ITEM WINELIB_NAME_AW(TV_ITEM)
2522 #define LPTV_ITEM WINELIB_NAME_AW(LPTV_ITEM)
2524 typedef struct {
2525 UINT mask;
2526 HTREEITEM hItem;
2527 UINT state;
2528 UINT stateMask;
2529 LPSTR pszText;
2530 INT cchTextMax;
2531 INT iImage;
2532 INT iSelectedImage;
2533 INT cChildren;
2534 LPARAM lParam;
2535 INT iIntegral;
2536 UINT uStateEx; /* _WIN32_IE >= 0x600 */
2537 HWND hwnd; /* _WIN32_IE >= 0x600 */
2538 INT iExpandedImage; /* _WIN32_IE >= 0x600 */
2539 } TVITEMEXA, *LPTVITEMEXA;
2541 typedef struct {
2542 UINT mask;
2543 HTREEITEM hItem;
2544 UINT state;
2545 UINT stateMask;
2546 LPWSTR pszText;
2547 INT cchTextMax;
2548 INT iImage;
2549 INT iSelectedImage;
2550 INT cChildren;
2551 LPARAM lParam;
2552 INT iIntegral;
2553 UINT uStateEx; /* _WIN32_IE >= 0x600 */
2554 HWND hwnd; /* _WIN32_IE >= 0x600 */
2555 INT iExpandedImage; /* _WIN32_IE >= 0x600 */
2556 } TVITEMEXW, *LPTVITEMEXW;
2558 #define TVITEMEX WINELIB_NAME_AW(TVITEMEX)
2559 #define LPTVITEMEX WINELIB_NAME_AW(LPTVITEMEX)
2561 typedef struct tagTVINSERTSTRUCTA {
2562 HTREEITEM hParent;
2563 HTREEITEM hInsertAfter;
2564 union {
2565 TVITEMEXA itemex;
2566 TVITEMA item;
2567 } DUMMYUNIONNAME;
2568 } TVINSERTSTRUCTA, *LPTVINSERTSTRUCTA;
2570 typedef struct tagTVINSERTSTRUCTW {
2571 HTREEITEM hParent;
2572 HTREEITEM hInsertAfter;
2573 union {
2574 TVITEMEXW itemex;
2575 TVITEMW item;
2576 } DUMMYUNIONNAME;
2577 } TVINSERTSTRUCTW, *LPTVINSERTSTRUCTW;
2579 #define TVINSERTSTRUCT WINELIB_NAME_AW(TVINSERTSTRUCT)
2580 #define LPTVINSERTSTRUCT WINELIB_NAME_AW(LPTVINSERTSTRUCT)
2582 #define TVINSERTSTRUCT_V1_SIZEA CCSIZEOF_STRUCT(TVINSERTSTRUCTA, item)
2583 #define TVINSERTSTRUCT_V1_SIZEW CCSIZEOF_STRUCT(TVINSERTSTRUCTW, item)
2584 #define TVINSERTSTRUCT_V1_SIZE WINELIB_NAME_AW(TVINSERTSTRUCT_V1_SIZE)
2586 #define TV_INSERTSTRUCT TVINSERTSTRUCT
2587 #define TV_INSERTSTRUCTA TVINSERTSTRUCTA
2588 #define TV_INSERTSTRUCTW TVINSERTSTRUCTW
2589 #define LPTV_INSERTSTRUCT LPTVINSERTSTRUCT
2590 #define LPTV_INSERTSTRUCTA LPTVINSERTSTRUCTA
2591 #define LPTV_INSERTSTRUCTW LPTVINSERTSTRUCTW
2595 typedef struct tagNMTREEVIEWA {
2596 NMHDR hdr;
2597 UINT action;
2598 TVITEMA itemOld;
2599 TVITEMA itemNew;
2600 POINT ptDrag;
2601 } NMTREEVIEWA, *LPNMTREEVIEWA;
2603 typedef struct tagNMTREEVIEWW {
2604 NMHDR hdr;
2605 UINT action;
2606 TVITEMW itemOld;
2607 TVITEMW itemNew;
2608 POINT ptDrag;
2609 } NMTREEVIEWW, *LPNMTREEVIEWW;
2611 #define NMTREEVIEW WINELIB_NAME_AW(NMTREEVIEW)
2612 #define NM_TREEVIEW WINELIB_NAME_AW(NMTREEVIEW)
2613 #define NM_TREEVIEWA NMTREEVIEWA
2614 #define NM_TREEVIEWW NMTREEVIEWW
2615 #define LPNMTREEVIEW WINELIB_NAME_AW(LPNMTREEVIEW)
2617 #define LPNM_TREEVIEW LPNMTREEVIEW
2618 #define LPNM_TREEVIEWA LPNMTREEVIEWA
2619 #define LPNM_TREEVIEWW LPNMTREEVIEWW
2621 typedef struct tagTVDISPINFOA {
2622 NMHDR hdr;
2623 TVITEMA item;
2624 } NMTVDISPINFOA, *LPNMTVDISPINFOA;
2626 typedef struct tagTVDISPINFOW {
2627 NMHDR hdr;
2628 TVITEMW item;
2629 } NMTVDISPINFOW, *LPNMTVDISPINFOW;
2631 typedef struct tagTVDISPINFOEXA {
2632 NMHDR hdr;
2633 TVITEMEXA item;
2634 } NMTVDISPINFOEXA, *LPNMTVDISPINFOEXA;
2636 typedef struct tagTVDISPINFOEXW {
2637 NMHDR hdr;
2638 TVITEMEXW item;
2639 } NMTVDISPINFOEXW, *LPNMTVDISPINFOEXW;
2641 #define NMTVDISPINFO WINELIB_NAME_AW(NMTVDISPINFO)
2642 #define LPNMTVDISPINFO WINELIB_NAME_AW(LPNMTVDISPINFO)
2643 #define NMTVDISPINFOEX WINELIB_NAME_AW(NMTVDISPINFOEX)
2644 #define LPNMTVDISPINFOEX WINELIB_NAME_AW(LPNMTVDISPINFOEX)
2645 #define TV_DISPINFOA NMTVDISPINFOA
2646 #define TV_DISPINFOW NMTVDISPINFOW
2647 #define TV_DISPINFO NMTVDISPINFO
2649 typedef INT (CALLBACK *PFNTVCOMPARE)(LPARAM, LPARAM, LPARAM);
2651 typedef struct tagTVSORTCB
2653 HTREEITEM hParent;
2654 PFNTVCOMPARE lpfnCompare;
2655 LPARAM lParam;
2656 } TVSORTCB, *LPTVSORTCB;
2658 #define TV_SORTCB TVSORTCB
2659 #define LPTV_SORTCB LPTVSORTCB
2661 typedef struct tagTVHITTESTINFO {
2662 POINT pt;
2663 UINT flags;
2664 HTREEITEM hItem;
2665 } TVHITTESTINFO, *LPTVHITTESTINFO;
2667 #define TV_HITTESTINFO TVHITTESTINFO
2670 /* Custom Draw Treeview */
2672 #define NMTVCUSTOMDRAW_V3_SIZE CCSIZEOF_STRUCT(NMTVCUSTOMDRAW, clrTextBk)
2674 #define TVCDRF_NOIMAGES 0x00010000
2676 typedef struct tagNMTVCUSTOMDRAW
2678 NMCUSTOMDRAW nmcd;
2679 COLORREF clrText;
2680 COLORREF clrTextBk;
2681 INT iLevel; /* IE>0x0400 */
2682 } NMTVCUSTOMDRAW, *LPNMTVCUSTOMDRAW;
2684 /* Treeview tooltips */
2686 typedef struct tagNMTVGETINFOTIPA
2688 NMHDR hdr;
2689 LPSTR pszText;
2690 INT cchTextMax;
2691 HTREEITEM hItem;
2692 LPARAM lParam;
2693 } NMTVGETINFOTIPA, *LPNMTVGETINFOTIPA;
2695 typedef struct tagNMTVGETINFOTIPW
2697 NMHDR hdr;
2698 LPWSTR pszText;
2699 INT cchTextMax;
2700 HTREEITEM hItem;
2701 LPARAM lParam;
2702 } NMTVGETINFOTIPW, *LPNMTVGETINFOTIPW;
2704 #define NMTVGETINFOTIP WINELIB_NAME_AW(NMTVGETINFOTIP)
2705 #define LPNMTVGETINFOTIP WINELIB_NAME_AW(LPNMTVGETINFOTIP)
2707 #include <pshpack1.h>
2708 typedef struct tagTVKEYDOWN
2710 NMHDR hdr;
2711 WORD wVKey;
2712 UINT flags;
2713 } NMTVKEYDOWN, *LPNMTVKEYDOWN;
2714 #include <poppack.h>
2716 #define TV_KEYDOWN NMTVKEYDOWN
2718 #define TreeView_InsertItemA(hwnd, phdi) \
2719 (HTREEITEM)SNDMSGA((hwnd), TVM_INSERTITEMA, 0, \
2720 (LPARAM)(LPTVINSERTSTRUCTA)(phdi))
2721 #define TreeView_InsertItemW(hwnd,phdi) \
2722 (HTREEITEM)SNDMSGW((hwnd), TVM_INSERTITEMW, 0, \
2723 (LPARAM)(LPTVINSERTSTRUCTW)(phdi))
2724 #define TreeView_InsertItem WINELIB_NAME_AW(TreeView_InsertItem)
2726 #define TreeView_DeleteItem(hwnd, hItem) \
2727 (BOOL)SNDMSG((hwnd), TVM_DELETEITEM, 0, (LPARAM)(HTREEITEM)(hItem))
2728 #define TreeView_DeleteAllItems(hwnd) \
2729 (BOOL)SNDMSG((hwnd), TVM_DELETEITEM, 0, (LPARAM)TVI_ROOT)
2730 #define TreeView_Expand(hwnd, hitem, code) \
2731 (BOOL)SNDMSG((hwnd), TVM_EXPAND, (WPARAM)code, \
2732 (LPARAM)(HTREEITEM)(hitem))
2734 #define TreeView_GetItemRect(hwnd, hitem, prc, code) \
2735 (*(HTREEITEM *)prc = (hitem), (BOOL)SNDMSG((hwnd), \
2736 TVM_GETITEMRECT, (WPARAM)(code), (LPARAM)(RECT *)(prc)))
2738 #define TreeView_GetCount(hwnd) \
2739 (UINT)SNDMSG((hwnd), TVM_GETCOUNT, 0, 0)
2740 #define TreeView_GetIndent(hwnd) \
2741 (UINT)SNDMSG((hwnd), TVM_GETINDENT, 0, 0)
2742 #define TreeView_SetIndent(hwnd, indent) \
2743 (BOOL)SNDMSG((hwnd), TVM_SETINDENT, (WPARAM)indent, 0)
2745 #define TreeView_GetImageList(hwnd, iImage) \
2746 (HIMAGELIST)SNDMSG((hwnd), TVM_GETIMAGELIST, iImage, 0)
2748 #define TreeView_SetImageList(hwnd, himl, iImage) \
2749 (HIMAGELIST)SNDMSG((hwnd), TVM_SETIMAGELIST, iImage, \
2750 (LPARAM)(HIMAGELIST)(himl))
2752 #define TreeView_GetNextItem(hwnd, hitem, code) \
2753 (HTREEITEM)SNDMSG((hwnd), TVM_GETNEXTITEM, (WPARAM)code,\
2754 (LPARAM)(HTREEITEM) (hitem))
2756 #define TreeView_GetChild(hwnd, hitem) \
2757 TreeView_GetNextItem(hwnd, hitem , TVGN_CHILD)
2758 #define TreeView_GetNextSibling(hwnd, hitem) \
2759 TreeView_GetNextItem(hwnd, hitem , TVGN_NEXT)
2760 #define TreeView_GetPrevSibling(hwnd, hitem) \
2761 TreeView_GetNextItem(hwnd, hitem , TVGN_PREVIOUS)
2762 #define TreeView_GetParent(hwnd, hitem) \
2763 TreeView_GetNextItem(hwnd, hitem , TVGN_PARENT)
2764 #define TreeView_GetFirstVisible(hwnd) \
2765 TreeView_GetNextItem(hwnd, NULL, TVGN_FIRSTVISIBLE)
2766 #define TreeView_GetLastVisible(hwnd) \
2767 TreeView_GetNextItem(hwnd, NULL, TVGN_LASTVISIBLE)
2768 #define TreeView_GetNextVisible(hwnd, hitem) \
2769 TreeView_GetNextItem(hwnd, hitem , TVGN_NEXTVISIBLE)
2770 #define TreeView_GetPrevVisible(hwnd, hitem) \
2771 TreeView_GetNextItem(hwnd, hitem , TVGN_PREVIOUSVISIBLE)
2772 #define TreeView_GetSelection(hwnd) \
2773 TreeView_GetNextItem(hwnd, NULL, TVGN_CARET)
2774 #define TreeView_GetDropHilight(hwnd) \
2775 TreeView_GetNextItem(hwnd, NULL, TVGN_DROPHILITE)
2776 #define TreeView_GetRoot(hwnd) \
2777 TreeView_GetNextItem(hwnd, NULL, TVGN_ROOT)
2778 #define TreeView_GetLastVisible(hwnd) \
2779 TreeView_GetNextItem(hwnd, NULL, TVGN_LASTVISIBLE)
2782 #define TreeView_Select(hwnd, hitem, code) \
2783 (BOOL)SNDMSG((hwnd), TVM_SELECTITEM, (WPARAM)(code), \
2784 (LPARAM)(HTREEITEM)(hitem))
2787 #define TreeView_SelectItem(hwnd, hitem) \
2788 TreeView_Select(hwnd, hitem, TVGN_CARET)
2789 #define TreeView_SelectDropTarget(hwnd, hitem) \
2790 TreeView_Select(hwnd, hitem, TVGN_DROPHILITE)
2791 #define TreeView_SelectSetFirstVisible(hwnd, hitem) \
2792 TreeView_Select(hwnd, hitem, TVGN_FIRSTVISIBLE)
2795 #define TreeView_GetItemA(hwnd, pitem) \
2796 (BOOL)SNDMSGA((hwnd), TVM_GETITEMA, 0, (LPARAM) (TVITEMA *)(pitem))
2797 #define TreeView_GetItemW(hwnd, pitem) \
2798 (BOOL)SNDMSGW((hwnd), TVM_GETITEMW, 0, (LPARAM) (TVITEMW *)(pitem))
2799 #define TreeView_GetItem WINELIB_NAME_AW(TreeView_GetItem)
2801 #define TreeView_SetItemA(hwnd, pitem) \
2802 (BOOL)SNDMSGA((hwnd), TVM_SETITEMA, 0, (LPARAM)(const TVITEMA *)(pitem))
2803 #define TreeView_SetItemW(hwnd, pitem) \
2804 (BOOL)SNDMSGW((hwnd), TVM_SETITEMW, 0, (LPARAM)(const TVITEMW *)(pitem))
2805 #define TreeView_SetItem WINELIB_NAME_AW(TreeView_SetItem)
2807 #define TreeView_EditLabel(hwnd, hitem) \
2808 (HWND)SNDMSG((hwnd), TVM_EDITLABEL, 0, (LPARAM)(HTREEITEM)(hitem))
2810 #define TreeView_GetEditControl(hwnd) \
2811 (HWND)SNDMSG((hwnd), TVM_GETEDITCONTROL, 0, 0)
2813 #define TreeView_GetVisibleCount(hwnd) \
2814 (UINT)SNDMSG((hwnd), TVM_GETVISIBLECOUNT, 0, 0)
2816 #define TreeView_HitTest(hwnd, lpht) \
2817 (HTREEITEM)SNDMSG((hwnd), TVM_HITTEST, 0,\
2818 (LPARAM)(LPTVHITTESTINFO)(lpht))
2820 #define TreeView_CreateDragImage(hwnd, hitem) \
2821 (HIMAGELIST)SNDMSG((hwnd), TVM_CREATEDRAGIMAGE, 0,\
2822 (LPARAM)(HTREEITEM)(hitem))
2824 #define TreeView_SortChildren(hwnd, hitem, recurse) \
2825 (BOOL)SNDMSG((hwnd), TVM_SORTCHILDREN, (WPARAM)recurse,\
2826 (LPARAM)(HTREEITEM)(hitem))
2828 #define TreeView_EnsureVisible(hwnd, hitem) \
2829 (BOOL)SNDMSG((hwnd), TVM_ENSUREVISIBLE, 0, (LPARAM)(UINT)(hitem))
2831 #define TreeView_SortChildrenCB(hwnd, psort, recurse) \
2832 (BOOL)SNDMSG((hwnd), TVM_SORTCHILDRENCB, (WPARAM)recurse, \
2833 (LPARAM)(LPTV_SORTCB)(psort))
2835 #define TreeView_EndEditLabelNow(hwnd, fCancel) \
2836 (BOOL)SNDMSG((hwnd), TVM_ENDEDITLABELNOW, (WPARAM)fCancel, 0)
2838 #define TreeView_GetISearchString(hwnd, lpsz) \
2839 (BOOL)SNDMSG((hwnd), TVM_GETISEARCHSTRING, 0, \
2840 (LPARAM)(LPTSTR)lpsz)
2842 #define TreeView_SetToolTips(hwnd, hwndTT) \
2843 (HWND)SNDMSG((hwnd), TVM_SETTOOLTIPS, (WPARAM)(hwndTT), 0)
2845 #define TreeView_GetToolTips(hwnd) \
2846 (HWND)SNDMSG((hwnd), TVM_GETTOOLTIPS, 0, 0)
2848 #define TreeView_SetItemHeight(hwnd, iHeight) \
2849 (INT)SNDMSG((hwnd), TVM_SETITEMHEIGHT, (WPARAM)iHeight, 0)
2851 #define TreeView_GetItemHeight(hwnd) \
2852 (INT)SNDMSG((hwnd), TVM_GETITEMHEIGHT, 0, 0)
2854 #define TreeView_SetBkColor(hwnd, clr) \
2855 (COLORREF)SNDMSG((hwnd), TVM_SETBKCOLOR, 0, (LPARAM)clr)
2857 #define TreeView_SetTextColor(hwnd, clr) \
2858 (COLORREF)SNDMSG((hwnd), TVM_SETTEXTCOLOR, 0, (LPARAM)clr)
2860 #define TreeView_GetBkColor(hwnd) \
2861 (COLORREF)SNDMSG((hwnd), TVM_GETBKCOLOR, 0, 0)
2863 #define TreeView_GetTextColor(hwnd) \
2864 (COLORREF)SNDMSG((hwnd), TVM_GETTEXTCOLOR, 0, 0)
2866 #define TreeView_SetScrollTime(hwnd, uTime) \
2867 (UINT)SNDMSG((hwnd), TVM_SETSCROLLTIME, uTime, 0)
2869 #define TreeView_GetScrollTime(hwnd) \
2870 (UINT)SNDMSG((hwnd), TVM_GETSCROLLTIME, 0, 0)
2872 #define TreeView_SetInsertMark(hwnd, hItem, fAfter) \
2873 (BOOL)SNDMSG((hwnd), TVM_SETINSERTMARK, (WPARAM)(fAfter), \
2874 (LPARAM) (hItem))
2876 #define TreeView_SetInsertMarkColor(hwnd, clr) \
2877 (COLORREF)SNDMSG((hwnd), TVM_SETINSERTMARKCOLOR, 0, (LPARAM)clr)
2879 #define TreeView_GetInsertMarkColor(hwnd) \
2880 (COLORREF)SNDMSG((hwnd), TVM_GETINSERTMARKCOLOR, 0, 0)
2882 #define TreeView_SetItemState(hwndTV, hti, data, _mask) \
2883 { TVITEM _TVi; \
2884 _TVi.mask = TVIF_STATE; \
2885 _TVi.hItem = hti; \
2886 _TVi.stateMask = _mask; \
2887 _TVi.state = data; \
2888 SNDMSG((hwndTV), TVM_SETITEM, 0, (LPARAM)&_TVi); \
2891 #define TreeView_GetItemState(hwndTV, hti, mask) \
2892 (UINT)SNDMSG((hwndTV), TVM_GETITEMSTATE, (WPARAM)(hti), (LPARAM)(mask))
2893 #define TreeView_GetCheckState(hwndTV, hti) \
2894 ((((UINT)(SNDMSG((hwndTV), TVM_GETITEMSTATE, (WPARAM)(hti), \
2895 TVIS_STATEIMAGEMASK))) >> 12) -1)
2897 #define TreeView_SetLineColor(hwnd, clr) \
2898 (COLORREF)SNDMSG((hwnd), TVM_SETLINECOLOR, 0, (LPARAM)(clr))
2900 #define TreeView_GetLineColor(hwnd) \
2901 (COLORREF)SNDMSG((hwnd), TVM_GETLINECOLOR, 0, 0)
2903 #define TreeView_MapAccIDToHTREEITEM(hwnd, id) \
2904 (HTREEITEM)SNDMSG((hwnd), TVM_MAPACCIDTOHTREEITEM, id, 0)
2906 #define TreeView_MapHTREEITEMToAccID(hwnd, htreeitem) \
2907 (UINT)SNDMSG((hwnd), TVM_MAPHTREEITEMTOACCID, (WPARAM)htreeitem, 0)
2909 #define TreeView_SetUnicodeFormat(hwnd, fUnicode) \
2910 (BOOL)SNDMSG((hwnd), TVM_SETUNICODEFORMAT, (WPARAM)(fUnicode), 0)
2911 #define TreeView_GetUnicodeFormat(hwnd) \
2912 (BOOL)SNDMSG((hwnd), TVM_GETUNICODEFORMAT, 0, 0)
2914 /* Listview control */
2916 #define WC_LISTVIEWA "SysListView32"
2917 #if defined(__GNUC__)
2918 # define WC_LISTVIEWW (const WCHAR []){ 'S','y','s', \
2919 'L','i','s','t','V','i','e','w','3','2',0 }
2920 #elif defined(_MSC_VER)
2921 # define WC_LISTVIEWW L"SysListView32"
2922 #else
2923 static const WCHAR WC_LISTVIEWW[] = { 'S','y','s',
2924 'L','i','s','t','V','i','e','w','3','2',0 };
2925 #endif
2926 #define WC_LISTVIEW WINELIB_NAME_AW(WC_LISTVIEW)
2928 #define LVSCW_AUTOSIZE -1
2929 #define LVSCW_AUTOSIZE_USEHEADER -2
2931 #define LVS_ICON 0x0000
2932 #define LVS_REPORT 0x0001
2933 #define LVS_SMALLICON 0x0002
2934 #define LVS_LIST 0x0003
2935 #define LVS_TYPEMASK 0x0003
2936 #define LVS_SINGLESEL 0x0004
2937 #define LVS_SHOWSELALWAYS 0x0008
2938 #define LVS_SORTASCENDING 0x0010
2939 #define LVS_SORTDESCENDING 0x0020
2940 #define LVS_SHAREIMAGELISTS 0x0040
2941 #define LVS_NOLABELWRAP 0x0080
2942 #define LVS_AUTOARRANGE 0x0100
2943 #define LVS_EDITLABELS 0x0200
2944 #define LVS_OWNERDATA 0x1000
2945 #define LVS_NOSCROLL 0x2000
2946 #define LVS_TYPESTYLEMASK 0xfc00
2947 #define LVS_ALIGNTOP 0x0000
2948 #define LVS_ALIGNLEFT 0x0800
2949 #define LVS_ALIGNMASK 0x0c00
2950 #define LVS_OWNERDRAWFIXED 0x0400
2951 #define LVS_NOCOLUMNHEADER 0x4000
2952 #define LVS_NOSORTHEADER 0x8000
2954 #define LVS_EX_GRIDLINES 0x0001
2955 #define LVS_EX_SUBITEMIMAGES 0x0002
2956 #define LVS_EX_CHECKBOXES 0x0004
2957 #define LVS_EX_TRACKSELECT 0x0008
2958 #define LVS_EX_HEADERDRAGDROP 0x0010
2959 #define LVS_EX_FULLROWSELECT 0x0020
2960 #define LVS_EX_ONECLICKACTIVATE 0x0040
2961 #define LVS_EX_TWOCLICKACTIVATE 0x0080
2962 #define LVS_EX_FLATSB 0x0100
2963 #define LVS_EX_REGIONAL 0x0200
2964 #define LVS_EX_INFOTIP 0x0400
2965 #define LVS_EX_UNDERLINEHOT 0x0800
2966 #define LVS_EX_UNDERLINECOLD 0x1000
2967 #define LVS_EX_MULTIWORKAREAS 0x2000
2968 #define LVS_EX_LABELTIP 0x4000
2969 #define LVS_EX_BORDERSELECT 0x8000
2970 #define LVS_EX_DOUBLEBUFFER 0x00010000
2971 #define LVS_EX_HIDELABELS 0x00020000
2972 #define LVS_EX_SINGLEROW 0x00040000
2973 #define LVS_EX_SNAPTOGRID 0x00080000
2974 #define LVS_EX_SIMPLESELECT 0x00100000
2975 #define LVS_EX_JUSTIFYCOLUMNS 0x00200000
2976 #define LVS_EX_TRANSPARENTBKGND 0x00400000
2977 #define LVS_EX_TRANSPARENTSHADOWTEXT 0x00800000
2978 #define LVS_EX_AUTOAUTOARRANGE 0x01000000
2979 #define LVS_EX_HEADERINALLVIEWS 0x02000000
2980 #define LVS_EX_AUTOCHECKSELECT 0x08000000
2981 #define LVS_EX_AUTOSIZECOLUMNS 0x10000000
2982 #define LVS_EX_COLUMNSNAPPOINTS 0x40000000
2983 #define LVS_EX_COLUMNOVERFLOW 0x80000000
2985 #define LVCF_FMT 0x0001
2986 #define LVCF_WIDTH 0x0002
2987 #define LVCF_TEXT 0x0004
2988 #define LVCF_SUBITEM 0x0008
2989 #define LVCF_IMAGE 0x0010
2990 #define LVCF_ORDER 0x0020
2992 #define LVCFMT_LEFT 0x0000
2993 #define LVCFMT_RIGHT 0x0001
2994 #define LVCFMT_CENTER 0x0002
2995 #define LVCFMT_JUSTIFYMASK 0x0003
2996 #define LVCFMT_FIXED_WIDTH 0x0100
2997 #define LVCFMT_IMAGE 0x0800
2998 #define LVCFMT_BITMAP_ON_RIGHT 0x1000
2999 #define LVCFMT_COL_HAS_IMAGES 0x8000
3000 #define LVCFMT_NO_DPI_SCALE 0x00040000
3001 #define LVCFMT_FIXED_RATIO 0x00080000
3002 #define LVCFMT_LINE_BREAK 0x00100000
3003 #define LVCFMT_FILL 0x00200000
3004 #define LVCFMT_WRAP 0x00400000
3005 #define LVCFMT_NO_TITLE 0x00800000
3006 #define LVCFMT_SPLIT_BUTTON 0x01000000
3007 #define LVCFMT_TILE_PLACEMENTMASK (LVCFMT_LINE_BREAK | LVCFMT_FILL)
3009 #define LVSIL_NORMAL 0
3010 #define LVSIL_SMALL 1
3011 #define LVSIL_STATE 2
3013 /* following 2 flags only for LVS_OWNERDATA listviews */
3014 /* and only in report or list mode */
3015 #define LVSICF_NOINVALIDATEALL 0x0001
3016 #define LVSICF_NOSCROLL 0x0002
3019 #define LVFI_PARAM 0X0001
3020 #define LVFI_STRING 0X0002
3021 #define LVFI_PARTIAL 0X0008
3022 #define LVFI_WRAP 0X0020
3023 #define LVFI_NEARESTXY 0X0040
3025 #define LVIF_TEXT 0x0001
3026 #define LVIF_IMAGE 0x0002
3027 #define LVIF_PARAM 0x0004
3028 #define LVIF_STATE 0x0008
3029 #define LVIF_INDENT 0x0010
3030 #define LVIF_GROUPID 0x0100
3031 #define LVIF_COLUMNS 0x0200
3032 #define LVIF_NORECOMPUTE 0x0800
3033 #define LVIF_DI_SETITEM 0x1000
3034 #define LVIF_COLFMT 0x00010000
3036 #define LVIR_BOUNDS 0x0000
3037 #define LVIR_ICON 0x0001
3038 #define LVIR_LABEL 0x0002
3039 #define LVIR_SELECTBOUNDS 0x0003
3041 #define LVIS_FOCUSED 0x0001
3042 #define LVIS_SELECTED 0x0002
3043 #define LVIS_CUT 0x0004
3044 #define LVIS_DROPHILITED 0x0008
3045 #define LVIS_ACTIVATING 0x0020
3047 #define LVIS_OVERLAYMASK 0x0F00
3048 #define LVIS_STATEIMAGEMASK 0xF000
3050 #define LVNI_ALL 0x0000
3051 #define LVNI_FOCUSED 0x0001
3052 #define LVNI_SELECTED 0x0002
3053 #define LVNI_CUT 0x0004
3054 #define LVNI_DROPHILITED 0x0008
3056 #define LVNI_ABOVE 0x0100
3057 #define LVNI_BELOW 0x0200
3058 #define LVNI_TOLEFT 0x0400
3059 #define LVNI_TORIGHT 0x0800
3061 #define LVHT_NOWHERE 0x0001
3062 #define LVHT_ONITEMICON 0x0002
3063 #define LVHT_ONITEMLABEL 0x0004
3064 #define LVHT_ONITEMSTATEICON 0x0008
3065 #define LVHT_ONITEM (LVHT_ONITEMICON|LVHT_ONITEMLABEL|LVHT_ONITEMSTATEICON)
3067 #define LVHT_ABOVE 0x0008
3068 #define LVHT_BELOW 0x0010
3069 #define LVHT_TORIGHT 0x0020
3070 #define LVHT_TOLEFT 0x0040
3072 #define LV_VIEW_ICON 0x0000
3073 #define LV_VIEW_DETAILS 0x0001
3074 #define LV_VIEW_SMALLICON 0x0002
3075 #define LV_VIEW_LIST 0x0003
3076 #define LV_VIEW_TILE 0x0004
3077 #define LV_VIEW_MAX 0x0004
3079 #define LVGF_NONE 0x00000000
3080 #define LVGF_HEADER 0x00000001
3081 #define LVGF_FOOTER 0x00000002
3082 #define LVGF_STATE 0x00000004
3083 #define LVGF_ALIGN 0x00000008
3084 #define LVGF_GROUPID 0x00000010
3085 #define LVGF_SUBTITLE 0x00000100
3086 #define LVGF_TASK 0x00000200
3087 #define LVGF_DESCRIPTIONTOP 0x00000400
3088 #define LVGF_DESCRIPTIONBOTTOM 0x00000800
3089 #define LVGF_TITLEIMAGE 0x00001000
3090 #define LVGF_EXTENDEDIMAGE 0x00002000
3091 #define LVGF_ITEMS 0x00004000
3092 #define LVGF_SUBSET 0x00008000
3093 #define LVGF_SUBSETITEMS 0x00010000
3095 #define LVGS_NORMAL 0x00000000
3096 #define LVGS_COLLAPSED 0x00000001
3097 #define LVGS_HIDDEN 0x00000002
3099 #define LVGA_HEADER_LEFT 0x00000001
3100 #define LVGA_HEADER_CENTER 0x00000002
3101 #define LVGA_HEADER_RIGHT 0x00000004
3102 #define LVGA_FOOTER_LEFT 0x00000008
3103 #define LVGA_FOOTER_CENTER 0x00000010
3104 #define LVGA_FOOTER_RIGHT 0x00000020
3106 #define LVGMF_NONE 0x00000000
3107 #define LVGMF_BORDERSIZE 0x00000001
3108 #define LVGMF_BORDERCOLOR 0x00000002
3109 #define LVGMF_TEXTCOLOR 0x00000004
3111 #define LVTVIF_AUTOSIZE 0x00000000
3112 #define LVTVIF_FIXEDWIDTH 0x00000001
3113 #define LVTVIF_FIXEDHEIGHT 0x00000002
3114 #define LVTVIF_FIXEDSIZE 0x00000003
3115 #define LVTVIF_EXTENDED 0x00000004
3117 #define LVTVIM_TILESIZE 0x00000001
3118 #define LVTVIM_COLUMNS 0x00000002
3119 #define LVTVIM_LABELMARGIN 0x00000004
3121 #define LVIM_AFTER 0x00000001
3123 #define LVM_FIRST 0x1000
3124 #define LVM_GETBKCOLOR (LVM_FIRST+0)
3125 #define LVM_SETBKCOLOR (LVM_FIRST+1)
3126 #define LVM_GETIMAGELIST (LVM_FIRST+2)
3127 #define LVM_SETIMAGELIST (LVM_FIRST+3)
3128 #define LVM_GETITEMCOUNT (LVM_FIRST+4)
3129 #define LVM_GETITEMA (LVM_FIRST+5)
3130 #define LVM_GETITEMW (LVM_FIRST+75)
3131 #define LVM_GETITEM WINELIB_NAME_AW(LVM_GETITEM)
3132 #define LVM_SETITEMA (LVM_FIRST+6)
3133 #define LVM_SETITEMW (LVM_FIRST+76)
3134 #define LVM_SETITEM WINELIB_NAME_AW(LVM_SETITEM)
3135 #define LVM_INSERTITEMA (LVM_FIRST+7)
3136 #define LVM_INSERTITEMW (LVM_FIRST+77)
3137 #define LVM_INSERTITEM WINELIB_NAME_AW(LVM_INSERTITEM)
3138 #define LVM_DELETEITEM (LVM_FIRST+8)
3139 #define LVM_DELETEALLITEMS (LVM_FIRST+9)
3140 #define LVM_GETCALLBACKMASK (LVM_FIRST+10)
3141 #define LVM_SETCALLBACKMASK (LVM_FIRST+11)
3142 #define LVM_GETNEXTITEM (LVM_FIRST+12)
3143 #define LVM_FINDITEMA (LVM_FIRST+13)
3144 #define LVM_FINDITEMW (LVM_FIRST+83)
3145 #define LVM_FINDITEM WINELIB_NAME_AW(LVM_FINDITEM)
3146 #define LVM_GETITEMRECT (LVM_FIRST+14)
3147 #define LVM_SETITEMPOSITION (LVM_FIRST+15)
3148 #define LVM_GETITEMPOSITION (LVM_FIRST+16)
3149 #define LVM_GETSTRINGWIDTHA (LVM_FIRST+17)
3150 #define LVM_GETSTRINGWIDTHW (LVM_FIRST+87)
3151 #define LVM_GETSTRINGWIDTH WINELIB_NAME_AW(LVM_GETSTRINGWIDTH)
3152 #define LVM_HITTEST (LVM_FIRST+18)
3153 #define LVM_ENSUREVISIBLE (LVM_FIRST+19)
3154 #define LVM_SCROLL (LVM_FIRST+20)
3155 #define LVM_REDRAWITEMS (LVM_FIRST+21)
3156 #define LVM_ARRANGE (LVM_FIRST+22)
3157 #define LVM_EDITLABELA (LVM_FIRST+23)
3158 #define LVM_EDITLABELW (LVM_FIRST+118)
3159 #define LVM_EDITLABEL WINELIB_NAME_AW(LVM_EDITLABEL)
3160 #define LVM_GETEDITCONTROL (LVM_FIRST+24)
3161 #define LVM_GETCOLUMNA (LVM_FIRST+25)
3162 #define LVM_GETCOLUMNW (LVM_FIRST+95)
3163 #define LVM_GETCOLUMN WINELIB_NAME_AW(LVM_GETCOLUMN)
3164 #define LVM_SETCOLUMNA (LVM_FIRST+26)
3165 #define LVM_SETCOLUMNW (LVM_FIRST+96)
3166 #define LVM_SETCOLUMN WINELIB_NAME_AW(LVM_SETCOLUMN)
3167 #define LVM_INSERTCOLUMNA (LVM_FIRST+27)
3168 #define LVM_INSERTCOLUMNW (LVM_FIRST+97)
3169 #define LVM_INSERTCOLUMN WINELIB_NAME_AW(LVM_INSERTCOLUMN)
3170 #define LVM_DELETECOLUMN (LVM_FIRST+28)
3171 #define LVM_GETCOLUMNWIDTH (LVM_FIRST+29)
3172 #define LVM_SETCOLUMNWIDTH (LVM_FIRST+30)
3173 #define LVM_GETHEADER (LVM_FIRST+31)
3175 #define LVM_CREATEDRAGIMAGE (LVM_FIRST+33)
3176 #define LVM_GETVIEWRECT (LVM_FIRST+34)
3177 #define LVM_GETTEXTCOLOR (LVM_FIRST+35)
3178 #define LVM_SETTEXTCOLOR (LVM_FIRST+36)
3179 #define LVM_GETTEXTBKCOLOR (LVM_FIRST+37)
3180 #define LVM_SETTEXTBKCOLOR (LVM_FIRST+38)
3181 #define LVM_GETTOPINDEX (LVM_FIRST+39)
3182 #define LVM_GETCOUNTPERPAGE (LVM_FIRST+40)
3183 #define LVM_GETORIGIN (LVM_FIRST+41)
3184 #define LVM_UPDATE (LVM_FIRST+42)
3185 #define LVM_SETITEMSTATE (LVM_FIRST+43)
3186 #define LVM_GETITEMSTATE (LVM_FIRST+44)
3187 #define LVM_GETITEMTEXTA (LVM_FIRST+45)
3188 #define LVM_GETITEMTEXTW (LVM_FIRST+115)
3189 #define LVM_GETITEMTEXT WINELIB_NAME_AW(LVM_GETITEMTEXT)
3190 #define LVM_SETITEMTEXTA (LVM_FIRST+46)
3191 #define LVM_SETITEMTEXTW (LVM_FIRST+116)
3192 #define LVM_SETITEMTEXT WINELIB_NAME_AW(LVM_SETITEMTEXT)
3193 #define LVM_SETITEMCOUNT (LVM_FIRST+47)
3194 #define LVM_SORTITEMS (LVM_FIRST+48)
3195 #define LVM_SORTITEMSEX (LVM_FIRST+81)
3196 #define LVM_SETITEMPOSITION32 (LVM_FIRST+49)
3197 #define LVM_GETSELECTEDCOUNT (LVM_FIRST+50)
3198 #define LVM_GETITEMSPACING (LVM_FIRST+51)
3199 #define LVM_GETISEARCHSTRINGA (LVM_FIRST+52)
3200 #define LVM_GETISEARCHSTRINGW (LVM_FIRST+117)
3201 #define LVM_GETISEARCHSTRING WINELIB_NAME_AW(LVM_GETISEARCHSTRING)
3202 #define LVM_SETICONSPACING (LVM_FIRST+53)
3203 #define LVM_SETEXTENDEDLISTVIEWSTYLE (LVM_FIRST+54)
3204 #define LVM_GETEXTENDEDLISTVIEWSTYLE (LVM_FIRST+55)
3205 #define LVM_GETSUBITEMRECT (LVM_FIRST+56)
3206 #define LVM_SUBITEMHITTEST (LVM_FIRST+57)
3207 #define LVM_SETCOLUMNORDERARRAY (LVM_FIRST+58)
3208 #define LVM_GETCOLUMNORDERARRAY (LVM_FIRST+59)
3209 #define LVM_SETHOTITEM (LVM_FIRST+60)
3210 #define LVM_GETHOTITEM (LVM_FIRST+61)
3211 #define LVM_SETHOTCURSOR (LVM_FIRST+62)
3212 #define LVM_GETHOTCURSOR (LVM_FIRST+63)
3213 #define LVM_APPROXIMATEVIEWRECT (LVM_FIRST+64)
3214 #define LVM_SETWORKAREAS (LVM_FIRST+65)
3215 #define LVM_GETSELECTIONMARK (LVM_FIRST+66)
3216 #define LVM_SETSELECTIONMARK (LVM_FIRST+67)
3217 #define LVM_SETBKIMAGEA (LVM_FIRST+68)
3218 #define LVM_SETBKIMAGEW (LVM_FIRST+138)
3219 #define LVM_SETBKIMAGE WINELIB_NAME_AW(LVM_SETBKIMAGE)
3220 #define LVM_GETBKIMAGEA (LVM_FIRST+69)
3221 #define LVM_GETBKIMAGEW (LVM_FIRST+139)
3222 #define LVM_GETBKIMAGE WINELIB_NAME_AW(LVM_GETBKIMAGE)
3223 #define LVM_GETWORKAREAS (LVM_FIRST+70)
3224 #define LVM_SETHOVERTIME (LVM_FIRST+71)
3225 #define LVM_GETHOVERTIME (LVM_FIRST+72)
3226 #define LVM_GETNUMBEROFWORKAREAS (LVM_FIRST+73)
3227 #define LVM_SETTOOLTIPS (LVM_FIRST+74)
3228 #define LVM_GETTOOLTIPS (LVM_FIRST+78)
3229 #define LVM_GETUNICODEFORMAT (CCM_GETUNICODEFORMAT)
3230 #define LVM_SETUNICODEFORMAT (CCM_SETUNICODEFORMAT)
3231 #define LVM_SETSELECTEDCOLUMN (LVM_FIRST + 140)
3232 #define LVM_SETTILEWIDTH (LVM_FIRST + 141)
3233 #define LVM_SETVIEW (LVM_FIRST + 142)
3234 #define LVM_GETVIEW (LVM_FIRST + 143)
3235 #define LVM_INSERTGROUP (LVM_FIRST + 145)
3236 #define LVM_SETGROUPINFO (LVM_FIRST + 147)
3237 #define LVM_GETGROUPINFO (LVM_FIRST + 149)
3238 #define LVM_REMOVEGROUP (LVM_FIRST + 150)
3239 #define LVM_MOVEGROUP (LVM_FIRST + 151)
3240 #define LVM_MOVEITEMTOGROUP (LVM_FIRST + 154)
3241 #define LVM_SETGROUPMETRICS (LVM_FIRST + 155)
3242 #define LVM_GETGROUPMETRICS (LVM_FIRST + 156)
3243 #define LVM_ENABLEGROUPVIEW (LVM_FIRST + 157)
3244 #define LVM_SORTGROUPS (LVM_FIRST + 158)
3245 #define LVM_INSERTGROUPSORTED (LVM_FIRST + 159)
3246 #define LVM_REMOVEALLGROUPS (LVM_FIRST + 160)
3247 #define LVM_HASGROUP (LVM_FIRST + 161)
3248 #define LVM_SETTILEVIEWINFO (LVM_FIRST + 162)
3249 #define LVM_GETTILEVIEWINFO (LVM_FIRST + 163)
3250 #define LVM_SETTILEINFO (LVM_FIRST + 164)
3251 #define LVM_GETTILEINFO (LVM_FIRST + 165)
3252 #define LVM_SETINSERTMARK (LVM_FIRST + 166)
3253 #define LVM_GETINSERTMARK (LVM_FIRST + 167)
3254 #define LVM_INSERTMARKHITTEST (LVM_FIRST + 168)
3255 #define LVM_GETINSERTMARKRECT (LVM_FIRST + 169)
3256 #define LVM_SETINSERTMARKCOLOR (LVM_FIRST + 170)
3257 #define LVM_GETINSERTMARKCOLOR (LVM_FIRST + 171)
3258 #define LVM_SETINFOTIP (LVM_FIRST + 173)
3259 #define LVM_GETSELECTEDCOLUMN (LVM_FIRST + 174)
3260 #define LVM_ISGROUPVIEWENABLED (LVM_FIRST + 175)
3261 #define LVM_GETOUTLINECOLOR (LVM_FIRST + 176)
3262 #define LVM_SETOUTLINECOLOR (LVM_FIRST + 177)
3263 #define LVM_CANCELEDITLABEL (LVM_FIRST + 179)
3264 #define LVM_MAPINDEXTOID (LVM_FIRST + 180)
3265 #define LVM_MAPIDTOINDEX (LVM_FIRST + 181)
3266 #define LVM_ISITEMVISIBLE (LVM_FIRST + 182)
3268 #define LVN_FIRST (0U-100U)
3269 #define LVN_LAST (0U-199U)
3270 #define LVN_ITEMCHANGING (LVN_FIRST-0)
3271 #define LVN_ITEMCHANGED (LVN_FIRST-1)
3272 #define LVN_INSERTITEM (LVN_FIRST-2)
3273 #define LVN_DELETEITEM (LVN_FIRST-3)
3274 #define LVN_DELETEALLITEMS (LVN_FIRST-4)
3275 #define LVN_BEGINLABELEDITA (LVN_FIRST-5)
3276 #define LVN_BEGINLABELEDITW (LVN_FIRST-75)
3277 #define LVN_BEGINLABELEDIT WINELIB_NAME_AW(LVN_BEGINLABELEDIT)
3278 #define LVN_ENDLABELEDITA (LVN_FIRST-6)
3279 #define LVN_ENDLABELEDITW (LVN_FIRST-76)
3280 #define LVN_ENDLABELEDIT WINELIB_NAME_AW(LVN_ENDLABELEDIT)
3281 #define LVN_COLUMNCLICK (LVN_FIRST-8)
3282 #define LVN_BEGINDRAG (LVN_FIRST-9)
3283 #define LVN_BEGINRDRAG (LVN_FIRST-11)
3284 #define LVN_ODCACHEHINT (LVN_FIRST-13)
3285 #define LVN_ITEMACTIVATE (LVN_FIRST-14)
3286 #define LVN_ODSTATECHANGED (LVN_FIRST-15)
3287 #define LVN_HOTTRACK (LVN_FIRST-21)
3288 #define LVN_ODFINDITEMA (LVN_FIRST-52)
3289 #define LVN_ODFINDITEMW (LVN_FIRST-79)
3290 #define LVN_ODFINDITEM WINELIB_NAME_AW(LVN_ODFINDITEM)
3291 #define LVN_GETDISPINFOA (LVN_FIRST-50)
3292 #define LVN_GETDISPINFOW (LVN_FIRST-77)
3293 #define LVN_GETDISPINFO WINELIB_NAME_AW(LVN_GETDISPINFO)
3294 #define LVN_SETDISPINFOA (LVN_FIRST-51)
3295 #define LVN_SETDISPINFOW (LVN_FIRST-78)
3296 #define LVN_SETDISPINFO WINELIB_NAME_AW(LVN_SETDISPINFO)
3297 #define LVN_KEYDOWN (LVN_FIRST-55)
3298 #define LVN_MARQUEEBEGIN (LVN_FIRST-56)
3299 #define LVN_GETINFOTIPA (LVN_FIRST-57)
3300 #define LVN_GETINFOTIPW (LVN_FIRST-58)
3301 #define LVN_GETINFOTIP WINELIB_NAME_AW(LVN_GETINFOTIP)
3302 #define LVN_INCREMENTALSEARCHA (LVN_FIRST-62)
3303 #define LVN_INCREMENTALSEARCHW (LVN_FIRST-63)
3304 #define LVN_INCREMENTALSEARCH WINELIB_NAME_AW(LVN_INCREMENTALSEARCH)
3305 #define LVN_BEGINSCROLL (LVN_FIRST-80)
3306 #define LVN_ENDSCROLL (LVN_FIRST-81)
3307 #define LVN_LINKCLICK (LVN_FIRST-84)
3308 #define LVN_ASYNCDRAWN (LVN_FIRST-86)
3309 #define LVN_GETEMPTYMARKUP (LVN_FIRST-87)
3311 /* LVN_INCREMENTALSEARCH return codes */
3312 #define LVNSCH_DEFAULT -1
3313 #define LVNSCH_ERROR -2
3314 #define LVNSCH_IGNORE -3
3316 #define LVA_DEFAULT 0x0000
3317 #define LVA_ALIGNLEFT 0x0001
3318 #define LVA_ALIGNTOP 0x0002
3319 #define LVA_SNAPTOGRID 0x0005
3321 typedef struct tagLVITEMA
3323 UINT mask;
3324 INT iItem;
3325 INT iSubItem;
3326 UINT state;
3327 UINT stateMask;
3328 LPSTR pszText;
3329 INT cchTextMax;
3330 INT iImage;
3331 LPARAM lParam;
3332 /* (_WIN32_IE >= 0x0300) */
3333 INT iIndent;
3334 /* (_WIN32_IE >= 0x0560) */
3335 INT iGroupId;
3336 UINT cColumns;
3337 PUINT puColumns;
3338 /* (_WIN32_WINNT >= 0x0600) */
3339 PINT piColFmt;
3340 INT iGroup;
3341 } LVITEMA, *LPLVITEMA;
3343 typedef struct tagLVITEMW
3345 UINT mask;
3346 INT iItem;
3347 INT iSubItem;
3348 UINT state;
3349 UINT stateMask;
3350 LPWSTR pszText;
3351 INT cchTextMax;
3352 INT iImage;
3353 LPARAM lParam;
3354 /* (_WIN32_IE >= 0x0300) */
3355 INT iIndent;
3356 /* (_WIN32_IE >= 0x0560) */
3357 INT iGroupId;
3358 UINT cColumns;
3359 PUINT puColumns;
3360 /* (_WIN32_WINNT >= 0x0600) */
3361 PINT piColFmt;
3362 INT iGroup;
3363 } LVITEMW, *LPLVITEMW;
3365 #define LVITEM WINELIB_NAME_AW(LVITEM)
3366 #define LPLVITEM WINELIB_NAME_AW(LPLVITEM)
3368 #define LVITEM_V1_SIZEA CCSIZEOF_STRUCT(LVITEMA, lParam)
3369 #define LVITEM_V1_SIZEW CCSIZEOF_STRUCT(LVITEMW, lParam)
3370 #define LVITEM_V1_SIZE WINELIB_NAME_AW(LVITEM_V1_SIZE)
3372 #define LVITEMA_V5_SIZE CCSIZEOF_STRUCT(LVITEMA, puColumns)
3373 #define LVITEMW_V5_SIZE CCSIZEOF_STRUCT(LVITEMW, puColumns)
3374 #define LVITEM_V5_SIZE WINELIB_NAME_AW(LVITEM_V5_SIZE)
3376 #define LV_ITEM LVITEM
3377 #define LV_ITEMA LVITEMA
3378 #define LV_ITEMW LVITEMW
3380 typedef struct LVSETINFOTIP
3382 UINT cbSize;
3383 DWORD dwFlags;
3384 LPWSTR pszText;
3385 int iItem;
3386 int iSubItem;
3387 } LVSETINFOTIP, *PLVSETINFOTIP;
3389 /* ListView background image structs and constants
3390 For _WIN32_IE version 0x400 and later. */
3392 typedef struct tagLVBKIMAGEA
3394 ULONG ulFlags;
3395 HBITMAP hbm;
3396 LPSTR pszImage;
3397 UINT cchImageMax;
3398 int xOffsetPercent;
3399 int yOffsetPercent;
3400 } LVBKIMAGEA, *LPLVBKIMAGEA;
3402 typedef struct tagLVBKIMAGEW
3404 ULONG ulFlags;
3405 HBITMAP hbm;
3406 LPWSTR pszImage;
3407 UINT cchImageMax;
3408 int xOffsetPercent;
3409 int yOffsetPercent;
3410 } LVBKIMAGEW, *LPLVBKIMAGEW;
3412 #define LVBKIMAGE WINELIB_NAME_AW(LVBKIMAGE)
3413 #define LPLVBKIMAGE WINELIB_NAME_AW(LPLVBKIMAGE)
3415 #define LVBKIF_SOURCE_NONE 0x00000000
3416 #define LVBKIF_SOURCE_HBITMAP 0x00000001
3417 #define LVBKIF_SOURCE_URL 0x00000002
3418 #define LVBKIF_SOURCE_MASK 0x00000003
3419 #define LVBKIF_STYLE_NORMAL 0x00000000
3420 #define LVBKIF_STYLE_TILE 0x00000010
3421 #define LVBKIF_STYLE_MASK 0x00000010
3422 #define LVBKIF_FLAG_TILEOFFSET 0x00000100
3423 #define LVBKIF_TYPE_WATERMARK 0x10000000
3425 #define ListView_SetBkImage(hwnd, plvbki) \
3426 (BOOL)SNDMSG((hwnd), LVM_SETBKIMAGE, 0, (LPARAM)plvbki)
3428 #define ListView_GetBkImage(hwnd, plvbki) \
3429 (BOOL)SNDMSG((hwnd), LVM_GETBKIMAGE, 0, (LPARAM)plvbki)
3431 typedef struct tagLVCOLUMNA
3433 UINT mask;
3434 INT fmt;
3435 INT cx;
3436 LPSTR pszText;
3437 INT cchTextMax;
3438 INT iSubItem;
3439 /* (_WIN32_IE >= 0x0300) */
3440 INT iImage;
3441 INT iOrder;
3442 /* (_WIN32_WINNT >= 0x0600) */
3443 INT cxMin;
3444 INT cxDefault;
3445 INT cxIdeal;
3446 } LVCOLUMNA, *LPLVCOLUMNA;
3448 typedef struct tagLVCOLUMNW
3450 UINT mask;
3451 INT fmt;
3452 INT cx;
3453 LPWSTR pszText;
3454 INT cchTextMax;
3455 INT iSubItem;
3456 /* (_WIN32_IE >= 0x0300) */
3457 INT iImage;
3458 INT iOrder;
3459 /* (_WIN32_WINNT >= 0x0600) */
3460 INT cxMin;
3461 INT cxDefault;
3462 INT cxIdeal;
3463 } LVCOLUMNW, *LPLVCOLUMNW;
3465 #define LVCOLUMN WINELIB_NAME_AW(LVCOLUMN)
3466 #define LPLVCOLUMN WINELIB_NAME_AW(LPLVCOLUMN)
3468 #define LVCOLUMN_V1_SIZEA CCSIZEOF_STRUCT(LVCOLUMNA, iSubItem)
3469 #define LVCOLUMN_V1_SIZEW CCSIZEOF_STRUCT(LVCOLUMNW, iSubItem)
3470 #define LVCOLUMN_V1_SIZE WINELIB_NAME_AW(LVCOLUMN_V1_SIZE)
3472 #define LV_COLUMN LVCOLUMN
3475 typedef struct tagNMLISTVIEW
3477 NMHDR hdr;
3478 INT iItem;
3479 INT iSubItem;
3480 UINT uNewState;
3481 UINT uOldState;
3482 UINT uChanged;
3483 POINT ptAction;
3484 LPARAM lParam;
3485 } NMLISTVIEW, *LPNMLISTVIEW;
3487 #define NM_LISTVIEW NMLISTVIEW
3488 #define LPNM_LISTVIEW LPNMLISTVIEW
3490 typedef struct tagNMITEMACTIVATE
3492 NMHDR hdr;
3493 int iItem;
3494 int iSubItem;
3495 UINT uNewState;
3496 UINT uOldState;
3497 UINT uChanged;
3498 POINT ptAction;
3499 LPARAM lParam;
3500 UINT uKeyFlags;
3501 } NMITEMACTIVATE, *LPNMITEMACTIVATE;
3503 #define LVKF_ALT 0x0001
3504 #define LVKF_CONTROL 0x0002
3505 #define LVKF_SHIFT 0x0004
3507 typedef struct tagLVDISPINFO
3509 NMHDR hdr;
3510 LVITEMA item;
3511 } NMLVDISPINFOA, *LPNMLVDISPINFOA;
3513 typedef struct tagLVDISPINFOW
3515 NMHDR hdr;
3516 LVITEMW item;
3517 } NMLVDISPINFOW, *LPNMLVDISPINFOW;
3519 #define NMLVDISPINFO WINELIB_NAME_AW(NMLVDISPINFO)
3520 #define LPNMLVDISPINFO WINELIB_NAME_AW(LPNMLVDISPINFO)
3522 #define LV_DISPINFO NMLVDISPINFO
3523 #define LV_DISPINFOA NMLVDISPINFOA
3524 #define LV_DISPINFOW NMLVDISPINFOW
3526 #include <pshpack1.h>
3527 typedef struct tagLVKEYDOWN
3529 NMHDR hdr;
3530 WORD wVKey;
3531 UINT flags;
3532 } NMLVKEYDOWN, *LPNMLVKEYDOWN;
3533 #include <poppack.h>
3535 #define LV_KEYDOWN NMLVKEYDOWN
3537 typedef struct tagNMLVGETINFOTIPA
3539 NMHDR hdr;
3540 DWORD dwFlags;
3541 LPSTR pszText;
3542 int cchTextMax;
3543 int iItem;
3544 int iSubItem;
3545 LPARAM lParam;
3546 } NMLVGETINFOTIPA, *LPNMLVGETINFOTIPA;
3548 typedef struct tagNMLVGETINFOTIPW
3550 NMHDR hdr;
3551 DWORD dwFlags;
3552 LPWSTR pszText;
3553 int cchTextMax;
3554 int iItem;
3555 int iSubItem;
3556 LPARAM lParam;
3557 } NMLVGETINFOTIPW, *LPNMLVGETINFOTIPW;
3559 #define NMLVGETINFOTIP WINELIB_NAME_AW(NMLVGETINFOTIP)
3560 #define LPNMLVGETINFOTIP WINELIB_NAME_AW(LPNMLVGETINFOTIP)
3562 typedef struct tagLVHITTESTINFO
3564 POINT pt;
3565 UINT flags;
3566 INT iItem;
3567 INT iSubItem;
3568 /* (_WIN32_WINNT >= 0x0600) */
3569 INT iGroup;
3570 } LVHITTESTINFO, *LPLVHITTESTINFO;
3572 #define LV_HITTESTINFO LVHITTESTINFO
3573 #define _LV_HITTESTINFO tagLVHITTESTINFO
3574 #define LVHITTESTINFO_V1_SIZE CCSIZEOF_STRUCT(LVHITTESTINFO,iItem)
3576 typedef struct tagLVFINDINFOA
3578 UINT flags;
3579 LPCSTR psz;
3580 LPARAM lParam;
3581 POINT pt;
3582 UINT vkDirection;
3583 } LVFINDINFOA, *LPLVFINDINFOA;
3585 typedef struct tagLVFINDINFOW
3587 UINT flags;
3588 LPCWSTR psz;
3589 LPARAM lParam;
3590 POINT pt;
3591 UINT vkDirection;
3592 } LVFINDINFOW, *LPLVFINDINFOW;
3594 #define LVFINDINFO WINELIB_NAME_AW(LVFINDINFO)
3595 #define LPLVFINDINFO WINELIB_NAME_AW(LPLVFINDINFO)
3597 #define LV_FINDINFO LVFINDINFO
3598 #define LV_FINDINFOA LVFINDINFOA
3599 #define LV_FINDINFOW LVFINDINFOW
3601 /* Groups relates structures */
3603 typedef struct LVGROUP
3605 UINT cbSize;
3606 UINT mask;
3607 LPWSTR pszHeader;
3608 INT cchHeader;
3609 LPWSTR pszFooter;
3610 INT cchFooter;
3611 INT iGroupId;
3612 UINT stateMask;
3613 UINT state;
3614 UINT uAlign;
3615 /* (_WIN32_WINNT >= 0x0600) */
3616 LPWSTR pszSubtitle;
3617 UINT cchSubtitle;
3618 LPWSTR pszTask;
3619 UINT cchTask;
3620 LPWSTR pszDescriptionTop;
3621 UINT cchDescriptionTop;
3622 LPWSTR pszDescriptionBottom;
3623 UINT cchDescriptionBottom;
3624 INT iTitleImage;
3625 INT iExtendedImage;
3626 INT iFirstItem;
3627 UINT cItems;
3628 LPWSTR pszSubsetTitle;
3629 UINT cchSubsetTitle;
3630 } LVGROUP, *PLVGROUP;
3632 #define LVGROUP_V5_SIZE CCSIZEOF_STRUCT(LVGROUP, uAlign)
3634 typedef struct LVGROUPMETRICS
3636 UINT cbSize;
3637 UINT mask;
3638 UINT Left;
3639 UINT Top;
3640 UINT Right;
3641 UINT Bottom;
3642 COLORREF crLeft;
3643 COLORREF crTop;
3644 COLORREF crRight;
3645 COLORREF crBottom;
3646 COLORREF crRightHeader;
3647 COLORREF crFooter;
3648 } LVGROUPMETRICS, *PLVGROUPMETRICS;
3650 typedef INT (*PFNLVGROUPCOMPARE)(INT, INT, VOID*);
3652 typedef struct LVINSERTGROUPSORTED
3654 PFNLVGROUPCOMPARE pfnGroupCompare;
3655 LPVOID *pvData;
3656 LVGROUP lvGroup;
3657 } LVINSERTGROUPSORTED, *PLVINSERTGROUPSORTED;
3659 /* Tile related structures */
3661 typedef struct LVTILEINFO
3663 UINT cbSize;
3664 int iItem;
3665 UINT cColumns;
3666 PUINT puColumns;
3667 /* (_WIN32_WINNT >= 0x0600) */
3668 int* piColFmt;
3669 } LVTILEINFO, *PLVTILEINFO;
3671 typedef struct LVTILEVIEWINFO
3673 UINT cbSize;
3674 DWORD dwMask;
3675 DWORD dwFlags;
3676 SIZE sizeTile;
3677 int cLines;
3678 RECT rcLabelMargin;
3679 } LVTILEVIEWINFO, *PLVTILEVIEWINFO;
3681 typedef struct LVINSERTMARK
3683 UINT cbSize;
3684 DWORD dwFlags;
3685 int iItem;
3686 DWORD dwReserved;
3687 } LVINSERTMARK, *PLVINSERTMARK;
3689 typedef struct tagTCHITTESTINFO
3691 POINT pt;
3692 UINT flags;
3693 } TCHITTESTINFO, *LPTCHITTESTINFO;
3695 #define TC_HITTESTINFO TCHITTESTINFO
3697 typedef INT (CALLBACK *PFNLVCOMPARE)(LPARAM, LPARAM, LPARAM);
3699 #define NMLVCUSTOMDRAW_V3_SIZE CCSIZEOF_STRUCT(NMLCUSTOMDRW, clrTextBk)
3701 typedef struct tagNMLVCUSTOMDRAW
3703 NMCUSTOMDRAW nmcd;
3704 COLORREF clrText;
3705 COLORREF clrTextBk;
3706 int iSubItem; /* (_WIN32_IE >= 0x0400) */
3707 DWORD dwItemType; /* (_WIN32_IE >= 0x560) */
3708 COLORREF clrFace; /* (_WIN32_IE >= 0x560) */
3709 int iIconEffect; /* (_WIN32_IE >= 0x560) */
3710 int iIconPhase; /* (_WIN32_IE >= 0x560) */
3711 int iPartId; /* (_WIN32_IE >= 0x560) */
3712 int iStateId; /* (_WIN32_IE >= 0x560) */
3713 RECT rcText; /* (_WIN32_IE >= 0x560) */
3714 UINT uAlign; /* (_WIN32_IE >= 0x560) */
3715 } NMLVCUSTOMDRAW, *LPNMLVCUSTOMDRAW;
3717 typedef struct tagNMLVCACHEHINT
3719 NMHDR hdr;
3720 INT iFrom;
3721 INT iTo;
3722 } NMLVCACHEHINT, *LPNMLVCACHEHINT;
3724 #define LPNM_CACHEHINT LPNMLVCACHEHINT
3725 #define PNM_CACHEHINT LPNMLVCACHEHINT
3726 #define NM_CACHEHINT NMLVCACHEHINT
3728 typedef struct tagNMLVFINDITEMA
3730 NMHDR hdr;
3731 int iStart;
3732 LVFINDINFOA lvfi;
3733 } NMLVFINDITEMA, *LPNMLVFINDITEMA;
3735 typedef struct tagNMLVFINDITEMW
3737 NMHDR hdr;
3738 int iStart;
3739 LVFINDINFOW lvfi;
3740 } NMLVFINDITEMW, *LPNMLVFINDITEMW;
3742 #define NMLVFINDITEM WINELIB_NAME_AW(NMLVFINDITEM)
3743 #define LPNMLVFINDITEM WINELIB_NAME_AW(LPNMLVFINDITEM)
3744 #define NM_FINDITEM NMLVFINDITEM
3745 #define LPNM_FINDITEM LPNMLVFINDITEM
3746 #define PNM_FINDITEM LPNMLVFINDITEM
3748 typedef struct tagNMLVODSTATECHANGE
3750 NMHDR hdr;
3751 int iFrom;
3752 int iTo;
3753 UINT uNewState;
3754 UINT uOldState;
3755 } NMLVODSTATECHANGE, *LPNMLVODSTATECHANGE;
3757 #define PNM_ODSTATECHANGE LPNMLVODSTATECHANGE
3758 #define LPNM_ODSTATECHANGE LPNMLVODSTATECHANGE
3759 #define NM_ODSTATECHANGE NMLVODSTATECHANGE
3761 typedef struct NMLVSCROLL
3763 NMHDR hdr;
3764 int dx;
3765 int dy;
3766 } NMLVSCROLL, *LPNMLVSCROLL;
3768 #define ListView_SetItemCount(hwnd,count) \
3769 (BOOL)SNDMSG((hwnd),LVM_SETITEMCOUNT,(WPARAM)(INT)(count),0)
3770 #define ListView_SetTextBkColor(hwnd,clrBk) \
3771 (BOOL)SNDMSG((hwnd),LVM_SETTEXTBKCOLOR,0,(LPARAM)(COLORREF)(clrBk))
3772 #define ListView_SetTextColor(hwnd,clrBk) \
3773 (BOOL)SNDMSG((hwnd),LVM_SETTEXTCOLOR,0,(LPARAM)(COLORREF)(clrBk))
3774 #define ListView_DeleteColumn(hwnd,col)\
3775 (LRESULT)SNDMSG((hwnd),LVM_DELETECOLUMN,0,(LPARAM)(INT)(col))
3776 #define ListView_GetColumnA(hwnd,x,col)\
3777 (LRESULT)SNDMSGA((hwnd),LVM_GETCOLUMNA,(WPARAM)(INT)(x),(LPARAM)(LPLVCOLUMNA)(col))
3778 #define ListView_GetColumnW(hwnd,x,col)\
3779 (LRESULT)SNDMSGW((hwnd),LVM_GETCOLUMNW,(WPARAM)(INT)(x),(LPARAM)(LPLVCOLUMNW)(col))
3780 #define ListView_GetColumn WINELIB_NAME_AW(ListView_GetColumn)
3781 #define ListView_SetColumnA(hwnd,x,col)\
3782 (LRESULT)SNDMSGA((hwnd),LVM_SETCOLUMNA,(WPARAM)(INT)(x),(LPARAM)(LPLVCOLUMNA)(col))
3783 #define ListView_SetColumnW(hwnd,x,col)\
3784 (LRESULT)SNDMSGW((hwnd),LVM_SETCOLUMNW,(WPARAM)(INT)(x),(LPARAM)(LPLVCOLUMNW)(col))
3785 #define ListView_SetColumn WINELIB_NAME_AW(ListView_SetColumn)
3786 #define ListView_GetColumnWidth(hwnd,x)\
3787 (INT)SNDMSG((hwnd),LVM_GETCOLUMNWIDTH,(WPARAM)(INT)(x),0L)
3788 #define ListView_SetColumnWidth(hwnd,x,width)\
3789 (BOOL)SNDMSG((hwnd),LVM_SETCOLUMNWIDTH,(WPARAM)(INT)(x),(LPARAM)(MAKELPARAM(width,0)))
3792 #define ListView_GetNextItem(hwnd,nItem,flags) \
3793 (INT)SNDMSG((hwnd),LVM_GETNEXTITEM,(WPARAM)(INT)(nItem),(LPARAM)(MAKELPARAM(flags,0)))
3794 #define ListView_FindItemA(hwnd,nItem,plvfi) \
3795 (INT)SNDMSGA((hwnd),LVM_FINDITEMA,(WPARAM)(INT)(nItem),(LPARAM)(LVFINDINFOA*)(plvfi))
3796 #define ListView_FindItemW(hwnd,nItem,plvfi) \
3797 (INT)SNDMSGW((hwnd),LVM_FINDITEMW,(WPARAM)(INT)(nItem),(LPARAM)(LVFINDINFOW*)(plvfi))
3798 #define ListView_FindItem WINELIB_NAME_AW(ListView_FindItem)
3800 #define ListView_Arrange(hwnd,code) \
3801 (INT)SNDMSG((hwnd),LVM_ARRANGE,(WPARAM)(INT)(code),0L)
3802 #define ListView_GetItemPosition(hwnd,i,ppt) \
3803 (INT)SNDMSG((hwnd),LVM_GETITEMPOSITION,(WPARAM)(INT)(i),(LPARAM)(LPPOINT)(ppt))
3804 #define ListView_GetItemRect(hwnd,i,prc,code) \
3805 (BOOL)SNDMSG((hwnd), LVM_GETITEMRECT, (WPARAM)(int)(i), \
3806 ((prc) ? (((RECT*)(prc))->left = (code),(LPARAM)(RECT \
3807 *)(prc)) : (LPARAM)(RECT*)NULL))
3808 #define ListView_SetItemA(hwnd,pitem) \
3809 (INT)SNDMSGA((hwnd),LVM_SETITEMA,0,(LPARAM)(const LVITEMA *)(pitem))
3810 #define ListView_SetItemW(hwnd,pitem) \
3811 (INT)SNDMSGW((hwnd),LVM_SETITEMW,0,(LPARAM)(const LVITEMW *)(pitem))
3812 #define ListView_SetItem WINELIB_NAME_AW(ListView_SetItem)
3813 #define ListView_SetItemState(hwnd,i,data,dataMask) \
3814 { LVITEM _LVi; _LVi.state = data; _LVi.stateMask = dataMask;\
3815 SNDMSG(hwnd, LVM_SETITEMSTATE, (WPARAM)(UINT)i, (LPARAM) (LPLVITEM)&_LVi);}
3816 #define ListView_GetItemState(hwnd,i,mask) \
3817 (UINT)SNDMSG((hwnd),LVM_GETITEMSTATE,(WPARAM)(UINT)(i),(LPARAM)(UINT)(mask))
3818 #define ListView_SetCheckState(hwndLV, i, bCheck) \
3819 { LVITEM _LVi; _LVi.state = INDEXTOSTATEIMAGEMASK((bCheck)?2:1); _LVi.stateMask = LVIS_STATEIMAGEMASK; \
3820 SNDMSG(hwndLV, LVM_SETITEMSTATE, (WPARAM)(UINT)(i), (LPARAM)(LPLVITEM)&_LVi);}
3821 #define ListView_GetCheckState(hwndLV, i) \
3822 (((UINT)SNDMSG((hwndLV), LVM_GETITEMSTATE, (i), LVIS_STATEIMAGEMASK) >> 12) - 1)
3823 #define ListView_GetCountPerPage(hwnd) \
3824 (BOOL)SNDMSG((hwnd),LVM_GETCOUNTPERPAGE,0,0L)
3825 #define ListView_GetImageList(hwnd,iImageList) \
3826 (HIMAGELIST)SNDMSG((hwnd),LVM_GETIMAGELIST,(WPARAM)(INT)(iImageList),0L)
3827 #define ListView_GetStringWidthA(hwnd,pstr) \
3828 (INT)SNDMSGA((hwnd),LVM_GETSTRINGWIDTHA,0,(LPARAM)(LPCSTR)(pstr))
3829 #define ListView_GetStringWidthW(hwnd,pstr) \
3830 (INT)SNDMSGW((hwnd),LVM_GETSTRINGWIDTHW,0,(LPARAM)(LPCWSTR)(pstr))
3831 #define ListView_GetStringWidth WINELIB_NAME_AW(ListView_GetStringWidth)
3832 #define ListView_GetTopIndex(hwnd) \
3833 (BOOL)SNDMSG((hwnd),LVM_GETTOPINDEX,0,0L)
3834 #define ListView_Scroll(hwnd,dx,dy) \
3835 (BOOL)SNDMSG((hwnd),LVM_SCROLL,(WPARAM)(INT)(dx),(LPARAM)(INT)(dy))
3836 #define ListView_EnsureVisible(hwnd,i,fPartialOk) \
3837 (BOOL)SNDMSG((hwnd),LVM_ENSUREVISIBLE,(WPARAM)(INT)i,(LPARAM)(BOOL)fPartialOk)
3838 #define ListView_SetBkColor(hwnd,clrBk) \
3839 (BOOL)SNDMSG((hwnd),LVM_SETBKCOLOR,0,(LPARAM)(COLORREF)(clrBk))
3840 #define ListView_SetImageList(hwnd,himl,iImageList) \
3841 (HIMAGELIST)SNDMSG((hwnd),LVM_SETIMAGELIST,(WPARAM)(iImageList),(LPARAM)(HIMAGELIST)(himl))
3842 #define ListView_GetItemCount(hwnd) \
3843 (INT)SNDMSG((hwnd),LVM_GETITEMCOUNT,0,0L)
3844 #define ListView_RedrawItems(hwnd,first,last) \
3845 (BOOL)SNDMSG((hwnd),LVM_REDRAWITEMS,(WPARAM)(INT)(first),(LPARAM)(INT)(last))
3846 #define ListView_GetEditControl(hwnd) \
3847 (HWND)SNDMSG((hwnd), LVM_GETEDITCONTROL, 0, 0)
3848 #define ListView_GetTextColor(hwnd) \
3849 (COLORREF)SNDMSG((hwnd), LVM_GETTEXTCOLOR, 0, 0)
3850 #define ListView_GetTextBkColor(hwnd) \
3851 (COLORREF)SNDMSG((hwnd), LVM_GETTEXTBKCOLOR, 0, 0)
3852 #define ListView_GetBkColor(hwnd) \
3853 (COLORREF)SNDMSG((hwnd), LVM_GETBKCOLOR, 0, 0)
3854 #define ListView_GetItemA(hwnd,pitem) \
3855 (BOOL)SNDMSGA((hwnd),LVM_GETITEMA,0,(LPARAM)(LVITEMA *)(pitem))
3856 #define ListView_GetItemW(hwnd,pitem) \
3857 (BOOL)SNDMSGW((hwnd),LVM_GETITEMW,0,(LPARAM)(LVITEMW *)(pitem))
3858 #define ListView_GetItem WINELIB_NAME_AW(ListView_GetItem)
3859 #define ListView_GetOrigin(hwnd,ppt) \
3860 (BOOL)SNDMSG((hwnd),LVM_GETORIGIN,0,(LPARAM)(POINT *)(ppt))
3862 #define ListView_HitTest(hwnd,pinfo) \
3863 (INT)SNDMSG((hwnd),LVM_HITTEST,0,(LPARAM)(LPLVHITTESTINFO)(pinfo))
3865 #define ListView_InsertItemA(hwnd,pitem) \
3866 (INT)SNDMSGA((hwnd),LVM_INSERTITEMA,0,(LPARAM)(const LVITEMA *)(pitem))
3867 #define ListView_InsertItemW(hwnd,pitem) \
3868 (INT)SNDMSGW((hwnd),LVM_INSERTITEMW,0,(LPARAM)(const LVITEMW *)(pitem))
3869 #define ListView_InsertItem WINELIB_NAME_AW(ListView_InsertItem)
3871 #define ListView_DeleteAllItems(hwnd) \
3872 (BOOL)SNDMSG((hwnd),LVM_DELETEALLITEMS,0,0L)
3874 #define ListView_InsertColumnA(hwnd,iCol,pcol) \
3875 (INT)SNDMSGA((hwnd),LVM_INSERTCOLUMNA,(WPARAM)(INT)(iCol),(LPARAM)(const LVCOLUMNA *)(pcol))
3876 #define ListView_InsertColumnW(hwnd,iCol,pcol) \
3877 (INT)SNDMSGW((hwnd),LVM_INSERTCOLUMNW,(WPARAM)(INT)(iCol),(LPARAM)(const LVCOLUMNW *)(pcol))
3878 #define ListView_InsertColumn WINELIB_NAME_AW(ListView_InsertColumn)
3880 #define ListView_SortItems(hwndLV,_pfnCompare,_lPrm) \
3881 (BOOL)SNDMSG((hwndLV),LVM_SORTITEMS,(WPARAM)(LPARAM)_lPrm,(LPARAM)(PFNLVCOMPARE)_pfnCompare)
3882 #define ListView_SortItemsEx(hwndLV, _pfnCompare, _lPrm) \
3883 (BOOL)SNDMSG((hwndLV), LVM_SORTITEMSEX, (WPARAM)(LPARAM)(_lPrm), (LPARAM)(PFNLVCOMPARE)(_pfnCompare))
3885 #define ListView_SetItemPosition(hwndLV, i, x, y) \
3886 (BOOL)SNDMSG((hwndLV),LVM_SETITEMPOSITION,(WPARAM)(INT)(i),MAKELPARAM((x),(y)))
3887 #define ListView_GetSelectedCount(hwndLV) \
3888 (UINT)SNDMSG((hwndLV),LVM_GETSELECTEDCOUNT,0,0L)
3890 #define ListView_EditLabelA(hwndLV, i) \
3891 (HWND)SNDMSG((hwndLV),LVM_EDITLABELA,(WPARAM)(int)(i), 0L)
3892 #define ListView_EditLabelW(hwndLV, i) \
3893 (HWND)SNDMSG((hwndLV),LVM_EDITLABELW,(WPARAM)(int)(i), 0L)
3894 #define ListView_EditLabel WINELIB_NAME_AW(ListView_EditLabel)
3896 #define ListView_GetItemTextA(hwndLV, i, _iSubItem, _pszText, _cchTextMax) \
3898 LVITEMA _LVi;\
3899 _LVi.iSubItem = _iSubItem;\
3900 _LVi.cchTextMax = _cchTextMax;\
3901 _LVi.pszText = _pszText;\
3902 SNDMSGA(hwndLV, LVM_GETITEMTEXTA, (WPARAM)(i), (LPARAM)&_LVi);\
3904 #define ListView_GetItemTextW(hwndLV, i, _iSubItem, _pszText, _cchTextMax) \
3906 LVITEMW _LVi;\
3907 _LVi.iSubItem = _iSubItem;\
3908 _LVi.cchTextMax = _cchTextMax;\
3909 _LVi.pszText = _pszText;\
3910 SNDMSGW(hwndLV, LVM_GETITEMTEXTW, (WPARAM)(i), (LPARAM)&_LVi);\
3912 #define ListView_GetItemText WINELIB_NAME_AW(ListView_GetItemText)
3913 #define ListView_SetItemPosition32(hwnd,n,x1,y1) \
3914 { POINT ptNewPos; ptNewPos.x = (x1); ptNewPos.y = (y1); SNDMSG((hwnd), LVM_SETITEMPOSITION32, (WPARAM)(int)(n), (LPARAM)&ptNewPos); }
3915 #define ListView_SetItemTextA(hwndLV, i, _iSubItem, _pszText) \
3916 { LVITEMA _LVi; _LVi.iSubItem = _iSubItem; _LVi.pszText = _pszText;\
3917 SNDMSGA(hwndLV, LVM_SETITEMTEXTA, (WPARAM)i, (LPARAM) (LVITEMA*)&_LVi);}
3918 #define ListView_SetItemTextW(hwndLV, i, _iSubItem, _pszText) \
3919 { LVITEMW _LVi; _LVi.iSubItem = _iSubItem; _LVi.pszText = _pszText;\
3920 SNDMSGW(hwndLV, LVM_SETITEMTEXTW, (WPARAM)i, (LPARAM) (LVITEMW*)& _LVi);}
3921 #define ListView_SetItemText WINELIB_NAME_AW(ListView_SetItemText)
3923 #define ListView_DeleteItem(hwndLV, i) \
3924 (BOOL)SNDMSG(hwndLV, LVM_DELETEITEM, (WPARAM)(int)(i), 0L)
3925 #define ListView_Update(hwndLV, i) \
3926 (BOOL)SNDMSG((hwndLV), LVM_UPDATE, (WPARAM)(i), 0L)
3927 #define ListView_GetColumnOrderArray(hwndLV, iCount, pi) \
3928 (BOOL)SNDMSG((hwndLV), LVM_GETCOLUMNORDERARRAY, (WPARAM)iCount, (LPARAM)(LPINT)pi)
3929 #define ListView_GetExtendedListViewStyle(hwndLV) \
3930 (DWORD)SNDMSG((hwndLV), LVM_GETEXTENDEDLISTVIEWSTYLE, 0, 0L)
3931 #define ListView_GetHotCursor(hwndLV) \
3932 (HCURSOR)SNDMSG((hwndLV), LVM_GETHOTCURSOR, 0, 0L)
3933 #define ListView_GetHotItem(hwndLV) \
3934 (int)SNDMSG((hwndLV), LVM_GETHOTITEM, 0, 0L)
3935 #define ListView_GetItemSpacing(hwndLV, fSmall) \
3936 (DWORD)SNDMSG((hwndLV), LVM_GETITEMSPACING, (WPARAM)fSmall, 0L)
3937 #define ListView_GetSubItemRect(hwndLV, iItem, iSubItem, code, prc) \
3938 (BOOL)SNDMSG((hwndLV), LVM_GETSUBITEMRECT, (WPARAM)(int)(iItem), \
3939 ((prc) ? ((((LPRECT)(prc))->top = iSubItem), (((LPRECT)(prc))->left = code), (LPARAM)(prc)) : 0))
3940 #define ListView_GetToolTips(hwndLV) \
3941 (HWND)SNDMSG((hwndLV), LVM_GETTOOLTIPS, 0, 0L)
3942 #define ListView_SetColumnOrderArray(hwndLV, iCount, pi) \
3943 (BOOL)SNDMSG((hwndLV), LVM_SETCOLUMNORDERARRAY, (WPARAM)iCount, (LPARAM)(LPINT)pi)
3944 #define ListView_SetExtendedListViewStyle(hwndLV, dw) \
3945 (DWORD)SNDMSG((hwndLV), LVM_SETEXTENDEDLISTVIEWSTYLE, 0, (LPARAM)dw)
3946 #define ListView_SetExtendedListViewStyleEx(hwndLV, dwMask, dw) \
3947 (DWORD)SNDMSG((hwndLV), LVM_SETEXTENDEDLISTVIEWSTYLE, (WPARAM)dwMask, (LPARAM)dw)
3948 #define ListView_SetHotCursor(hwndLV, hcur) \
3949 (HCURSOR)SNDMSG((hwndLV), LVM_SETHOTCURSOR, 0, (LPARAM)hcur)
3950 #define ListView_SetHotItem(hwndLV, i) \
3951 (int)SNDMSG((hwndLV), LVM_SETHOTITEM, (WPARAM)i, 0L)
3952 #define ListView_SetIconSpacing(hwndLV, cx, cy) \
3953 (DWORD)SNDMSG((hwndLV), LVM_SETICONSPACING, 0, MAKELONG(cx,cy))
3954 #define ListView_SetToolTips(hwndLV, hwndNewHwnd) \
3955 (HWND)SNDMSG((hwndLV), LVM_SETTOOLTIPS, (WPARAM)hwndNewHwnd, 0L)
3956 #define ListView_SubItemHitTest(hwndLV, plvhti) \
3957 (int)SNDMSG((hwndLV), LVM_SUBITEMHITTEST, 0, (LPARAM)(LPLVHITTESTINFO)(plvhti))
3958 #define ListView_GetSelectionMark(hwndLV) \
3959 (int)SNDMSG((hwndLV), LVM_GETSELECTIONMARK, 0, 0)
3960 #define ListView_SetSelectionMark(hwndLV, iItem) \
3961 (int)SNDMSG((hwndLV), LVM_SETSELECTIONMARK, 0, (LPARAM)(iItem))
3962 #define ListView_GetViewRect(hwndLV, prc) \
3963 (BOOL)SNDMSG((hwndLV),LVM_GETVIEWRECT,0,(LPARAM)(LPRECT)(prc))
3964 #define ListView_GetHeader(hwndLV) \
3965 (HWND)SNDMSG((hwndLV),LVM_GETHEADER,0,0L)
3966 #define ListView_SetSelectedColumn(hwnd, iCol) \
3967 SNDMSG((hwnd), LVM_SETSELECTEDCOLUMN, (WPARAM)iCol, 0)
3968 #define ListView_SetTileWidth(hwnd, cpWidth) \
3969 SNDMSG((hwnd), LVM_SETTILEWIDTH, (WPARAM)cpWidth, 0)
3970 #define ListView_SetView(hwnd, iView) \
3971 (DWORD)SNDMSG((hwnd), LVM_SETVIEW, (WPARAM)(DWORD)iView, 0)
3972 #define ListView_GetView(hwnd) \
3973 (DWORD)SNDMSG((hwnd), LVM_GETVIEW, 0, 0)
3974 #define ListView_InsertGroup(hwnd, index, pgrp) \
3975 SNDMSG((hwnd), LVM_INSERTGROUP, (WPARAM)index, (LPARAM)pgrp)
3976 #define ListView_SetGroupHeaderImageList(hwnd, himl) \
3977 SNDMSG((hwnd), LVM_SETIMAGELIST, (WPARAM)LVSIL_GROUPHEADER, (LPARAM)himl)
3978 #define ListView_GetGroupHeaderImageList(hwnd) \
3979 SNDMSG((hwnd), LVM_GETIMAGELIST, (WPARAM)LVSIL_GROUPHEADER, 0)
3980 #define ListView_SetGroupInfo(hwnd, iGroupId, pgrp) \
3981 SNDMSG((hwnd), LVM_SETGROUPINFO, (WPARAM)iGroupId, (LPARAM)pgrp)
3982 #define ListView_GetGroupInfo(hwnd, iGroupId, pgrp) \
3983 SNDMSG((hwnd), LVM_GETGROUPINFO, (WPARAM)iGroupId, (LPARAM)pgrp)
3984 #define ListView_RemoveGroup(hwnd, iGroupId) \
3985 SNDMSG((hwnd), LVM_REMOVEGROUP, (WPARAM)iGroupId, 0)
3986 #define ListView_MoveGroup(hwnd, iGroupId, toIndex) \
3987 SNDMSG((hwnd), LVM_MOVEGROUP, (WPARAM)iGroupId, (LPARAM)toIndex)
3988 #define ListView_MoveItemToGroup(hwnd, idItemFrom, idGroupTo) \
3989 SNDMSG((hwnd), LVM_MOVEITEMTOGROUP, (WPARAM)idItemFrom, (LPARAM)idGroupTo)
3990 #define ListView_SetGroupMetrics(hwnd, pGroupMetrics) \
3991 SNDMSG((hwnd), LVM_SETGROUPMETRICS, 0, (LPARAM)pGroupMetrics)
3992 #define ListView_GetGroupMetrics(hwnd, pGroupMetrics) \
3993 SNDMSG((hwnd), LVM_GETGROUPMETRICS, 0, (LPARAM)pGroupMetrics)
3994 #define ListView_EnableGroupView(hwnd, fEnable) \
3995 SNDMSG((hwnd), LVM_ENABLEGROUPVIEW, (WPARAM)fEnable, 0)
3996 #define ListView_SortGroups(hwnd, _pfnGroupCompate, _plv) \
3997 SNDMSG((hwnd), LVM_SORTGROUPS, (WPARAM)_pfnGroupCompate, (LPARAM)_plv)
3998 #define ListView_InsertGroupSorted(hwnd, structInsert) \
3999 SNDMSG((hwnd), LVM_INSERTGROUPSORTED, (WPARAM)structInsert, 0)
4000 #define ListView_RemoveAllGroups(hwnd) \
4001 SNDMSG((hwnd), LVM_REMOVEALLGROUPS, 0, 0)
4002 #define ListView_HasGroup(hwnd, dwGroupId) \
4003 SNDMSG((hwnd), LVM_HASGROUP, dwGroupId, 0)
4004 #define ListView_SetTileViewInfo(hwnd, ptvi) \
4005 SNDMSG((hwnd), LVM_SETTILEVIEWINFO, 0, (LPARAM)ptvi)
4006 #define ListView_GetTileViewInfo(hwnd, ptvi) \
4007 SNDMSG((hwnd), LVM_GETTILEVIEWINFO, 0, (LPARAM)ptvi)
4008 #define ListView_SetTileInfo(hwnd, pti) \
4009 SNDMSG((hwnd), LVM_SETTILEINFO, 0, (LPARAM)pti)
4010 #define ListView_GetTileInfo(hwnd, pti) \
4011 SNDMSG((hwnd), LVM_GETTILEINFO, 0, (LPARAM)pti)
4012 #define ListView_SetInsertMark(hwnd, lvim) \
4013 (BOOL)SNDMSG((hwnd), LVM_SETINSERTMARK, (WPARAM) 0, (LPARAM) (lvim))
4014 #define ListView_GetInsertMark(hwnd, lvim) \
4015 (BOOL)SNDMSG((hwnd), LVM_GETINSERTMARK, (WPARAM) 0, (LPARAM) (lvim))
4016 #define ListView_InsertMarkHitTest(hwnd, point, lvim) \
4017 (int)SNDMSG((hwnd), LVM_INSERTMARKHITTEST, (WPARAM)(LPPOINT)(point), (LPARAM)(LPLVINSERTMARK)(lvim))
4018 #define ListView_GetInsertMarkRect(hwnd, rc) \
4019 (int)SNDMSG((hwnd), LVM_GETINSERTMARKRECT, (WPARAM)0, (LPARAM)(LPRECT)(rc))
4020 #define ListView_SetInsertMarkColor(hwnd, color) \
4021 (COLORREF)SNDMSG((hwnd), LVM_SETINSERTMARKCOLOR, (WPARAM)0, (LPARAM)(COLORREF)(color))
4022 #define ListView_GetInsertMarkColor(hwnd) \
4023 (COLORREF)SNDMSG((hwnd), LVM_GETINSERTMARKCOLOR, (WPARAM)0, (LPARAM)0)
4024 #define ListView_SetInfoTip(hwndLV, plvInfoTip)\
4025 (BOOL)SNDMSG((hwndLV), LVM_SETINFOTIP, (WPARAM)0, (LPARAM)plvInfoTip)
4026 #define ListView_GetSelectedColumn(hwnd) \
4027 (UINT)SNDMSG((hwnd), LVM_GETSELECTEDCOLUMN, 0, 0)
4028 #define ListView_IsGroupViewEnabled(hwnd) \
4029 (BOOL)SNDMSG((hwnd), LVM_ISGROUPVIEWENABLED, 0, 0)
4030 #define ListView_GetOutlineColor(hwnd) \
4031 (COLORREF)SNDMSG((hwnd), LVM_GETOUTLINECOLOR, 0, 0)
4032 #define ListView_SetOutlineColor(hwnd, color) \
4033 (COLORREF)SNDMSG((hwnd), LVM_SETOUTLINECOLOR, (WPARAM)0, (LPARAM)(COLORREF)(color))
4034 #define ListView_CancelEditLabel(hwnd) \
4035 (VOID)SNDMSG((hwnd), LVM_CANCELEDITLABEL, (WPARAM)0, (LPARAM)0)
4036 #define ListView_MapIndexToID(hwnd, index) \
4037 (UINT)SNDMSG((hwnd), LVM_MAPINDEXTOID, (WPARAM)index, (LPARAM)0)
4038 #define ListView_MapIDToIndex(hwnd, id) \
4039 (UINT)SNDMSG((hwnd), LVM_MAPIDTOINDEX, (WPARAM)id, (LPARAM)0)
4040 #define ListView_SetUnicodeFormat(hwnd, fUnicode) \
4041 (BOOL)SNDMSG((hwnd), LVM_SETUNICODEFORMAT, (WPARAM)(fUnicode), 0)
4042 #define ListView_GetUnicodeFormat(hwnd) \
4043 (BOOL)SNDMSG((hwnd), LVM_GETUNICODEFORMAT, 0, 0)
4045 /* Tab Control */
4047 #define WC_TABCONTROLA "SysTabControl32"
4048 #if defined(__GNUC__)
4049 # define WC_TABCONTROLW (const WCHAR []){ 'S','y','s', \
4050 'T','a','b','C','o','n','t','r','o','l','3','2',0 }
4051 #elif defined(_MSC_VER)
4052 # define WC_TABCONTROLW L"SysTabControl32"
4053 #else
4054 static const WCHAR WC_TABCONTROLW[] = { 'S','y','s',
4055 'T','a','b','C','o','n','t','r','o','l','3','2',0 };
4056 #endif
4057 #define WC_TABCONTROL WINELIB_NAME_AW(WC_TABCONTROL)
4059 /* tab control styles */
4060 #define TCS_SCROLLOPPOSITE 0x0001 /* assumes multiline tab */
4061 #define TCS_BOTTOM 0x0002
4062 #define TCS_RIGHT 0x0002
4063 #define TCS_MULTISELECT 0x0004 /* allow multi-select in button mode */
4064 #define TCS_FLATBUTTONS 0x0008
4065 #define TCS_FORCEICONLEFT 0x0010
4066 #define TCS_FORCELABELLEFT 0x0020
4067 #define TCS_HOTTRACK 0x0040
4068 #define TCS_VERTICAL 0x0080
4069 #define TCS_TABS 0x0000
4070 #define TCS_BUTTONS 0x0100
4071 #define TCS_SINGLELINE 0x0000
4072 #define TCS_MULTILINE 0x0200
4073 #define TCS_RIGHTJUSTIFY 0x0000
4074 #define TCS_FIXEDWIDTH 0x0400
4075 #define TCS_RAGGEDRIGHT 0x0800
4076 #define TCS_FOCUSONBUTTONDOWN 0x1000
4077 #define TCS_OWNERDRAWFIXED 0x2000
4078 #define TCS_TOOLTIPS 0x4000
4079 #define TCS_FOCUSNEVER 0x8000
4080 #define TCS_EX_FLATSEPARATORS 0x00000001 /* to be used with */
4081 #define TCS_EX_REGISTERDROP 0x00000002 /* TCM_SETEXTENDEDSTYLE */
4084 #define TCM_FIRST 0x1300
4086 #define TCM_GETIMAGELIST (TCM_FIRST + 2)
4087 #define TCM_SETIMAGELIST (TCM_FIRST + 3)
4088 #define TCM_GETITEMCOUNT (TCM_FIRST + 4)
4089 #define TCM_GETITEM WINELIB_NAME_AW(TCM_GETITEM)
4090 #define TCM_GETITEMA (TCM_FIRST + 5)
4091 #define TCM_GETITEMW (TCM_FIRST + 60)
4092 #define TCM_SETITEMA (TCM_FIRST + 6)
4093 #define TCM_SETITEMW (TCM_FIRST + 61)
4094 #define TCM_SETITEM WINELIB_NAME_AW(TCM_SETITEM)
4095 #define TCM_INSERTITEMA (TCM_FIRST + 7)
4096 #define TCM_INSERTITEMW (TCM_FIRST + 62)
4097 #define TCM_INSERTITEM WINELIB_NAME_AW(TCM_INSERTITEM)
4098 #define TCM_DELETEITEM (TCM_FIRST + 8)
4099 #define TCM_DELETEALLITEMS (TCM_FIRST + 9)
4100 #define TCM_GETITEMRECT (TCM_FIRST + 10)
4101 #define TCM_GETCURSEL (TCM_FIRST + 11)
4102 #define TCM_SETCURSEL (TCM_FIRST + 12)
4103 #define TCM_HITTEST (TCM_FIRST + 13)
4104 #define TCM_SETITEMEXTRA (TCM_FIRST + 14)
4105 #define TCM_ADJUSTRECT (TCM_FIRST + 40)
4106 #define TCM_SETITEMSIZE (TCM_FIRST + 41)
4107 #define TCM_REMOVEIMAGE (TCM_FIRST + 42)
4108 #define TCM_SETPADDING (TCM_FIRST + 43)
4109 #define TCM_GETROWCOUNT (TCM_FIRST + 44)
4110 #define TCM_GETTOOLTIPS (TCM_FIRST + 45)
4111 #define TCM_SETTOOLTIPS (TCM_FIRST + 46)
4112 #define TCM_GETCURFOCUS (TCM_FIRST + 47)
4113 #define TCM_SETCURFOCUS (TCM_FIRST + 48)
4114 #define TCM_SETMINTABWIDTH (TCM_FIRST + 49)
4115 #define TCM_DESELECTALL (TCM_FIRST + 50)
4116 #define TCM_HIGHLIGHTITEM (TCM_FIRST + 51)
4117 #define TCM_SETEXTENDEDSTYLE (TCM_FIRST + 52)
4118 #define TCM_GETEXTENDEDSTYLE (TCM_FIRST + 53)
4119 #define TCM_SETUNICODEFORMAT CCM_SETUNICODEFORMAT
4120 #define TCM_GETUNICODEFORMAT CCM_GETUNICODEFORMAT
4123 #define TCIF_TEXT 0x0001
4124 #define TCIF_IMAGE 0x0002
4125 #define TCIF_RTLREADING 0x0004
4126 #define TCIF_PARAM 0x0008
4127 #define TCIF_STATE 0x0010
4129 #define TCIS_BUTTONPRESSED 0x0001
4130 #define TCIS_HIGHLIGHTED 0x0002
4132 /* TabCtrl Macros */
4133 #define TabCtrl_GetImageList(hwnd) \
4134 (HIMAGELIST)SNDMSG((hwnd), TCM_GETIMAGELIST, 0, 0L)
4135 #define TabCtrl_SetImageList(hwnd, himl) \
4136 (HIMAGELIST)SNDMSG((hwnd), TCM_SETIMAGELIST, 0, (LPARAM)(UINT)(HIMAGELIST)(himl))
4137 #define TabCtrl_GetItemCount(hwnd) \
4138 (int)SNDMSG((hwnd), TCM_GETITEMCOUNT, 0, 0L)
4139 #define TabCtrl_GetItemA(hwnd, iItem, pitem) \
4140 (BOOL)SNDMSGA((hwnd), TCM_GETITEMA, (WPARAM)(int)iItem, (LPARAM)(TCITEMA *)(pitem))
4141 #define TabCtrl_GetItemW(hwnd, iItem, pitem) \
4142 (BOOL)SNDMSGW((hwnd), TCM_GETITEMW, (WPARAM)(int)iItem, (LPARAM)(TCITEMW *)(pitem))
4143 #define TabCtrl_GetItem WINELIB_NAME_AW(TabCtrl_GetItem)
4144 #define TabCtrl_SetItemA(hwnd, iItem, pitem) \
4145 (BOOL)SNDMSGA((hwnd), TCM_SETITEMA, (WPARAM)(int)iItem, (LPARAM)(TCITEMA *)(pitem))
4146 #define TabCtrl_SetItemW(hwnd, iItem, pitem) \
4147 (BOOL)SNDMSGW((hwnd), TCM_SETITEMW, (WPARAM)(int)iItem, (LPARAM)(TCITEMW *)(pitem))
4148 #define TabCtrl_SetItem WINELIB_NAME_AW(TabCtrl_SetItem)
4149 #define TabCtrl_InsertItemA(hwnd, iItem, pitem) \
4150 (int)SNDMSGA((hwnd), TCM_INSERTITEMA, (WPARAM)(int)iItem, (LPARAM)(const TCITEMA *)(pitem))
4151 #define TabCtrl_InsertItemW(hwnd, iItem, pitem) \
4152 (int)SNDMSGW((hwnd), TCM_INSERTITEMW, (WPARAM)(int)iItem, (LPARAM)(const TCITEMW *)(pitem))
4153 #define TabCtrl_InsertItem WINELIB_NAME_AW(TabCtrl_InsertItem)
4154 #define TabCtrl_DeleteItem(hwnd, i) \
4155 (BOOL)SNDMSG((hwnd), TCM_DELETEITEM, (WPARAM)(int)(i), 0L)
4156 #define TabCtrl_DeleteAllItems(hwnd) \
4157 (BOOL)SNDMSG((hwnd), TCM_DELETEALLITEMS, 0, 0L)
4158 #define TabCtrl_GetItemRect(hwnd, i, prc) \
4159 (BOOL)SNDMSG((hwnd), TCM_GETITEMRECT, (WPARAM)(int)(i), (LPARAM)(RECT *)(prc))
4160 #define TabCtrl_GetCurSel(hwnd) \
4161 (int)SNDMSG((hwnd), TCM_GETCURSEL, 0, 0)
4162 #define TabCtrl_SetCurSel(hwnd, i) \
4163 (int)SNDMSG((hwnd), TCM_SETCURSEL, (WPARAM)i, 0)
4164 #define TabCtrl_HitTest(hwndTC, pinfo) \
4165 (int)SNDMSG((hwndTC), TCM_HITTEST, 0, (LPARAM)(TC_HITTESTINFO *)(pinfo))
4166 #define TabCtrl_SetItemExtra(hwndTC, cb) \
4167 (BOOL)SNDMSG((hwndTC), TCM_SETITEMEXTRA, (WPARAM)(cb), 0L)
4168 #define TabCtrl_AdjustRect(hwnd, bLarger, prc) \
4169 (int)SNDMSG(hwnd, TCM_ADJUSTRECT, (WPARAM)(BOOL)bLarger, (LPARAM)(RECT *)prc)
4170 #define TabCtrl_SetItemSize(hwnd, x, y) \
4171 (DWORD)SNDMSG((hwnd), TCM_SETITEMSIZE, 0, MAKELPARAM(x,y))
4172 #define TabCtrl_RemoveImage(hwnd, i) \
4173 (void)SNDMSG((hwnd), TCM_REMOVEIMAGE, i, 0L)
4174 #define TabCtrl_SetPadding(hwnd, cx, cy) \
4175 (void)SNDMSG((hwnd), TCM_SETPADDING, 0, MAKELPARAM(cx, cy))
4176 #define TabCtrl_GetRowCount(hwnd) \
4177 (int)SNDMSG((hwnd), TCM_GETROWCOUNT, 0, 0L)
4178 #define TabCtrl_GetToolTips(hwnd) \
4179 (HWND)SNDMSG((hwnd), TCM_GETTOOLTIPS, 0, 0L)
4180 #define TabCtrl_SetToolTips(hwnd, hwndTT) \
4181 (void)SNDMSG((hwnd), TCM_SETTOOLTIPS, (WPARAM)hwndTT, 0L)
4182 #define TabCtrl_GetCurFocus(hwnd) \
4183 (int)SNDMSG((hwnd), TCM_GETCURFOCUS, 0, 0)
4184 #define TabCtrl_SetCurFocus(hwnd, i) \
4185 SNDMSG((hwnd),TCM_SETCURFOCUS, i, 0)
4186 #define TabCtrl_SetMinTabWidth(hwnd, x) \
4187 (int)SNDMSG((hwnd), TCM_SETMINTABWIDTH, 0, x)
4188 #define TabCtrl_DeselectAll(hwnd, fExcludeFocus)\
4189 (void)SNDMSG((hwnd), TCM_DESELECTALL, fExcludeFocus, 0)
4190 #define TabCtrl_GetUnicodeFormat(hwnd) \
4191 (BOOL)SNDMSG((hwnd), TCM_GETUNICODEFORMAT, 0, 0)
4192 #define TabCtrl_SetUnicodeFormat(hwnd, fUnicode) \
4193 (BOOL)SNDMSG((hwnd), TCM_SETUNICODEFORMAT, (WPARAM)fUnicode, 0)
4194 #define TabCtrl_GetExtendedStyle(hwnd) \
4195 (BOOL)SNDMSG((hwnd), TCM_GETEXTENDEDSTYLE, 0, 0)
4196 #define TabCtrl_SetExtendedStyle(hwnd, dwExStyle) \
4197 (BOOL)SNDMSG((hwnd), TCM_GETEXTENDEDSTYLE, 0, (LPARAM)dwExStyle)
4198 #define TabCtrl_HighlightItem(hwnd, i, fHighlight) \
4199 (BOOL)SNDMSG((hwnd), TCM_HIGHLIGHTITEM, (WPARAM)i, (LPARAM)MAKELONG(fHighlight, 0))
4201 /* constants for TCHITTESTINFO */
4203 #define TCHT_NOWHERE 0x01
4204 #define TCHT_ONITEMICON 0x02
4205 #define TCHT_ONITEMLABEL 0x04
4206 #define TCHT_ONITEM (TCHT_ONITEMICON | TCHT_ONITEMLABEL)
4208 typedef struct tagTCITEMHEADERA
4210 UINT mask;
4211 UINT lpReserved1;
4212 UINT lpReserved2;
4213 LPSTR pszText;
4214 int cchTextMax;
4215 int iImage;
4216 } TCITEMHEADERA, *LPTCITEMHEADERA;
4218 typedef struct tagTCITEMHEADERW
4220 UINT mask;
4221 UINT lpReserved1;
4222 UINT lpReserved2;
4223 LPWSTR pszText;
4224 int cchTextMax;
4225 int iImage;
4226 } TCITEMHEADERW, *LPTCITEMHEADERW;
4228 #define TCITEMHEADER WINELIB_NAME_AW(TCITEMHEADER)
4229 #define LPTCITEMHEADER WINELIB_NAME_AW(LPTCITEMHEADER)
4230 #define TC_ITEMHEADER WINELIB_NAME_AW(TCITEMHEADER)
4231 #define LPTC_ITEMHEADER WINELIB_NAME_AW(LPTCITEMHEADER)
4233 typedef struct tagTCITEMA
4235 UINT mask;
4236 UINT dwState;
4237 UINT dwStateMask;
4238 LPSTR pszText;
4239 INT cchTextMax;
4240 INT iImage;
4241 LPARAM lParam;
4242 } TCITEMA, *LPTCITEMA;
4244 typedef struct tagTCITEMW
4246 UINT mask;
4247 DWORD dwState;
4248 DWORD dwStateMask;
4249 LPWSTR pszText;
4250 INT cchTextMax;
4251 INT iImage;
4252 LPARAM lParam;
4253 } TCITEMW, *LPTCITEMW;
4255 #define TCITEM WINELIB_NAME_AW(TCITEM)
4256 #define LPTCITEM WINELIB_NAME_AW(LPTCITEM)
4257 #define TC_ITEM WINELIB_NAME_AW(TCITEM)
4258 #define LPTC_ITEM WINELIB_NAME_AW(LPTCITEM)
4260 #define TCN_FIRST (0U-550U)
4261 #define TCN_LAST (0U-580U)
4262 #define TCN_KEYDOWN (TCN_FIRST - 0)
4263 #define TCN_SELCHANGE (TCN_FIRST - 1)
4264 #define TCN_SELCHANGING (TCN_FIRST - 2)
4265 #define TCN_GETOBJECT (TCN_FIRST - 3)
4267 #include <pshpack1.h>
4268 typedef struct tagTCKEYDOWN
4270 NMHDR hdr;
4271 WORD wVKey;
4272 UINT flags;
4273 } NMTCKEYDOWN;
4274 #include <poppack.h>
4276 #define TC_KEYDOWN NMTCKEYDOWN
4278 /* ComboBoxEx control */
4280 #define WC_COMBOBOXEXA "ComboBoxEx32"
4281 #if defined(__GNUC__)
4282 # define WC_COMBOBOXEXW (const WCHAR []){ 'C','o','m','b','o', \
4283 'B','o','x','E','x','3','2',0 }
4284 #elif defined(_MSC_VER)
4285 # define WC_COMBOBOXEXW L"ComboBoxEx32"
4286 #else
4287 static const WCHAR WC_COMBOBOXEXW[] = { 'C','o','m','b','o',
4288 'B','o','x','E','x','3','2',0 };
4289 #endif
4290 #define WC_COMBOBOXEX WINELIB_NAME_AW(WC_COMBOBOXEX)
4292 #define CBEIF_TEXT 0x00000001
4293 #define CBEIF_IMAGE 0x00000002
4294 #define CBEIF_SELECTEDIMAGE 0x00000004
4295 #define CBEIF_OVERLAY 0x00000008
4296 #define CBEIF_INDENT 0x00000010
4297 #define CBEIF_LPARAM 0x00000020
4298 #define CBEIF_DI_SETITEM 0x10000000
4300 #define CBEM_INSERTITEMA (WM_USER+1)
4301 #define CBEM_INSERTITEMW (WM_USER+11)
4302 #define CBEM_INSERTITEM WINELIB_NAME_AW(CBEM_INSERTITEM)
4303 #define CBEM_SETIMAGELIST (WM_USER+2)
4304 #define CBEM_GETIMAGELIST (WM_USER+3)
4305 #define CBEM_GETITEMA (WM_USER+4)
4306 #define CBEM_GETITEMW (WM_USER+13)
4307 #define CBEM_GETITEM WINELIB_NAME_AW(CBEM_GETITEM)
4308 #define CBEM_SETITEMA (WM_USER+5)
4309 #define CBEM_SETITEMW (WM_USER+12)
4310 #define CBEM_SETITEM WINELIB_NAME_AW(CBEM_SETITEM)
4311 #define CBEM_DELETEITEM CB_DELETESTRING
4312 #define CBEM_GETCOMBOCONTROL (WM_USER+6)
4313 #define CBEM_GETEDITCONTROL (WM_USER+7)
4314 #define CBEM_SETEXSTYLE (WM_USER+8)
4315 #define CBEM_GETEXSTYLE (WM_USER+9)
4316 #define CBEM_GETEXTENDEDSTYLE (WM_USER+9)
4317 #define CBEM_SETEXTENDEDSTYLE (WM_USER+14)
4318 #define CBEM_SETUNICODEFORMAT CCM_SETUNICODEFORMAT
4319 #define CBEM_GETUNICODEFORMAT CCM_GETUNICODEFORMAT
4320 #define CBEM_HASEDITCHANGED (WM_USER+10)
4321 #define CBEM_SETWINDOWTHEME CCM_SETWINDOWTHEME
4323 #define CBEIF_TEXT 0x00000001
4324 #define CBEIF_IMAGE 0x00000002
4325 #define CBEIF_SELECTEDIMAGE 0x00000004
4326 #define CBEIF_OVERLAY 0x00000008
4327 #define CBEIF_INDENT 0x00000010
4328 #define CBEIF_LPARAM 0x00000020
4329 #define CBEIF_DI_SETITEM 0x10000000
4331 #define CBEN_FIRST (0U-800U)
4332 #define CBEN_LAST (0U-830U)
4334 #define CBEN_GETDISPINFOA (CBEN_FIRST - 0)
4335 #define CBEN_GETDISPINFOW (CBEN_FIRST - 7)
4336 #define CBEN_GETDISPINFO WINELIB_NAME_AW(CBEN_GETDISPINFO)
4337 #define CBEN_INSERTITEM (CBEN_FIRST - 1)
4338 #define CBEN_DELETEITEM (CBEN_FIRST - 2)
4339 #define CBEN_BEGINEDIT (CBEN_FIRST - 4)
4340 #define CBEN_ENDEDITA (CBEN_FIRST - 5)
4341 #define CBEN_ENDEDITW (CBEN_FIRST - 6)
4342 #define CBEN_ENDEDIT WINELIB_NAME_AW(CBEN_ENDEDIT)
4343 #define CBEN_DRAGBEGINA (CBEN_FIRST - 8)
4344 #define CBEN_DRAGBEGINW (CBEN_FIRST - 9)
4345 #define CBEN_DRAGBEGIN WINELIB_NAME_AW(CBEN_DRAGBEGIN)
4347 #define CBES_EX_NOEDITIMAGE 0x00000001
4348 #define CBES_EX_NOEDITIMAGEINDENT 0x00000002
4349 #define CBES_EX_PATHWORDBREAKPROC 0x00000004
4350 #define CBES_EX_NOSIZELIMIT 0x00000008
4351 #define CBES_EX_CASESENSITIVE 0x00000010
4354 typedef struct tagCOMBOBOXEXITEMA
4356 UINT mask;
4357 INT_PTR iItem;
4358 LPSTR pszText;
4359 int cchTextMax;
4360 int iImage;
4361 int iSelectedImage;
4362 int iOverlay;
4363 int iIndent;
4364 LPARAM lParam;
4365 } COMBOBOXEXITEMA, *PCOMBOBOXEXITEMA;
4366 typedef COMBOBOXEXITEMA const *PCCOMBOEXITEMA; /* Yes, there's a BOX missing */
4368 typedef struct tagCOMBOBOXEXITEMW
4370 UINT mask;
4371 INT_PTR iItem;
4372 LPWSTR pszText;
4373 int cchTextMax;
4374 int iImage;
4375 int iSelectedImage;
4376 int iOverlay;
4377 int iIndent;
4378 LPARAM lParam;
4379 } COMBOBOXEXITEMW, *PCOMBOBOXEXITEMW;
4380 typedef COMBOBOXEXITEMW const *PCCOMBOEXITEMW; /* Yes, there's a BOX missing */
4382 #define COMBOBOXEXITEM WINELIB_NAME_AW(COMBOBOXEXITEM)
4383 #define PCOMBOBOXEXITEM WINELIB_NAME_AW(PCOMBOBOXEXITEM)
4384 #define PCCOMBOBOXEXITEM WINELIB_NAME_AW(PCCOMBOEXITEM) /* Yes, there's a BOX missing */
4386 #define CBENF_KILLFOCUS 1
4387 #define CBENF_RETURN 2
4388 #define CBENF_ESCAPE 3
4389 #define CBENF_DROPDOWN 4
4391 #define CBEMAXSTRLEN 260
4393 typedef struct tagNMCBEENDEDITW
4395 NMHDR hdr;
4396 BOOL fChanged;
4397 int iNewSelection;
4398 WCHAR szText[CBEMAXSTRLEN];
4399 int iWhy;
4400 } NMCBEENDEDITW, *LPNMCBEENDEDITW, *PNMCBEENDEDITW;
4402 typedef struct tagNMCBEENDEDITA
4404 NMHDR hdr;
4405 BOOL fChanged;
4406 int iNewSelection;
4407 char szText[CBEMAXSTRLEN];
4408 int iWhy;
4409 } NMCBEENDEDITA, *LPNMCBEENDEDITA, *PNMCBEENDEDITA;
4411 #define NMCBEENDEDIT WINELIB_NAME_AW(NMCBEENDEDIT)
4412 #define LPNMCBEENDEDIT WINELIB_NAME_AW(LPNMCBEENDEDIT)
4413 #define PNMCBEENDEDIT WINELIB_NAME_AW(PNMCBEENDEDIT)
4415 typedef struct
4417 NMHDR hdr;
4418 COMBOBOXEXITEMA ceItem;
4419 } NMCOMBOBOXEXA, *PNMCOMBOBOXEXA;
4421 typedef struct
4423 NMHDR hdr;
4424 COMBOBOXEXITEMW ceItem;
4425 } NMCOMBOBOXEXW, *PNMCOMBOBOXEXW;
4427 #define NMCOMBOBOXEX WINELIB_NAME_AW(NMCOMBOBOXEX)
4428 #define PNMCOMBOBOXEX WINELIB_NAME_AW(PNMCOMBOBOXEX)
4430 typedef struct
4432 NMHDR hdr;
4433 int iItemid;
4434 char szText[CBEMAXSTRLEN];
4435 } NMCBEDRAGBEGINA, *PNMCBEDRAGBEGINA, *LPNMCBEDRAGBEGINA;
4437 typedef struct
4439 NMHDR hdr;
4440 int iItemid;
4441 WCHAR szText[CBEMAXSTRLEN];
4442 } NMCBEDRAGBEGINW, *PNMCBEDRAGBEGINW, *LPNMCBEDRAGBEGINW;
4444 #define NMCBEDRAGBEGIN WINELIB_NAME_AW(NMCBEDRAGBEGIN)
4445 #define PNMCBEDRAGBEGIN WINELIB_NAME_AW(PNMCBEDRAGBEGIN)
4446 #define LPNMCBEDRAGBEGIN WINELIB_NAME_AW(LPNMCBEDRAGBEGIN)
4449 /* Hotkey control */
4451 #define HOTKEY_CLASSA "msctls_hotkey32"
4452 #if defined(__GNUC__)
4453 # define HOTKEY_CLASSW (const WCHAR []){ 'm','s','c','t','l','s','_', \
4454 'h','o','t','k','e','y','3','2',0 }
4455 #elif defined(_MSC_VER)
4456 # define HOTKEY_CLASSW L"msctls_hotkey32"
4457 #else
4458 static const WCHAR HOTKEY_CLASSW[] = { 'm','s','c','t','l','s','_',
4459 'h','o','t','k','e','y','3','2',0 };
4460 #endif
4461 #define HOTKEY_CLASS WINELIB_NAME_AW(HOTKEY_CLASS)
4463 #define HOTKEYF_SHIFT 0x01
4464 #define HOTKEYF_CONTROL 0x02
4465 #define HOTKEYF_ALT 0x04
4466 #define HOTKEYF_EXT 0x08
4468 #define HKCOMB_NONE 0x0001
4469 #define HKCOMB_S 0x0002
4470 #define HKCOMB_C 0x0004
4471 #define HKCOMB_A 0x0008
4472 #define HKCOMB_SC 0x0010
4473 #define HKCOMB_SA 0x0020
4474 #define HKCOMB_CA 0x0040
4475 #define HKCOMB_SCA 0x0080
4477 #define HKM_SETHOTKEY (WM_USER+1)
4478 #define HKM_GETHOTKEY (WM_USER+2)
4479 #define HKM_SETRULES (WM_USER+3)
4482 /* animate control */
4484 #define ANIMATE_CLASSA "SysAnimate32"
4485 #if defined(__GNUC__)
4486 # define ANIMATE_CLASSW (const WCHAR []){ 'S','y','s', \
4487 'A','n','i','m','a','t','e','3','2',0 }
4488 #elif defined(_MSC_VER)
4489 # define ANIMATE_CLASSW L"SysAnimate32"
4490 #else
4491 static const WCHAR ANIMATE_CLASSW[] = { 'S','y','s',
4492 'A','n','i','m','a','t','e','3','2',0 };
4493 #endif
4494 #define ANIMATE_CLASS WINELIB_NAME_AW(ANIMATE_CLASS)
4496 #define ACS_CENTER 0x0001
4497 #define ACS_TRANSPARENT 0x0002
4498 #define ACS_AUTOPLAY 0x0004
4499 #define ACS_TIMER 0x0008 /* no threads, just timers */
4501 #define ACM_OPENA (WM_USER+100)
4502 #define ACM_OPENW (WM_USER+103)
4503 #define ACM_OPEN WINELIB_NAME_AW(ACM_OPEN)
4504 #define ACM_PLAY (WM_USER+101)
4505 #define ACM_STOP (WM_USER+102)
4507 #define ACN_START 1
4508 #define ACN_STOP 2
4510 #define Animate_CreateA(hwndP,id,dwStyle,hInstance) \
4511 CreateWindowA(ANIMATE_CLASSA,NULL,dwStyle,0,0,0,0,hwndP,(HMENU)(id),hInstance,NULL)
4512 #define Animate_CreateW(hwndP,id,dwStyle,hInstance) \
4513 CreateWindowW(ANIMATE_CLASSW,NULL,dwStyle,0,0,0,0,hwndP,(HMENU)(id),hInstance,NULL)
4514 #define Animate_Create WINELIB_NAME_AW(Animate_Create)
4515 #define Animate_OpenA(hwnd,szName) \
4516 (BOOL)SNDMSGA(hwnd,ACM_OPENA,0,(LPARAM)(LPSTR)(szName))
4517 #define Animate_OpenW(hwnd,szName) \
4518 (BOOL)SNDMSGW(hwnd,ACM_OPENW,0,(LPARAM)(LPWSTR)(szName))
4519 #define Animate_Open WINELIB_NAME_AW(Animate_Open)
4520 #define Animate_OpenExA(hwnd,hInst,szName) \
4521 (BOOL)SNDMSGA(hwnd,ACM_OPENA,(WPARAM)hInst,(LPARAM)(LPSTR)(szName))
4522 #define Animate_OpenExW(hwnd,hInst,szName) \
4523 (BOOL)SNDMSGW(hwnd,ACM_OPENW,(WPARAM)hInst,(LPARAM)(LPWSTR)(szName))
4524 #define Animate_OpenEx WINELIB_NAME_AW(Animate_OpenEx)
4525 #define Animate_Play(hwnd,from,to,rep) \
4526 (BOOL)SNDMSG(hwnd,ACM_PLAY,(WPARAM)(UINT)(rep),(LPARAM)MAKELONG(from,to))
4527 #define Animate_Stop(hwnd) \
4528 (BOOL)SNDMSG(hwnd,ACM_STOP,0,0)
4529 #define Animate_Close(hwnd) \
4530 (BOOL)SNDMSG(hwnd,ACM_OPENA,0,0)
4531 #define Animate_Seek(hwnd,frame) \
4532 (BOOL)SNDMSG(hwnd,ACM_PLAY,1,(LPARAM)MAKELONG(frame,frame))
4535 /**************************************************************************
4536 * IP Address control
4539 #define WC_IPADDRESSA "SysIPAddress32"
4540 #if defined(__GNUC__)
4541 # define WC_IPADDRESSW (const WCHAR []){ 'S','y','s', \
4542 'I','P','A','d','d','r','e','s','s','3','2',0 }
4543 #elif defined(_MSC_VER)
4544 # define WC_IPADDRESSW L"SysIPAddress32"
4545 #else
4546 static const WCHAR WC_IPADDRESSW[] = { 'S','y','s',
4547 'I','P','A','d','d','r','e','s','s','3','2',0 };
4548 #endif
4549 #define WC_IPADDRESS WINELIB_NAME_AW(WC_IPADDRESS)
4551 #define IPM_CLEARADDRESS (WM_USER+100)
4552 #define IPM_SETADDRESS (WM_USER+101)
4553 #define IPM_GETADDRESS (WM_USER+102)
4554 #define IPM_SETRANGE (WM_USER+103)
4555 #define IPM_SETFOCUS (WM_USER+104)
4556 #define IPM_ISBLANK (WM_USER+105)
4558 #define IPN_FIRST (0U-860U)
4559 #define IPN_LAST (0U-879U)
4560 #define IPN_FIELDCHANGED (IPN_FIRST-0)
4562 typedef struct tagNMIPADDRESS
4564 NMHDR hdr;
4565 INT iField;
4566 INT iValue;
4567 } NMIPADDRESS, *LPNMIPADDRESS;
4569 #define MAKEIPRANGE(low,high) \
4570 ((LPARAM)(WORD)(((BYTE)(high)<<8)+(BYTE)(low)))
4571 #define MAKEIPADDRESS(b1,b2,b3,b4) \
4572 ((LPARAM)(((DWORD)(b1)<<24)+((DWORD)(b2)<<16)+((DWORD)(b3)<<8)+((DWORD)(b4))))
4574 #define FIRST_IPADDRESS(x) (((x)>>24)&0xff)
4575 #define SECOND_IPADDRESS(x) (((x)>>16)&0xff)
4576 #define THIRD_IPADDRESS(x) (((x)>>8)&0xff)
4577 #define FOURTH_IPADDRESS(x) ((x)&0xff)
4580 /**************************************************************************
4581 * Native Font control
4584 #define WC_NATIVEFONTCTLA "NativeFontCtl"
4585 #if defined(__GNUC__)
4586 # define WC_NATIVEFONTCTLW (const WCHAR []){ 'N','a','t','i','v','e', \
4587 'F','o','n','t','C','t','l',0 }
4588 #elif defined(_MSC_VER)
4589 # define WC_NATIVEFONTCTLW L"NativeFontCtl"
4590 #else
4591 static const WCHAR WC_NATIVEFONTCTLW[] = { 'N','a','t','i','v','e',
4592 'F','o','n','t','C','t','l',0 };
4593 #endif
4594 #define WC_NATIVEFONTCTL WINELIB_NAME_AW(WC_NATIVEFONTCTL)
4596 #define NFS_EDIT 0x0001
4597 #define NFS_STATIC 0x0002
4598 #define NFS_LISTCOMBO 0x0004
4599 #define NFS_BUTTON 0x0008
4600 #define NFS_ALL 0x0010
4603 /**************************************************************************
4604 * Month calendar control
4608 #define MONTHCAL_CLASSA "SysMonthCal32"
4609 #if defined(__GNUC__)
4610 # define MONTHCAL_CLASSW (const WCHAR []){ 'S','y','s', \
4611 'M','o','n','t','h','C','a','l','3','2',0 }
4612 #elif defined(_MSC_VER)
4613 # define MONTHCAL_CLASSW L"SysMonthCal32"
4614 #else
4615 static const WCHAR MONTHCAL_CLASSW[] = { 'S','y','s',
4616 'M','o','n','t','h','C','a','l','3','2',0 };
4617 #endif
4618 #define MONTHCAL_CLASS WINELIB_NAME_AW(MONTHCAL_CLASS)
4620 #define MCM_FIRST 0x1000
4621 #define MCN_FIRST (0U-750U)
4622 #define MCN_LAST (0U-759U)
4625 #define MCM_GETCURSEL (MCM_FIRST + 1)
4626 #define MCM_SETCURSEL (MCM_FIRST + 2)
4627 #define MCM_GETMAXSELCOUNT (MCM_FIRST + 3)
4628 #define MCM_SETMAXSELCOUNT (MCM_FIRST + 4)
4629 #define MCM_GETSELRANGE (MCM_FIRST + 5)
4630 #define MCM_SETSELRANGE (MCM_FIRST + 6)
4631 #define MCM_GETMONTHRANGE (MCM_FIRST + 7)
4632 #define MCM_SETDAYSTATE (MCM_FIRST + 8)
4633 #define MCM_GETMINREQRECT (MCM_FIRST + 9)
4634 #define MCM_SETCOLOR (MCM_FIRST + 10)
4635 #define MCM_GETCOLOR (MCM_FIRST + 11)
4636 #define MCM_SETTODAY (MCM_FIRST + 12)
4637 #define MCM_GETTODAY (MCM_FIRST + 13)
4638 #define MCM_HITTEST (MCM_FIRST + 14)
4639 #define MCM_SETFIRSTDAYOFWEEK (MCM_FIRST + 15)
4640 #define MCM_GETFIRSTDAYOFWEEK (MCM_FIRST + 16)
4641 #define MCM_GETRANGE (MCM_FIRST + 17)
4642 #define MCM_SETRANGE (MCM_FIRST + 18)
4643 #define MCM_GETMONTHDELTA (MCM_FIRST + 19)
4644 #define MCM_SETMONTHDELTA (MCM_FIRST + 20)
4645 #define MCM_GETMAXTODAYWIDTH (MCM_FIRST + 21)
4646 #define MCM_GETUNICODEFORMAT CCM_GETUNICODEFORMAT
4647 #define MCM_SETUNICODEFORMAT CCM_SETUNICODEFORMAT
4650 /* Notifications */
4652 #define MCN_SELCHANGE (MCN_FIRST + 1)
4653 #define MCN_GETDAYSTATE (MCN_FIRST + 3)
4654 #define MCN_SELECT (MCN_FIRST + 4)
4656 #define MCSC_BACKGROUND 0
4657 #define MCSC_TEXT 1
4658 #define MCSC_TITLEBK 2
4659 #define MCSC_TITLETEXT 3
4660 #define MCSC_MONTHBK 4
4661 #define MCSC_TRAILINGTEXT 5
4663 #define MCS_DAYSTATE 0x0001
4664 #define MCS_MULTISELECT 0x0002
4665 #define MCS_WEEKNUMBERS 0x0004
4666 #define MCS_NOTODAY 0x0010
4667 #define MCS_NOTODAYCIRCLE 0x0008
4669 #define MCHT_TITLE 0x00010000
4670 #define MCHT_CALENDAR 0x00020000
4671 #define MCHT_TODAYLINK 0x00030000
4673 #define MCHT_NEXT 0x01000000
4674 #define MCHT_PREV 0x02000000
4675 #define MCHT_NOWHERE 0x00000000
4676 #define MCHT_TITLEBK (MCHT_TITLE)
4677 #define MCHT_TITLEMONTH (MCHT_TITLE | 0x0001)
4678 #define MCHT_TITLEYEAR (MCHT_TITLE | 0x0002)
4679 #define MCHT_TITLEBTNNEXT (MCHT_TITLE | MCHT_NEXT | 0x0003)
4680 #define MCHT_TITLEBTNPREV (MCHT_TITLE | MCHT_PREV | 0x0003)
4682 #define MCHT_CALENDARBK (MCHT_CALENDAR)
4683 #define MCHT_CALENDARDATE (MCHT_CALENDAR | 0x0001)
4684 #define MCHT_CALENDARDATENEXT (MCHT_CALENDARDATE | MCHT_NEXT)
4685 #define MCHT_CALENDARDATEPREV (MCHT_CALENDARDATE | MCHT_PREV)
4686 #define MCHT_CALENDARDAY (MCHT_CALENDAR | 0x0002)
4687 #define MCHT_CALENDARWEEKNUM (MCHT_CALENDAR | 0x0003)
4691 #define GMR_VISIBLE 0
4692 #define GMR_DAYSTATE 1
4695 /* Month calendar's structures */
4698 typedef struct {
4699 UINT cbSize;
4700 POINT pt;
4701 UINT uHit;
4702 SYSTEMTIME st;
4703 } MCHITTESTINFO, *PMCHITTESTINFO;
4705 typedef struct tagNMSELCHANGE
4707 NMHDR nmhdr;
4708 SYSTEMTIME stSelStart;
4709 SYSTEMTIME stSelEnd;
4710 } NMSELCHANGE, *LPNMSELCHANGE;
4712 typedef NMSELCHANGE NMSELECT, *LPNMSELECT;
4713 typedef DWORD MONTHDAYSTATE, *LPMONTHDAYSTATE;
4715 typedef struct tagNMDAYSTATE
4717 NMHDR nmhdr;
4718 SYSTEMTIME stStart;
4719 int cDayState;
4720 LPMONTHDAYSTATE prgDayState;
4721 } NMDAYSTATE, *LPNMDAYSTATE;
4724 /* macros */
4726 #define MonthCal_GetCurSel(hmc, pst) \
4727 (BOOL)SNDMSGA(hmc, MCM_GETCURSEL, 0, (LPARAM)(pst))
4728 #define MonthCal_SetCurSel(hmc, pst) \
4729 (BOOL)SNDMSGA(hmc, MCM_SETCURSEL, 0, (LPARAM)(pst))
4730 #define MonthCal_GetMaxSelCount(hmc) \
4731 (DWORD)SNDMSGA(hmc, MCM_GETMAXSELCOUNT, 0, 0L)
4732 #define MonthCal_SetMaxSelCount(hmc, n) \
4733 (BOOL)SNDMSGA(hmc, MCM_SETMAXSELCOUNT, (WPARAM)(n), 0L)
4734 #define MonthCal_GetSelRange(hmc, rgst) \
4735 SNDMSGA(hmc, MCM_GETSELRANGE, 0, (LPARAM) (rgst))
4736 #define MonthCal_SetSelRange(hmc, rgst) \
4737 SNDMSGA(hmc, MCM_SETSELRANGE, 0, (LPARAM) (rgst))
4738 #define MonthCal_GetMonthRange(hmc, gmr, rgst) \
4739 (DWORD)SNDMSGA(hmc, MCM_GETMONTHRANGE, (WPARAM)(gmr), (LPARAM)(rgst))
4740 #define MonthCal_SetDayState(hmc, cbds, rgds) \
4741 SNDMSGA(hmc, MCM_SETDAYSTATE, (WPARAM)(cbds), (LPARAM)(rgds))
4742 #define MonthCal_GetMinReqRect(hmc, prc) \
4743 SNDMSGA(hmc, MCM_GETMINREQRECT, 0, (LPARAM)(prc))
4744 #define MonthCal_SetColor(hmc, iColor, clr)\
4745 SNDMSGA(hmc, MCM_SETCOLOR, iColor, clr)
4746 #define MonthCal_GetColor(hmc, iColor) \
4747 SNDMSGA(hmc, MCM_SETCOLOR, iColor, 0)
4748 #define MonthCal_GetToday(hmc, pst)\
4749 (BOOL)SNDMSGA(hmc, MCM_GETTODAY, 0, (LPARAM)pst)
4750 #define MonthCal_SetToday(hmc, pst)\
4751 SNDMSGA(hmc, MCM_SETTODAY, 0, (LPARAM)pst)
4752 #define MonthCal_HitTest(hmc, pinfo) \
4753 SNDMSGA(hmc, MCM_HITTEST, 0, (LPARAM)(PMCHITTESTINFO)pinfo)
4754 #define MonthCal_SetFirstDayOfWeek(hmc, iDay) \
4755 SNDMSGA(hmc, MCM_SETFIRSTDAYOFWEEK, 0, iDay)
4756 #define MonthCal_GetFirstDayOfWeek(hmc) \
4757 (DWORD)SNDMSGA(hmc, MCM_GETFIRSTDAYOFWEEK, 0, 0)
4758 #define MonthCal_GetRange(hmc, rgst) \
4759 (DWORD)SNDMSGA(hmc, MCM_GETRANGE, 0, (LPARAM)(rgst))
4760 #define MonthCal_SetRange(hmc, gd, rgst) \
4761 (BOOL)SNDMSGA(hmc, MCM_SETRANGE, (WPARAM)(gd), (LPARAM)(rgst))
4762 #define MonthCal_GetMonthDelta(hmc) \
4763 (int)SNDMSGA(hmc, MCM_GETMONTHDELTA, 0, 0)
4764 #define MonthCal_SetMonthDelta(hmc, n) \
4765 (int)SNDMSGA(hmc, MCM_SETMONTHDELTA, n, 0)
4766 #define MonthCal_GetMaxTodayWidth(hmc) \
4767 (DWORD)SNDMSGA(hmc, MCM_GETMAXTODAYWIDTH, 0, 0)
4768 #define MonthCal_SetUnicodeFormat(hwnd, fUnicode) \
4769 (BOOL)SNDMSGA((hwnd), MCM_SETUNICODEFORMAT, (WPARAM)(fUnicode), 0)
4770 #define MonthCal_GetUnicodeFormat(hwnd) \
4771 (BOOL)SNDMSGA((hwnd), MCM_GETUNICODEFORMAT, 0, 0)
4774 /**************************************************************************
4775 * Date and time picker control
4778 #define DATETIMEPICK_CLASSA "SysDateTimePick32"
4779 #if defined(__GNUC__)
4780 # define DATETIMEPICK_CLASSW (const WCHAR []){ 'S','y','s', \
4781 'D','a','t','e','T','i','m','e','P','i','c','k','3','2',0 }
4782 #elif defined(_MSC_VER)
4783 # define DATETIMEPICK_CLASSW L"SysDateTimePick32"
4784 #else
4785 static const WCHAR DATETIMEPICK_CLASSW[] = { 'S','y','s',
4786 'D','a','t','e','T','i','m','e','P','i','c','k','3','2',0 };
4787 #endif
4788 #define DATETIMEPICK_CLASS WINELIB_NAME_AW(DATETIMEPICK_CLASS)
4790 #define DTM_FIRST 0x1000
4791 #define DTN_FIRST (0U-760U)
4792 #define DTN_LAST (0U-799U)
4795 #define DTM_GETSYSTEMTIME (DTM_FIRST+1)
4796 #define DTM_SETSYSTEMTIME (DTM_FIRST+2)
4797 #define DTM_GETRANGE (DTM_FIRST+3)
4798 #define DTM_SETRANGE (DTM_FIRST+4)
4799 #define DTM_SETFORMATA (DTM_FIRST+5)
4800 #define DTM_SETFORMATW (DTM_FIRST + 50)
4801 #define DTM_SETFORMAT WINELIB_NAME_AW(DTM_SETFORMAT)
4802 #define DTM_SETMCCOLOR (DTM_FIRST+6)
4803 #define DTM_GETMCCOLOR (DTM_FIRST+7)
4804 #define DTM_GETMONTHCAL (DTM_FIRST+8)
4805 #define DTM_SETMCFONT (DTM_FIRST+9)
4806 #define DTM_GETMCFONT (DTM_FIRST+10)
4809 /* Datetime Notifications */
4811 #define DTN_DATETIMECHANGE (DTN_FIRST + 1)
4812 #define DTN_USERSTRINGA (DTN_FIRST + 2)
4813 #define DTN_WMKEYDOWNA (DTN_FIRST + 3)
4814 #define DTN_FORMATA (DTN_FIRST + 4)
4815 #define DTN_FORMATQUERYA (DTN_FIRST + 5)
4816 #define DTN_DROPDOWN (DTN_FIRST + 6)
4817 #define DTN_CLOSEUP (DTN_FIRST + 7)
4818 #define DTN_USERSTRINGW (DTN_FIRST + 15)
4819 #define DTN_WMKEYDOWNW (DTN_FIRST + 16)
4820 #define DTN_FORMATW (DTN_FIRST + 17)
4821 #define DTN_FORMATQUERYW (DTN_FIRST + 18)
4823 #define DTN_USERSTRING WINELIB_NAME_AW(DTN_USERSTRING)
4824 #define DTN_WMKEYDOWN WINELIB_NAME_AW(DTN_WMKEYDOWN)
4825 #define DTN_FORMAT WINELIB_NAME_AW(DTN_FORMAT)
4826 #define DTN_FORMATQUERY WINELIB_NAME_AW(DTN_FORMATQUERY)
4828 #define DTS_SHORTDATEFORMAT 0x0000
4829 #define DTS_UPDOWN 0x0001
4830 #define DTS_SHOWNONE 0x0002
4831 #define DTS_LONGDATEFORMAT 0x0004
4832 #define DTS_TIMEFORMAT 0x0009
4833 #define DTS_APPCANPARSE 0x0010
4834 #define DTS_RIGHTALIGN 0x0020
4836 typedef struct tagNMDATETIMECHANGE
4838 NMHDR nmhdr;
4839 DWORD dwFlags;
4840 SYSTEMTIME st;
4841 } NMDATETIMECHANGE, *LPNMDATETIMECHANGE;
4843 typedef struct tagNMDATETIMESTRINGA
4845 NMHDR nmhdr;
4846 LPCSTR pszUserString;
4847 SYSTEMTIME st;
4848 DWORD dwFlags;
4849 } NMDATETIMESTRINGA, *LPNMDATETIMESTRINGA;
4851 typedef struct tagNMDATETIMESTRINGW
4853 NMHDR nmhdr;
4854 LPCWSTR pszUserString;
4855 SYSTEMTIME st;
4856 DWORD dwFlags;
4857 } NMDATETIMESTRINGW, *LPNMDATETIMESTRINGW;
4859 DECL_WINELIB_TYPE_AW(NMDATETIMESTRING)
4860 DECL_WINELIB_TYPE_AW(LPNMDATETIMESTRING)
4862 typedef struct tagNMDATETIMEWMKEYDOWNA
4864 NMHDR nmhdr;
4865 int nVirtKey;
4866 LPCSTR pszFormat;
4867 SYSTEMTIME st;
4868 } NMDATETIMEWMKEYDOWNA, *LPNMDATETIMEWMKEYDOWNA;
4870 typedef struct tagNMDATETIMEWMKEYDOWNW
4872 NMHDR nmhdr;
4873 int nVirtKey;
4874 LPCWSTR pszFormat;
4875 SYSTEMTIME st;
4876 } NMDATETIMEWMKEYDOWNW, *LPNMDATETIMEWMKEYDOWNW;
4878 DECL_WINELIB_TYPE_AW(NMDATETIMEWMKEYDOWN)
4879 DECL_WINELIB_TYPE_AW(LPNMDATETIMEWMKEYDOWN)
4881 typedef struct tagNMDATETIMEFORMATA
4883 NMHDR nmhdr;
4884 LPCSTR pszFormat;
4885 SYSTEMTIME st;
4886 LPCSTR pszDisplay;
4887 CHAR szDisplay[64];
4888 } NMDATETIMEFORMATA, *LPNMDATETIMEFORMATA;
4891 typedef struct tagNMDATETIMEFORMATW
4893 NMHDR nmhdr;
4894 LPCWSTR pszFormat;
4895 SYSTEMTIME st;
4896 LPCWSTR pszDisplay;
4897 WCHAR szDisplay[64];
4898 } NMDATETIMEFORMATW, *LPNMDATETIMEFORMATW;
4900 DECL_WINELIB_TYPE_AW(NMDATETIMEFORMAT)
4901 DECL_WINELIB_TYPE_AW(LPNMDATETIMEFORMAT)
4903 typedef struct tagNMDATETIMEFORMATQUERYA
4905 NMHDR nmhdr;
4906 LPCSTR pszFormat;
4907 SIZE szMax;
4908 } NMDATETIMEFORMATQUERYA, *LPNMDATETIMEFORMATQUERYA;
4910 typedef struct tagNMDATETIMEFORMATQUERYW
4912 NMHDR nmhdr;
4913 LPCWSTR pszFormat;
4914 SIZE szMax;
4915 } NMDATETIMEFORMATQUERYW, *LPNMDATETIMEFORMATQUERYW;
4917 DECL_WINELIB_TYPE_AW(NMDATETIMEFORMATQUERY)
4918 DECL_WINELIB_TYPE_AW(LPNMDATETIMEFORMATQUERY)
4922 #define GDT_ERROR -1
4923 #define GDT_VALID 0
4924 #define GDT_NONE 1
4926 #define GDTR_MIN 0x0001
4927 #define GDTR_MAX 0x0002
4930 #define DateTime_GetSystemtime(hdp, pst) \
4931 (DWORD)SNDMSGA (hdp, DTM_GETSYSTEMTIME , 0, (LPARAM)(pst))
4932 #define DateTime_SetSystemtime(hdp, gd, pst) \
4933 (BOOL)SNDMSGA (hdp, DTM_SETSYSTEMTIME, (LPARAM)(gd), (LPARAM)(pst))
4934 #define DateTime_GetRange(hdp, rgst) \
4935 (DWORD)SNDMSGA (hdp, DTM_GETRANGE, 0, (LPARAM)(rgst))
4936 #define DateTime_SetRange(hdp, gd, rgst) \
4937 (BOOL)SNDMSGA (hdp, DTM_SETRANGE, (WPARAM)(gd), (LPARAM)(rgst))
4938 #define DateTime_SetFormatA(hdp, sz) \
4939 (BOOL)SNDMSGA (hdp, DTM_SETFORMATA, 0, (LPARAM)(sz))
4940 #define DateTime_SetFormatW(hdp, sz) \
4941 (BOOL)SNDMSGW (hdp, DTM_SETFORMATW, 0, (LPARAM)(sz))
4942 #define DateTime_SetFormat WINELIB_NAME_AW(DateTime_SetFormat)
4943 #define DateTime_GetMonthCalColor(hdp, iColor) \
4944 SNDMSGA (hdp, DTM_GETMCCOLOR, iColor, 0)
4945 #define DateTime_SetMonthCalColor(hdp, iColor, clr) \
4946 SNDMSGA (hdp, DTM_SETMCCOLOR, iColor, clr)
4947 #define DateTime_GetMonthCal(hdp) \
4948 (HWND) SNDMSGA (hdp, DTM_GETMONTHCAL, 0, 0)
4949 #define DateTime_SetMonthCalFont(hdp, hfont, fRedraw) \
4950 SNDMSGA (hdp, DTM_SETMCFONT, (WPARAM)hfont, (LPARAM)fRedraw)
4951 #define DateTime_GetMonthCalFont(hdp) \
4952 SNDMSGA (hdp, DTM_GETMCFONT, 0, 0)
4954 #define DA_LAST (0x7fffffff)
4955 #define DPA_APPEND (0x7fffffff)
4956 #define DPA_ERR (-1)
4958 #define DSA_APPEND (0x7fffffff)
4959 #define DSA_ERR (-1)
4961 struct _DSA;
4962 typedef struct _DSA *HDSA;
4964 typedef INT (CALLBACK *PFNDSAENUMCALLBACK)(LPVOID, LPVOID);
4966 HDSA WINAPI DSA_Create(INT, INT);
4967 BOOL WINAPI DSA_Destroy(HDSA);
4968 void WINAPI DSA_DestroyCallback(HDSA, PFNDSAENUMCALLBACK, LPVOID);
4969 LPVOID WINAPI DSA_GetItemPtr(HDSA, INT);
4970 INT WINAPI DSA_InsertItem(HDSA, INT, LPVOID);
4972 #define DPAS_SORTED 0x0001
4973 #define DPAS_INSERTBEFORE 0x0002
4974 #define DPAS_INSERTAFTER 0x0004
4977 struct _DPA;
4978 typedef struct _DPA *HDPA;
4980 typedef INT (CALLBACK *PFNDPAENUMCALLBACK)(LPVOID, LPVOID);
4981 typedef INT (CALLBACK *PFNDPACOMPARE)(LPVOID, LPVOID, LPARAM);
4983 HDPA WINAPI DPA_Create(INT);
4984 BOOL WINAPI DPA_Destroy(HDPA);
4985 LPVOID WINAPI DPA_DeletePtr(HDPA, INT);
4986 BOOL WINAPI DPA_DeleteAllPtrs(HDPA);
4987 BOOL WINAPI DPA_SetPtr(HDPA, INT, LPVOID);
4988 LPVOID WINAPI DPA_GetPtr(HDPA, INT);
4989 INT WINAPI DPA_InsertPtr(HDPA, INT, LPVOID);
4990 BOOL WINAPI DPA_Sort(HDPA, PFNDPACOMPARE, LPARAM);
4991 void WINAPI DPA_EnumCallback(HDPA, PFNDPAENUMCALLBACK, LPVOID);
4992 void WINAPI DPA_DestroyCallback(HDPA, PFNDPAENUMCALLBACK, LPVOID);
4993 INT WINAPI DPA_Search(HDPA, LPVOID, INT, PFNDPACOMPARE, LPARAM, UINT);
4995 BOOL WINAPI Str_SetPtrW (LPWSTR *, LPCWSTR);
4997 /**************************************************************************
4998 * SysLink control
5001 #if defined(__GNUC__)
5002 # define WC_LINK (const WCHAR []){ 'S','y','s','L','i','n','k',0 }
5003 #elif defined(_MSC_VER)
5004 # define WC_LINK L"SysLink"
5005 #else
5006 static const WCHAR WC_LINK[] = { 'S','y','s','L','i','n','k',0 };
5007 #endif
5009 /* SysLink messages */
5010 #define LM_HITTEST (WM_USER + 768)
5011 #define LM_GETIDEALHEIGHT (WM_USER + 769)
5012 #define LM_GETIDEALSIZE (LM_GETIDEALHEIGHT)
5013 #define LM_SETITEM (WM_USER + 770)
5014 #define LM_GETITEM (WM_USER + 771)
5016 /* SysLink links flags */
5018 #define LIF_ITEMINDEX 1
5019 #define LIF_STATE 2
5020 #define LIF_ITEMID 4
5021 #define LIF_URL 8
5023 /* SysLink links states */
5025 #define LIS_FOCUSED 1
5026 #define LIS_ENABLED 2
5027 #define LIS_VISITED 4
5029 /* SysLink misc. */
5031 #define INVALID_LINK_INDEX (-1)
5032 #define MAX_LINKID_TEXT 48
5033 #define L_MAX_URL_LENGTH 2084
5035 /* SysLink structures */
5037 typedef struct tagLITEM
5039 UINT mask;
5040 int iLink;
5041 UINT state;
5042 UINT stateMask;
5043 WCHAR szID[MAX_LINKID_TEXT];
5044 WCHAR szUrl[L_MAX_URL_LENGTH];
5045 } LITEM, *PLITEM;
5047 typedef struct tagLHITTESTINFO
5049 POINT pt;
5050 LITEM item;
5051 } LHITTESTINFO, *PLHITTESTINFO;
5053 typedef struct tagNMLINK
5055 NMHDR hdr;
5056 LITEM item;
5057 } NMLINK, *PNMLINK;
5059 typedef struct tagNMLVLINK
5061 NMHDR hdr;
5062 LITEM link;
5063 int iItem;
5064 int iSubItem;
5065 } NMLVLINK, *PNMLVLINK;
5067 /**************************************************************************
5068 * Static control
5071 #define WC_STATICA "Static"
5072 #if defined(__GNUC__)
5073 # define WC_STATICW (const WCHAR []){ 'S','t','a','t','i','c',0 }
5074 #elif defined(_MSC_VER)
5075 # define WC_STATICW L"Static"
5076 #else
5077 static const WCHAR WC_STATICW[] = { 'S','t','a','t','i','c',0 };
5078 #endif
5079 #define WC_STATIC WINELIB_NAME_AW(WC_STATIC)
5081 /**************************************************************************
5082 * Combobox control
5085 #define WC_COMBOBOXA "ComboBox"
5086 #if defined(__GNUC__)
5087 # define WC_COMBOBOXW (const WCHAR []){ 'C','o','m','b','o','B','o','x',0 }
5088 #elif defined(_MSC_VER)
5089 # define WC_COMBOBOXW L"ComboBox"
5090 #else
5091 static const WCHAR WC_COMBOBOXW[] = { 'C','o','m','b','o','B','o','x',0 };
5092 #endif
5093 #define WC_COMBOBOX WINELIB_NAME_AW(WC_COMBOBOX)
5095 /**************************************************************************
5096 * Edit control
5099 #define WC_EDITA "Edit"
5100 #if defined(__GNUC__)
5101 # define WC_EDITW (const WCHAR []){ 'E','d','i','t',0 }
5102 #elif defined(_MSC_VER)
5103 # define WC_EDITW L"Edit"
5104 #else
5105 static const WCHAR WC_EDITW[] = { 'E','d','i','t',0 };
5106 #endif
5107 #define WC_EDIT WINELIB_NAME_AW(WC_EDIT)
5109 /**************************************************************************
5110 * List box control
5113 #define WC_LISTBOXA "ListBox"
5114 #if defined(__GNUC__)
5115 # define WC_LISTBOXW (const WCHAR []){ 'L','i','s','t','B','o','x',0 }
5116 #elif defined(_MSC_VER)
5117 # define WC_LISTBOXW L"ListBox"
5118 #else
5119 static const WCHAR WC_LISTBOXW[] = { 'L','i','s','t','B','o','x',0 };
5120 #endif
5121 #define WC_LISTBOX WINELIB_NAME_AW(WC_LISTBOX)
5123 /**************************************************************************
5124 * Scroll bar control
5127 #define WC_SCROLLBARA "ScrollBar"
5128 #if defined(__GNUC__)
5129 # define WC_SCROLLBARW (const WCHAR []){ 'S','c','r','o','l','l','B','a','r',0 }
5130 #elif defined(_MSC_VER)
5131 # define WC_SCROLLBARW L"ScrollBar"
5132 #else
5133 static const WCHAR WC_SCROLLBARW[] = { 'S','c','r','o','l','l','B','a','r',0 };
5134 #endif
5135 #define WC_SCROLLBAR WINELIB_NAME_AW(WC_SCROLLBAR)
5137 #ifdef __cplusplus
5139 #endif
5141 #endif /* __WINE_COMMCTRL_H */