eliminate GCC warning about initialization order
[reactos.git] / reactos / include / wine / commctrl.h
1 /*
2 * Compatibility header
3 *
4 * This header is wrapper to allow compilation of Wine DLLs under ReactOS
5 * build system. It contains definitions commonly refered to as Wineisms
6 * and definitions that are missing in w32api.
7 */
8
9 #include_next <commctrl.h>
10
11 #ifndef __WINE_COMMCTRL_H
12 #define __WINE_COMMCTRL_H
13
14 typedef LPFINDINFOA LPLVFINDINFOA;
15 typedef LPFINDINFOW LPLVFINDINFOW;
16
17 #undef RB_GETBANDINFO
18 #define RB_GETBANDINFO (WM_USER+5) /* just for compatibility */
19
20 #define LVIS_ACTIVATING 0x0020
21
22 #define ListView_FindItemA(hwnd,nItem,plvfi) \
23 (INT)SendMessageA((hwnd),LVM_FINDITEMA,(WPARAM)(INT)(nItem),(LPARAM)(LVFINDINFOA*)(plvfi))
24 #define ListView_FindItemW(hwnd,nItem,plvfi) \
25 (INT)SendMessageW((hwnd),LVM_FINDITEMW,(WPARAM)(INT)(nItem),(LPARAM)(LVFINDINFOW*)(plvfi))
26 #define ListView_InsertColumnA(hwnd,iCol,pcol) \
27 (INT)SendMessageA((hwnd),LVM_INSERTCOLUMNA,(WPARAM)(INT)(iCol),(LPARAM)(const LVCOLUMNA *)(pcol))
28 #define ListView_GetItemA(hwnd,pitem) \
29 (BOOL)SendMessageA((hwnd),LVM_GETITEMA,0,(LPARAM)(LVITEMA *)(pitem))
30 #define ListView_SetItemA(hwnd,pitem) \
31 (INT)SendMessageA((hwnd),LVM_SETITEMA,0,(LPARAM)(const LVITEMA *)(pitem))
32 #define ListView_InsertItemA(hwnd,pitem) \
33 (INT)SendMessageA((hwnd),LVM_INSERTITEMA,0,(LPARAM)(const LVITEMA *)(pitem))
34 #define ListView_EditLabelA(hwndLV, i) \
35 (HWND)SendMessageA((hwndLV),LVM_EDITLABELA,(WPARAM)(int)(i), 0L)
36 #define TreeView_InsertItemW(hwnd,phdi) \
37 (HTREEITEM)SendMessageW((hwnd), TVM_INSERTITEMW, 0, (LPARAM)(LPTVINSERTSTRUCTW)(phdi))
38 #define Header_SetItemW(hwndHD,i,phdi) \
39 (BOOL)SendMessageW((hwndHD),HDM_SETITEMW,(WPARAM)(INT)(i),(LPARAM)(const HDITEMW*)(phdi))
40 #define Header_GetItemW(hwndHD,i,phdi) \
41 (BOOL)SendMessageW((hwndHD),HDM_GETITEMW,(WPARAM)(INT)(i),(LPARAM)(HDITEMW*)(phdi))
42
43 #define TBSTYLE_EX_UNDOC1 0x00000004 /* similar to TBSTYLE_WRAPABLE */
44
45 /* undocumented messages in Toolbar */
46 #define TB_UNKWN45D (WM_USER+93)
47 #define TB_UNKWN45E (WM_USER+94)
48 #define TB_UNKWN460 (WM_USER+96)
49 #define TB_UNKWN462 (WM_USER+98)
50 #define TB_UNKWN463 (WM_USER+99)
51 #define TB_UNKWN464 (WM_USER+100)
52
53 #define TBN_WRAPHOTITEM (TBN_FIRST-24) /* this is undocumented and the name is a guess */
54
55 #define RBBS_USECHEVRON 0x00000200
56 #define RBHT_CHEVRON 0x0008
57 #define RBN_CHEVRONPUSHED (RBN_FIRST-10)
58 #define RB_PUSHCHEVRON (WM_USER+43)
59
60 #define HDM_SETBITMAPMARGIN (HDM_FIRST+20)
61 #define HDM_GETBITMAPMARGIN (HDM_FIRST+21)
62
63 #define SB_SETBORDERS (WM_USER+5)
64
65 #define FLATSB_CLASSA "flatsb_class32"
66 #if defined(__GNUC__)
67 # define FLATSB_CLASSW (const WCHAR []){ 'f','l','a','t','s','b','_', \
68 'c','l','a','s','s','3','2',0 }
69 #elif defined(_MSC_VER)
70 # define FLATSB_CLASSW L"flatsb_class32"
71 #else
72 static const WCHAR FLATSB_CLASSW[] = { 'f','l','a','t','s','b','_',
73 'c','l','a','s','s','3','2',0 };
74 #endif
75
76 #define DRAGLISTMSGSTRINGA "commctrl_DragListMsg"
77 #if defined(__GNUC__)
78 # define DRAGLISTMSGSTRINGW (const WCHAR []){ 'c','o','m','m','c','t','r','l', \
79 '_','D','r','a','g','L','i','s','t','M','s','g',0 }
80 #elif defined(_MSC_VER)
81 # define DRAGLISTMSGSTRINGW L"commctrl_DragListMsg"
82 #else
83 static const WCHAR DRAGLISTMSGSTRINGW[] = { 'c','o','m','m','c','t','r','l', \
84 '_','D','r','a','g','L','i','s','t','M','s','g',0 };
85 #endif
86
87 /* these are undocumented and the names are guesses */
88 typedef struct
89 {
90 NMHDR hdr;
91 HWND hwndDialog;
92 } NMTBINITCUSTOMIZE;
93
94 typedef struct
95 {
96 NMHDR hdr;
97 INT idNew;
98 INT iDirection; /* left is -1, right is 1 */
99 DWORD dwReason; /* HICF_* */
100 } NMTBWRAPHOTITEM;
101
102 #endif /* __WINE_COMMCTRL_H */