1 /** 2 * This file has no copyright assigned and is placed in the Public Domain. 3 * This file is part of the w64 mingw-runtime package. 4 * No warranty is given; refer to the file DISCLAIMER.PD within this package. 5 */ 6 7 #ifndef _INC_COMMCTRL 8 #define _INC_COMMCTRL 9 10 #include <_mingw_unicode.h> 11 12 #ifndef _WINRESRC_ 13 #ifndef _WIN32_IE 14 #define _WIN32_IE 0x0501 15 #else 16 /* FIXME: This really must be 0x0501 !!! */ 17 #if (_WIN32_IE < 0x0500) 18 #error _WIN32_IE setting conflicts 19 #endif 20 #endif /* !_WIN32_IE */ 21 #endif /* !_WINRESRC_ */ 22 23 #ifndef _HRESULT_DEFINED 24 #define _HRESULT_DEFINED 25 typedef _Return_type_success_(return >= 0) LONG HRESULT; 26 #endif 27 28 #ifndef NOUSER 29 30 #ifndef WINCOMMCTRLAPI 31 #ifndef _COMCTL32_ 32 #define WINCOMMCTRLAPI DECLSPEC_IMPORT 33 #else 34 #define WINCOMMCTRLAPI 35 #endif 36 #endif /* !WINCOMMCTRLAPI */ 37 38 #ifdef __cplusplus 39 extern "C" { 40 #endif 41 42 #include <prsht.h> 43 44 #ifndef SNDMSG 45 #ifdef __cplusplus 46 #define SNDMSG ::SendMessage 47 #else 48 #define SNDMSG SendMessage 49 #endif 50 #endif /* !SNDMSG */ 51 52 WINCOMMCTRLAPI void WINAPI InitCommonControls(void); 53 54 typedef struct tagINITCOMMONCONTROLSEX { 55 DWORD dwSize; 56 DWORD dwICC; 57 } INITCOMMONCONTROLSEX,*LPINITCOMMONCONTROLSEX; 58 #define ICC_LISTVIEW_CLASSES 0x1 59 #define ICC_TREEVIEW_CLASSES 0x2 60 #define ICC_BAR_CLASSES 0x4 61 #define ICC_TAB_CLASSES 0x8 62 #define ICC_UPDOWN_CLASS 0x10 63 #define ICC_PROGRESS_CLASS 0x20 64 #define ICC_HOTKEY_CLASS 0x40 65 #define ICC_ANIMATE_CLASS 0x80 66 #define ICC_WIN95_CLASSES 0xff 67 #define ICC_DATE_CLASSES 0x100 68 #define ICC_USEREX_CLASSES 0x200 69 #define ICC_COOL_CLASSES 0x400 70 #define ICC_INTERNET_CLASSES 0x800 71 #define ICC_PAGESCROLLER_CLASS 0x1000 72 #define ICC_NATIVEFNTCTL_CLASS 0x2000 73 #define ICC_STANDARD_CLASSES 0x4000 74 #define ICC_LINK_CLASS 0x8000 75 76 WINCOMMCTRLAPI BOOL WINAPI InitCommonControlsEx(_In_ const INITCOMMONCONTROLSEX *); 77 78 #define ODT_HEADER 100 79 #define ODT_TAB 101 80 #define ODT_LISTVIEW 102 81 82 #define LVM_FIRST 0x1000 83 #define TV_FIRST 0x1100 84 #define HDM_FIRST 0x1200 85 #define TCM_FIRST 0x1300 86 87 #define PGM_FIRST 0x1400 88 #define ECM_FIRST 0x1500 89 #define BCM_FIRST 0x1600 90 #define CBM_FIRST 0x1700 91 #define CCM_FIRST 0x2000 92 #define CCM_LAST (CCM_FIRST+0x200) 93 #define CCM_SETBKCOLOR (CCM_FIRST+1) 94 #define CCM_SETCOLORSCHEME (CCM_FIRST+2) 95 #define CCM_GETCOLORSCHEME (CCM_FIRST+3) 96 #define CCM_GETDROPTARGET (CCM_FIRST+4) 97 #define CCM_SETUNICODEFORMAT (CCM_FIRST+5) 98 #define CCM_GETUNICODEFORMAT (CCM_FIRST+6) 99 100 typedef struct tagCOLORSCHEME { 101 DWORD dwSize; 102 COLORREF clrBtnHighlight; 103 COLORREF clrBtnShadow; 104 } COLORSCHEME,*LPCOLORSCHEME; 105 106 #if (_WIN32_IE >= 0x0500) 107 108 #if (_WIN32_WINNT >= 0x0501) 109 #define COMCTL32_VERSION 6 110 #else 111 #define COMCTL32_VERSION 5 112 #endif 113 114 #define CCM_SETVERSION (CCM_FIRST+0x7) 115 #define CCM_GETVERSION (CCM_FIRST+0x8) 116 #define CCM_SETNOTIFYWINDOW (CCM_FIRST+0x9) 117 #if (_WIN32_WINNT >= 0x0501) 118 #define CCM_SETWINDOWTHEME (CCM_FIRST+0xb) 119 #define CCM_DPISCALE (CCM_FIRST+0xc) 120 #endif 121 122 #endif /* _WIN32_IE >= 0x0500 */ 123 124 #define INFOTIPSIZE 1024 125 126 #define HANDLE_WM_NOTIFY(hwnd,wParam,lParam,fn) (fn)((hwnd),(int)(wParam),(NMHDR *)(lParam)) 127 #define FORWARD_WM_NOTIFY(hwnd,idFrom,pnmhdr,fn) (LRESULT)(fn)((hwnd),WM_NOTIFY,(WPARAM)(int)(idFrom),(LPARAM)(NMHDR *)(pnmhdr)) 128 129 #define NM_OUTOFMEMORY (NM_FIRST-1) 130 #define NM_CLICK (NM_FIRST-2) 131 #define NM_DBLCLK (NM_FIRST-3) 132 #define NM_RETURN (NM_FIRST-4) 133 #define NM_RCLICK (NM_FIRST-5) 134 #define NM_RDBLCLK (NM_FIRST-6) 135 #define NM_SETFOCUS (NM_FIRST-7) 136 #define NM_KILLFOCUS (NM_FIRST-8) 137 #define NM_CUSTOMDRAW (NM_FIRST-12) 138 #define NM_HOVER (NM_FIRST-13) 139 #define NM_NCHITTEST (NM_FIRST-14) 140 #define NM_KEYDOWN (NM_FIRST-15) 141 #define NM_RELEASEDCAPTURE (NM_FIRST-16) 142 #define NM_SETCURSOR (NM_FIRST-17) 143 #define NM_CHAR (NM_FIRST-18) 144 #define NM_TOOLTIPSCREATED (NM_FIRST-19) 145 #define NM_LDOWN (NM_FIRST-20) 146 #define NM_RDOWN (NM_FIRST-21) 147 #define NM_THEMECHANGED (NM_FIRST-22) 148 149 #ifndef CCSIZEOF_STRUCT 150 #if defined(__clang__) /* Clang-CL fails without this workaround. See CORE-17547 */ 151 #define CCSIZEOF_STRUCT(structname,member) (__builtin_offsetof(structname,member) + sizeof(((structname*)0)->member)) 152 #else 153 #define CCSIZEOF_STRUCT(structname,member) (((int)((LPBYTE)(&((structname*)0)->member) - ((LPBYTE)((structname*)0))))+sizeof(((structname*)0)->member)) 154 #endif 155 #endif 156 157 typedef struct tagNMTOOLTIPSCREATED { 158 NMHDR hdr; 159 HWND hwndToolTips; 160 } NMTOOLTIPSCREATED,*LPNMTOOLTIPSCREATED; 161 162 typedef struct tagNMMOUSE { 163 NMHDR hdr; 164 DWORD_PTR dwItemSpec; 165 DWORD_PTR dwItemData; 166 POINT pt; 167 LPARAM dwHitInfo; 168 } NMMOUSE,*LPNMMOUSE; 169 170 typedef NMMOUSE NMCLICK; 171 typedef LPNMMOUSE LPNMCLICK; 172 173 typedef struct tagNMOBJECTNOTIFY { 174 NMHDR hdr; 175 int iItem; 176 #ifdef __IID_DEFINED__ 177 const IID *piid; 178 #else 179 const void *piid; 180 #endif 181 void *pObject; 182 HRESULT hResult; 183 DWORD dwFlags; 184 } NMOBJECTNOTIFY,*LPNMOBJECTNOTIFY; 185 186 typedef struct tagNMKEY { 187 NMHDR hdr; 188 UINT nVKey; 189 UINT uFlags; 190 } NMKEY,*LPNMKEY; 191 192 typedef struct tagNMCHAR { 193 NMHDR hdr; 194 UINT ch; 195 DWORD dwItemPrev; 196 DWORD dwItemNext; 197 } NMCHAR,*LPNMCHAR; 198 199 #define NM_FIRST (0U- 0U) 200 #define NM_LAST (0U- 99U) 201 202 #define LVN_FIRST (0U-100U) 203 #define LVN_LAST (0U-199U) 204 205 #define HDN_FIRST (0U-300U) 206 #define HDN_LAST (0U-399U) 207 208 #define TVN_FIRST (0U-400U) 209 #define TVN_LAST (0U-499U) 210 211 #define TTN_FIRST (0U-520U) 212 #define TTN_LAST (0U-549U) 213 214 #define TCN_FIRST (0U-550U) 215 #define TCN_LAST (0U-580U) 216 217 #ifndef CDN_FIRST 218 #define CDN_FIRST (0U-601U) 219 #define CDN_LAST (0U-699U) 220 #endif 221 222 #define TBN_FIRST (0U-700U) 223 #define TBN_LAST (0U-720U) 224 225 #define UDN_FIRST (0U-721U) 226 #define UDN_LAST (0U-740U) 227 228 #define MCN_FIRST (0U-750U) 229 #define MCN_LAST (0U-759U) 230 #define DTN_FIRST (0U-760U) 231 #define DTN_LAST (0U-799U) 232 #define CBEN_FIRST (0U-800U) 233 #define CBEN_LAST (0U-830U) 234 #define RBN_FIRST (0U-831U) 235 #define RBN_LAST (0U-859U) 236 237 #define IPN_FIRST (0U-860U) 238 #define IPN_LAST (0U-879U) 239 #define SBN_FIRST (0U-880U) 240 #define SBN_LAST (0U-899U) 241 #define PGN_FIRST (0U-900U) 242 #define PGN_LAST (0U-950U) 243 244 #ifndef WMN_FIRST 245 #define WMN_FIRST (0U-1000U) 246 #define WMN_LAST (0U-1200U) 247 #endif 248 249 #define BCSIF_GLYPH 0x00000001 250 #define BCSIF_IMAGE 0x00000002 251 #define BCSIF_STYLE 0x00000004 252 #define BCSIF_SIZE 0x00000008 253 254 #define BCSS_STRETCH 0x00000002 255 #define BCSS_IMAGE 0x00000008 256 257 #define BCN_FIRST (0U-1250U) 258 #define BCN_LAST (0U-1350U) 259 260 #define BCN_HOTITEMCHANGE (BCN_FIRST + 1) 261 #define BCN_DROPDOWN (BCN_FIRST + 2) 262 263 #define MSGF_COMMCTRL_BEGINDRAG 0x4200 264 #define MSGF_COMMCTRL_SIZEHEADER 0x4201 265 #define MSGF_COMMCTRL_DRAGSELECT 0x4202 266 #define MSGF_COMMCTRL_TOOLBARCUST 0x4203 267 268 #define CDRF_DODEFAULT 0x0 269 #define CDRF_NEWFONT 0x2 270 #define CDRF_SKIPDEFAULT 0x4 271 #define CDRF_DOERASE 0x8 272 #define CDRF_SKIPPOSTPAINT 0x100 273 274 #define CDRF_NOTIFYPOSTPAINT 0x10 275 #define CDRF_NOTIFYITEMDRAW 0x20 276 #define CDRF_NOTIFYSUBITEMDRAW 0x20 277 #define CDRF_NOTIFYPOSTERASE 0x40 278 #define CDRF_NOTIFYITEMERASE 0x00000080 /* obsolete ??? */ 279 280 #define CDDS_PREPAINT 0x1 281 #define CDDS_POSTPAINT 0x2 282 #define CDDS_PREERASE 0x3 283 #define CDDS_POSTERASE 0x4 284 #define CDDS_ITEM 0x10000 285 #define CDDS_ITEMPREPAINT (CDDS_ITEM | CDDS_PREPAINT) 286 #define CDDS_ITEMPOSTPAINT (CDDS_ITEM | CDDS_POSTPAINT) 287 #define CDDS_ITEMPREERASE (CDDS_ITEM | CDDS_PREERASE) 288 #define CDDS_ITEMPOSTERASE (CDDS_ITEM | CDDS_POSTERASE) 289 #define CDDS_SUBITEM 0x20000 290 291 #define CDIS_SELECTED 0x1 292 #define CDIS_GRAYED 0x2 293 #define CDIS_DISABLED 0x4 294 #define CDIS_CHECKED 0x8 295 #define CDIS_FOCUS 0x10 296 #define CDIS_DEFAULT 0x20 297 #define CDIS_HOT 0x40 298 #define CDIS_MARKED 0x80 299 #define CDIS_INDETERMINATE 0x100 300 #define CDIS_SHOWKEYBOARDCUES 0x200 301 302 typedef struct tagNMCUSTOMDRAWINFO { 303 NMHDR hdr; 304 DWORD dwDrawStage; 305 HDC hdc; 306 RECT rc; 307 DWORD_PTR dwItemSpec; 308 UINT uItemState; 309 LPARAM lItemlParam; 310 } NMCUSTOMDRAW,*LPNMCUSTOMDRAW; 311 312 typedef struct tagNMTTCUSTOMDRAW { 313 NMCUSTOMDRAW nmcd; 314 UINT uDrawFlags; 315 } NMTTCUSTOMDRAW,*LPNMTTCUSTOMDRAW; 316 317 #ifndef NOIMAGEAPIS 318 319 #define CLR_NONE 0xffffffffL 320 #define CLR_DEFAULT 0xFF000000L 321 322 #ifndef HIMAGELIST 323 struct _IMAGELIST; 324 typedef struct _IMAGELIST *HIMAGELIST; 325 #endif 326 327 #ifndef IMAGELISTDRAWPARAMS 328 typedef struct _IMAGELISTDRAWPARAMS { 329 DWORD cbSize; 330 HIMAGELIST himl; 331 int i; 332 HDC hdcDst; 333 int x; 334 int y; 335 int cx; 336 int cy; 337 int xBitmap; 338 int yBitmap; 339 COLORREF rgbBk; 340 COLORREF rgbFg; 341 UINT fStyle; 342 DWORD dwRop; 343 DWORD fState; 344 DWORD Frame; 345 COLORREF crEffect; 346 } IMAGELISTDRAWPARAMS,*LPIMAGELISTDRAWPARAMS; 347 348 #define IMAGELISTDRAWPARAMS_V3_SIZE CCSIZEOF_STRUCT(IMAGELISTDRAWPARAMS,dwRop) 349 #endif 350 351 #define ILC_MASK 0x1 352 #define ILC_COLOR 0x0 353 #define ILC_COLORDDB 0xfe 354 #define ILC_COLOR4 0x4 355 #define ILC_COLOR8 0x8 356 #define ILC_COLOR16 0x10 357 #define ILC_COLOR24 0x18 358 #define ILC_COLOR32 0x20 359 #define ILC_PALETTE 0x800 360 #define ILC_MIRROR 0x2000 361 #define ILC_PERITEMMIRROR 0x8000 362 363 WINCOMMCTRLAPI HIMAGELIST WINAPI ImageList_Create(int cx,int cy,UINT flags,int cInitial,int cGrow); 364 WINCOMMCTRLAPI BOOL WINAPI ImageList_Destroy(_In_opt_ HIMAGELIST himl); 365 WINCOMMCTRLAPI int WINAPI ImageList_GetImageCount(_In_ HIMAGELIST himl); 366 367 WINCOMMCTRLAPI 368 BOOL 369 WINAPI 370 ImageList_SetImageCount( 371 _In_ HIMAGELIST himl, 372 _In_ UINT uNewCount); 373 374 WINCOMMCTRLAPI 375 int 376 WINAPI 377 ImageList_Add( 378 _In_ HIMAGELIST himl, 379 _In_ HBITMAP hbmImage, 380 _In_opt_ HBITMAP hbmMask); 381 382 WINCOMMCTRLAPI 383 int 384 WINAPI 385 ImageList_ReplaceIcon( 386 _In_ HIMAGELIST himl, 387 _In_ int i, 388 _In_ HICON hicon); 389 390 WINCOMMCTRLAPI 391 COLORREF 392 WINAPI 393 ImageList_SetBkColor( 394 _In_ HIMAGELIST himl, 395 _In_ COLORREF clrBk); 396 397 WINCOMMCTRLAPI COLORREF WINAPI ImageList_GetBkColor(_In_ HIMAGELIST himl); 398 399 WINCOMMCTRLAPI 400 BOOL 401 WINAPI 402 ImageList_SetOverlayImage( 403 _In_ HIMAGELIST himl, 404 _In_ int iImage, 405 _In_ int iOverlay); 406 407 WINCOMMCTRLAPI 408 HRESULT 409 WINAPI 410 HIMAGELIST_QueryInterface( 411 _In_ HIMAGELIST, 412 _In_ REFIID, 413 _Outptr_ void **); 414 415 #define ImageList_AddIcon(himl,hicon) ImageList_ReplaceIcon(himl,-1,hicon) 416 417 #define ILD_NORMAL 0x0 418 #define ILD_TRANSPARENT 0x1 419 #define ILD_MASK 0x10 420 #define ILD_IMAGE 0x20 421 #define ILD_ROP 0x40 422 #define ILD_BLEND25 0x2 423 #define ILD_BLEND50 0x4 424 #define ILD_OVERLAYMASK 0xf00 425 #define INDEXTOOVERLAYMASK(i) ((i) << 8) 426 #define ILD_PRESERVEALPHA 0x1000 427 #define ILD_SCALE 0x2000 428 #define ILD_DPISCALE 0x4000 429 430 #define ILD_SELECTED ILD_BLEND50 431 #define ILD_FOCUS ILD_BLEND25 432 #define ILD_BLEND ILD_BLEND50 433 #define CLR_HILIGHT CLR_DEFAULT 434 435 #define ILS_NORMAL 0x0 436 #define ILS_GLOW 0x1 437 #define ILS_SHADOW 0x2 438 #define ILS_SATURATE 0x4 439 #define ILS_ALPHA 0x8 440 441 WINCOMMCTRLAPI 442 BOOL 443 WINAPI 444 ImageList_Draw( 445 _In_ HIMAGELIST himl, 446 _In_ int i, 447 _In_ HDC hdcDst, 448 _In_ int x, 449 _In_ int y, 450 _In_ UINT fStyle); 451 452 WINCOMMCTRLAPI 453 BOOL 454 WINAPI 455 ImageList_Replace( 456 _In_ HIMAGELIST himl, 457 _In_ int i, 458 _In_ HBITMAP hbmImage, 459 _In_opt_ HBITMAP hbmMask); 460 461 WINCOMMCTRLAPI 462 int 463 WINAPI 464 ImageList_AddMasked( 465 _In_ HIMAGELIST himl, 466 _In_ HBITMAP hbmImage, 467 _In_ COLORREF crMask); 468 469 WINCOMMCTRLAPI 470 BOOL 471 WINAPI 472 ImageList_DrawEx( 473 _In_ HIMAGELIST himl, 474 _In_ int i, 475 _In_ HDC hdcDst, 476 _In_ int x, 477 _In_ int y, 478 _In_ int dx, 479 _In_ int dy, 480 _In_ COLORREF rgbBk, 481 _In_ COLORREF rgbFg, 482 _In_ UINT fStyle); 483 484 WINCOMMCTRLAPI 485 BOOL 486 WINAPI 487 ImageList_DrawIndirect( 488 _In_ IMAGELISTDRAWPARAMS *pimldp); 489 490 WINCOMMCTRLAPI 491 BOOL 492 WINAPI 493 ImageList_Remove( 494 _In_ HIMAGELIST himl, 495 _In_ int i); 496 497 WINCOMMCTRLAPI 498 HICON 499 WINAPI 500 ImageList_GetIcon( 501 _In_ HIMAGELIST himl, 502 _In_ int i, 503 _In_ UINT flags); 504 505 WINCOMMCTRLAPI HIMAGELIST WINAPI ImageList_LoadImageA(HINSTANCE hi,LPCSTR lpbmp,int cx,int cGrow,COLORREF crMask,UINT uType,UINT uFlags); 506 WINCOMMCTRLAPI HIMAGELIST WINAPI ImageList_LoadImageW(HINSTANCE hi,LPCWSTR lpbmp,int cx,int cGrow,COLORREF crMask,UINT uType,UINT uFlags); 507 508 #define ImageList_LoadImage __MINGW_NAME_AW(ImageList_LoadImage) 509 510 #define ILCF_MOVE 0x0 511 #define ILCF_SWAP 0x1 512 513 WINCOMMCTRLAPI 514 BOOL 515 WINAPI 516 ImageList_Copy( 517 _In_ HIMAGELIST himlDst, 518 _In_ int iDst, 519 _In_ HIMAGELIST himlSrc, 520 _In_ int iSrc, 521 _In_ UINT uFlags); 522 523 WINCOMMCTRLAPI 524 BOOL 525 WINAPI 526 ImageList_BeginDrag( 527 _In_ HIMAGELIST himlTrack, 528 _In_ int iTrack, 529 _In_ int dxHotspot, 530 _In_ int dyHotspot); 531 532 WINCOMMCTRLAPI void WINAPI ImageList_EndDrag(void); 533 WINCOMMCTRLAPI BOOL WINAPI ImageList_DragEnter(HWND hwndLock,int x,int y); 534 WINCOMMCTRLAPI BOOL WINAPI ImageList_DragLeave(HWND hwndLock); 535 WINCOMMCTRLAPI BOOL WINAPI ImageList_DragMove(int x,int y); 536 537 WINCOMMCTRLAPI 538 BOOL 539 WINAPI 540 ImageList_SetDragCursorImage( 541 _In_ HIMAGELIST himlDrag, 542 _In_ int iDrag, 543 _In_ int dxHotspot, 544 _In_ int dyHotspot); 545 546 WINCOMMCTRLAPI BOOL WINAPI ImageList_DragShowNolock(BOOL fShow); 547 548 _Success_(return != NULL) 549 WINCOMMCTRLAPI 550 HIMAGELIST 551 WINAPI 552 ImageList_GetDragImage( 553 _Out_opt_ POINT *ppt, 554 _Out_opt_ POINT *pptHotspot); 555 556 #define ImageList_RemoveAll(himl) ImageList_Remove(himl,-1) 557 #define ImageList_ExtractIcon(hi,himl,i) ImageList_GetIcon(himl,i,0) 558 #define ImageList_LoadBitmap(hi,lpbmp,cx,cGrow,crMask) ImageList_LoadImage(hi,lpbmp,cx,cGrow,crMask,IMAGE_BITMAP,0) 559 560 #ifdef __IStream_INTERFACE_DEFINED__ 561 WINCOMMCTRLAPI HIMAGELIST WINAPI ImageList_Read(_In_ LPSTREAM pstm); 562 WINCOMMCTRLAPI BOOL WINAPI ImageList_Write(_In_ HIMAGELIST himl, _In_ LPSTREAM pstm); 563 #define ILP_NORMAL 0 564 #define ILP_DOWNLEVEL 1 565 WINCOMMCTRLAPI HRESULT WINAPI ImageList_ReadEx(_In_ DWORD dwFlags, _In_ LPSTREAM pstm, _In_ REFIID riid, _Outptr_ PVOID *ppv); 566 WINCOMMCTRLAPI HRESULT WINAPI ImageList_WriteEx(_In_ HIMAGELIST himl, _In_ DWORD dwFlags, _In_ LPSTREAM pstm); 567 #endif 568 569 #ifndef IMAGEINFO 570 typedef struct _IMAGEINFO { 571 HBITMAP hbmImage; 572 HBITMAP hbmMask; 573 int Unused1; 574 int Unused2; 575 RECT rcImage; 576 } IMAGEINFO,*LPIMAGEINFO; 577 #endif 578 579 _Success_(return != 0) 580 WINCOMMCTRLAPI 581 BOOL 582 WINAPI 583 ImageList_GetIconSize( 584 _In_ HIMAGELIST himl, 585 _Out_opt_ int *cx, 586 _Out_opt_ int *cy); 587 588 _Success_(return != 0) 589 WINCOMMCTRLAPI 590 BOOL 591 WINAPI 592 ImageList_SetIconSize( 593 _In_ HIMAGELIST himl, 594 _In_ int cx, 595 _In_ int cy); 596 597 _Success_(return != 0) 598 WINCOMMCTRLAPI 599 BOOL 600 WINAPI 601 ImageList_GetImageInfo( 602 _In_ HIMAGELIST himl, 603 _In_ int i, 604 _Out_ IMAGEINFO *pImageInfo); 605 606 WINCOMMCTRLAPI 607 HIMAGELIST 608 WINAPI 609 ImageList_Merge( 610 _In_ HIMAGELIST himl1, 611 _In_ int i1, 612 _In_ HIMAGELIST himl2, 613 _In_ int i2, 614 _In_ int dx, 615 _In_ int dy); 616 617 WINCOMMCTRLAPI HIMAGELIST WINAPI ImageList_Duplicate(_In_ HIMAGELIST himl); 618 619 #endif /* !NOIMAGEAPIS */ 620 621 #ifndef NOHEADER 622 623 #define WC_HEADERA "SysHeader32" 624 #define WC_HEADERW L"SysHeader32" 625 626 #define WC_HEADER __MINGW_NAME_AW(WC_HEADER) 627 628 #define HDS_HORZ 0x0 629 #define HDS_BUTTONS 0x2 630 #define HDS_HOTTRACK 0x4 631 #define HDS_HIDDEN 0x8 632 #define HDS_DRAGDROP 0x40 633 #define HDS_FULLDRAG 0x80 634 #define HDS_FILTERBAR 0x100 635 #define HDS_FLAT 0x200 636 #if (_WIN32_WINNT >= 0x0600) 637 #define HDS_CHECKBOXES 0x400 638 #define HDS_NOSIZING 0x800 639 #define HDS_OVERFLOW 0x1000 640 #endif 641 642 #define HDFT_ISSTRING 0x0 643 #define HDFT_ISNUMBER 0x1 644 645 #define HDFT_HASNOVALUE 0x8000 646 647 #define HD_TEXTFILTER __MINGW_NAME_AW(HD_TEXTFILTER) 648 #define HDTEXTFILTER __MINGW_NAME_AW(HD_TEXTFILTER) 649 #define LPHD_TEXTFILTER __MINGW_NAME_AW(LPHD_TEXTFILTER) 650 #define LPHDTEXTFILTER __MINGW_NAME_AW(LPHD_TEXTFILTER) 651 652 typedef struct _HD_TEXTFILTERA { 653 LPSTR pszText; 654 INT cchTextMax; 655 } HD_TEXTFILTERA,*LPHD_TEXTFILTERA; 656 657 typedef struct _HD_TEXTFILTERW { 658 LPWSTR pszText; 659 INT cchTextMax; 660 } HD_TEXTFILTERW,*LPHD_TEXTFILTERW; 661 662 #define HD_ITEMA HDITEMA 663 #define HD_ITEMW HDITEMW 664 #define HD_ITEM HDITEM 665 666 typedef struct _HD_ITEMA { 667 UINT mask; 668 int cxy; 669 LPSTR pszText; 670 HBITMAP hbm; 671 int cchTextMax; 672 int fmt; 673 LPARAM lParam; 674 int iImage; 675 int iOrder; 676 UINT type; 677 void *pvFilter; 678 } HDITEMA,*LPHDITEMA; 679 680 #define HDITEMA_V1_SIZE CCSIZEOF_STRUCT(HDITEMA,lParam) 681 #define HDITEMW_V1_SIZE CCSIZEOF_STRUCT(HDITEMW,lParam) 682 683 typedef struct _HD_ITEMW { 684 UINT mask; 685 int cxy; 686 LPWSTR pszText; 687 HBITMAP hbm; 688 int cchTextMax; 689 int fmt; 690 LPARAM lParam; 691 int iImage; 692 int iOrder; 693 UINT type; 694 void *pvFilter; 695 } HDITEMW,*LPHDITEMW; 696 697 #define HDITEM __MINGW_NAME_AW(HDITEM) 698 #define LPHDITEM __MINGW_NAME_AW(LPHDITEM) 699 700 #define HDITEM_V1_SIZE __MINGW_NAME_AW_EXT(HDITEM,_V1_SIZE) 701 702 #define HDI_WIDTH 0x1 703 #define HDI_HEIGHT HDI_WIDTH 704 #define HDI_TEXT 0x2 705 #define HDI_FORMAT 0x4 706 #define HDI_LPARAM 0x8 707 #define HDI_BITMAP 0x10 708 #define HDI_IMAGE 0x20 709 #define HDI_DI_SETITEM 0x40 710 #define HDI_ORDER 0x80 711 #define HDI_FILTER 0x100 712 713 #define HDF_LEFT 0x0 714 #define HDF_RIGHT 0x1 715 #define HDF_CENTER 0x2 716 #define HDF_JUSTIFYMASK 0x3 717 #define HDF_RTLREADING 0x4 718 719 #define HDF_OWNERDRAW 0x8000 720 #define HDF_STRING 0x4000 721 #define HDF_BITMAP 0x2000 722 #define HDF_BITMAP_ON_RIGHT 0x1000 723 #define HDF_IMAGE 0x800 724 #define HDF_SORTUP 0x400 725 #define HDF_SORTDOWN 0x200 726 #if (_WIN32_WINNT >= 0x0600) 727 #define HDF_CHECKBOX 0x40 728 #define HDF_CHECKED 0x80 729 #define HDF_FIXEDWIDTH 0x100 730 #define HDF_SPLITBUTTON 0x1000000 731 #endif 732 733 #define HDM_GETITEMCOUNT (HDM_FIRST+0) 734 #define Header_GetItemCount(hwndHD) (int)SNDMSG((hwndHD),HDM_GETITEMCOUNT,0,0L) 735 736 #define HDM_INSERTITEMA (HDM_FIRST+1) 737 #define HDM_INSERTITEMW (HDM_FIRST+10) 738 739 #define HDM_INSERTITEM __MINGW_NAME_AW(HDM_INSERTITEM) 740 741 #define Header_InsertItem(hwndHD,i,phdi) (int)SNDMSG((hwndHD),HDM_INSERTITEM,(WPARAM)(int)(i),(LPARAM)(const HD_ITEM *)(phdi)) 742 743 #define HDM_DELETEITEM (HDM_FIRST+2) 744 #define Header_DeleteItem(hwndHD,i) (BOOL)SNDMSG((hwndHD),HDM_DELETEITEM,(WPARAM)(int)(i),0L) 745 746 #define HDM_GETITEMA (HDM_FIRST+3) 747 #define HDM_GETITEMW (HDM_FIRST+11) 748 749 #define HDM_GETITEM __MINGW_NAME_AW(HDM_GETITEM) 750 751 #define Header_GetItem(hwndHD,i,phdi) (BOOL)SNDMSG((hwndHD),HDM_GETITEM,(WPARAM)(int)(i),(LPARAM)(HD_ITEM *)(phdi)) 752 753 #define HDM_SETITEMA (HDM_FIRST+4) 754 #define HDM_SETITEMW (HDM_FIRST+12) 755 756 #define HDM_SETITEM __MINGW_NAME_AW(HDM_SETITEM) 757 758 #define Header_SetItem(hwndHD,i,phdi) (BOOL)SNDMSG((hwndHD),HDM_SETITEM,(WPARAM)(int)(i),(LPARAM)(const HD_ITEM *)(phdi)) 759 760 #define HD_LAYOUT HDLAYOUT 761 762 typedef struct _HD_LAYOUT { 763 RECT *prc; 764 WINDOWPOS *pwpos; 765 } HDLAYOUT,*LPHDLAYOUT; 766 767 #define HDM_LAYOUT (HDM_FIRST+5) 768 #define Header_Layout(hwndHD,playout) (BOOL)SNDMSG((hwndHD),HDM_LAYOUT,0,(LPARAM)(HD_LAYOUT *)(playout)) 769 770 #define HHT_NOWHERE 0x1 771 #define HHT_ONHEADER 0x2 772 #define HHT_ONDIVIDER 0x4 773 #define HHT_ONDIVOPEN 0x8 774 #define HHT_ONFILTER 0x10 775 #define HHT_ONFILTERBUTTON 0x20 776 #define HHT_ABOVE 0x100 777 #define HHT_BELOW 0x200 778 #define HHT_TORIGHT 0x400 779 #define HHT_TOLEFT 0x800 780 781 #define HD_HITTESTINFO HDHITTESTINFO 782 783 typedef struct _HD_HITTESTINFO { 784 POINT pt; 785 UINT flags; 786 int iItem; 787 } HDHITTESTINFO,*LPHDHITTESTINFO; 788 789 #define HDM_HITTEST (HDM_FIRST+6) 790 791 #define HDM_GETITEMRECT (HDM_FIRST+7) 792 #define Header_GetItemRect(hwnd,iItem,lprc) (BOOL)SNDMSG((hwnd),HDM_GETITEMRECT,(WPARAM)(iItem),(LPARAM)(lprc)) 793 794 #define HDM_SETIMAGELIST (HDM_FIRST+8) 795 #define Header_SetImageList(hwnd,himl) (HIMAGELIST)SNDMSG((hwnd),HDM_SETIMAGELIST,0,(LPARAM)(himl)) 796 797 #define HDM_GETIMAGELIST (HDM_FIRST+9) 798 #define Header_GetImageList(hwnd) (HIMAGELIST)SNDMSG((hwnd),HDM_GETIMAGELIST,0,0) 799 800 #define HDM_ORDERTOINDEX (HDM_FIRST+15) 801 #define Header_OrderToIndex(hwnd,i) (int)SNDMSG((hwnd),HDM_ORDERTOINDEX,(WPARAM)(i),0) 802 803 #define HDM_CREATEDRAGIMAGE (HDM_FIRST+16) 804 #define Header_CreateDragImage(hwnd,i) (HIMAGELIST)SNDMSG((hwnd),HDM_CREATEDRAGIMAGE,(WPARAM)(i),0) 805 806 #define HDM_GETORDERARRAY (HDM_FIRST+17) 807 #define Header_GetOrderArray(hwnd,iCount,lpi) (BOOL)SNDMSG((hwnd),HDM_GETORDERARRAY,(WPARAM)(iCount),(LPARAM)(lpi)) 808 809 #define HDM_SETORDERARRAY (HDM_FIRST+18) 810 #define Header_SetOrderArray(hwnd,iCount,lpi) (BOOL)SNDMSG((hwnd),HDM_SETORDERARRAY,(WPARAM)(iCount),(LPARAM)(lpi)) 811 812 #define HDM_SETHOTDIVIDER (HDM_FIRST+19) 813 #define Header_SetHotDivider(hwnd,fPos,dw) (int)SNDMSG((hwnd),HDM_SETHOTDIVIDER,(WPARAM)(fPos),(LPARAM)(dw)) 814 815 #define HDM_SETBITMAPMARGIN (HDM_FIRST+20) 816 #define Header_SetBitmapMargin(hwnd,iWidth) (int)SNDMSG((hwnd),HDM_SETBITMAPMARGIN,(WPARAM)(iWidth),0) 817 818 #define HDM_GETBITMAPMARGIN (HDM_FIRST+21) 819 #define Header_GetBitmapMargin(hwnd) (int)SNDMSG((hwnd),HDM_GETBITMAPMARGIN,0,0) 820 821 #define HDM_SETUNICODEFORMAT CCM_SETUNICODEFORMAT 822 #define Header_SetUnicodeFormat(hwnd,fUnicode) (BOOL)SNDMSG((hwnd),HDM_SETUNICODEFORMAT,(WPARAM)(fUnicode),0) 823 824 #define HDM_GETUNICODEFORMAT CCM_GETUNICODEFORMAT 825 #define Header_GetUnicodeFormat(hwnd) (BOOL)SNDMSG((hwnd),HDM_GETUNICODEFORMAT,0,0) 826 827 #define HDM_SETFILTERCHANGETIMEOUT (HDM_FIRST+22) 828 #define Header_SetFilterChangeTimeout(hwnd,i) (int)SNDMSG((hwnd),HDM_SETFILTERCHANGETIMEOUT,0,(LPARAM)(i)) 829 830 #define HDM_EDITFILTER (HDM_FIRST+23) 831 #define Header_EditFilter(hwnd,i,fDiscardChanges) (int)SNDMSG((hwnd),HDM_EDITFILTER,(WPARAM)(i),MAKELPARAM(fDiscardChanges,0)) 832 833 #define HDM_CLEARFILTER (HDM_FIRST+24) 834 #define Header_ClearFilter(hwnd,i) (int)SNDMSG((hwnd),HDM_CLEARFILTER,(WPARAM)(i),0) 835 #define Header_ClearAllFilters(hwnd) (int)SNDMSG((hwnd),HDM_CLEARFILTER,(WPARAM)-1,0) 836 837 #define HDN_ITEMCHANGINGA (HDN_FIRST-0) 838 #define HDN_ITEMCHANGINGW (HDN_FIRST-20) 839 #define HDN_ITEMCHANGEDA (HDN_FIRST-1) 840 #define HDN_ITEMCHANGEDW (HDN_FIRST-21) 841 #define HDN_ITEMCLICKA (HDN_FIRST-2) 842 #define HDN_ITEMCLICKW (HDN_FIRST-22) 843 #define HDN_ITEMDBLCLICKA (HDN_FIRST-3) 844 #define HDN_ITEMDBLCLICKW (HDN_FIRST-23) 845 #define HDN_DIVIDERDBLCLICKA (HDN_FIRST-5) 846 #define HDN_DIVIDERDBLCLICKW (HDN_FIRST-25) 847 #define HDN_BEGINTRACKA (HDN_FIRST-6) 848 #define HDN_BEGINTRACKW (HDN_FIRST-26) 849 #define HDN_ENDTRACKA (HDN_FIRST-7) 850 #define HDN_ENDTRACKW (HDN_FIRST-27) 851 #define HDN_TRACKA (HDN_FIRST-8) 852 #define HDN_TRACKW (HDN_FIRST-28) 853 #define HDN_GETDISPINFOA (HDN_FIRST-9) 854 #define HDN_GETDISPINFOW (HDN_FIRST-29) 855 #define HDN_BEGINDRAG (HDN_FIRST-10) 856 #define HDN_ENDDRAG (HDN_FIRST-11) 857 #define HDN_FILTERCHANGE (HDN_FIRST-12) 858 #define HDN_FILTERBTNCLICK (HDN_FIRST-13) 859 #define HDN_BEGINFILTEREDIT (HDN_FIRST-14) 860 #define HDN_ENDFILTEREDIT (HDN_FIRST-15) 861 #define HDN_ITEMSTATEICONCLICK (HDN_FIRST-16) 862 #define HDN_ITEMKEYDOWN (HDN_FIRST-17) 863 #define HDN_DROPDOWN (HDN_FIRST-18) 864 #define HDN_OVERFLOWCLICK (HDN_FIRST-19) 865 866 #define HDN_ITEMCHANGING __MINGW_NAME_AW(HDN_ITEMCHANGING) 867 #define HDN_ITEMCHANGED __MINGW_NAME_AW(HDN_ITEMCHANGED) 868 #define HDN_ITEMCLICK __MINGW_NAME_AW(HDN_ITEMCLICK) 869 #define HDN_ITEMDBLCLICK __MINGW_NAME_AW(HDN_ITEMDBLCLICK) 870 #define HDN_DIVIDERDBLCLICK __MINGW_NAME_AW(HDN_DIVIDERDBLCLICK) 871 #define HDN_BEGINTRACK __MINGW_NAME_AW(HDN_BEGINTRACK) 872 #define HDN_ENDTRACK __MINGW_NAME_AW(HDN_ENDTRACK) 873 #define HDN_TRACK __MINGW_NAME_AW(HDN_TRACK) 874 #define HDN_GETDISPINFO __MINGW_NAME_AW(HDN_GETDISPINFO) 875 876 #define HD_NOTIFYA NMHEADERA 877 #define HD_NOTIFYW NMHEADERW 878 #define HD_NOTIFY NMHEADER 879 880 typedef struct tagNMHEADERA { 881 NMHDR hdr; 882 int iItem; 883 int iButton; 884 HDITEMA *pitem; 885 } NMHEADERA,*LPNMHEADERA; 886 887 typedef struct tagNMHEADERW { 888 NMHDR hdr; 889 int iItem; 890 int iButton; 891 HDITEMW *pitem; 892 } NMHEADERW,*LPNMHEADERW; 893 894 #define NMHEADER __MINGW_NAME_AW(NMHEADER) 895 #define LPNMHEADER __MINGW_NAME_AW(LPNMHEADER) 896 897 typedef struct tagNMHDDISPINFOW { 898 NMHDR hdr; 899 int iItem; 900 UINT mask; 901 LPWSTR pszText; 902 int cchTextMax; 903 int iImage; 904 LPARAM lParam; 905 } NMHDDISPINFOW,*LPNMHDDISPINFOW; 906 907 typedef struct tagNMHDDISPINFOA { 908 NMHDR hdr; 909 int iItem; 910 UINT mask; 911 LPSTR pszText; 912 int cchTextMax; 913 int iImage; 914 LPARAM lParam; 915 } NMHDDISPINFOA,*LPNMHDDISPINFOA; 916 917 #define NMHDDISPINFO __MINGW_NAME_AW(NMHDDISPINFO) 918 #define LPNMHDDISPINFO __MINGW_NAME_AW(LPNMHDDISPINFO) 919 920 typedef struct tagNMHDFILTERBTNCLICK { 921 NMHDR hdr; 922 INT iItem; 923 RECT rc; 924 } NMHDFILTERBTNCLICK,*LPNMHDFILTERBTNCLICK; 925 926 #endif /* !NOHEADER */ 927 928 typedef struct tagBUTTON_SPLITINFO { 929 UINT mask; 930 HIMAGELIST himlGlyph; 931 UINT uSplitStyle; 932 SIZE size; 933 } BUTTON_SPLITINFO, *PBUTTON_SPLITINFO; 934 935 typedef struct tagNMBCDROPDOWN { 936 NMHDR hdr; 937 RECT rcButton; 938 } NMBCDROPDOWN; 939 940 941 #ifndef NOTOOLBAR 942 943 #define TOOLBARCLASSNAMEW L"ToolbarWindow32" 944 #define TOOLBARCLASSNAMEA "ToolbarWindow32" 945 946 #define TOOLBARCLASSNAME __MINGW_NAME_AW(TOOLBARCLASSNAME) 947 948 typedef struct _TBBUTTON { 949 int iBitmap; 950 int idCommand; 951 BYTE fsState; 952 BYTE fsStyle; 953 #ifdef _WIN64 954 BYTE bReserved[6]; 955 #else 956 BYTE bReserved[2]; 957 #endif 958 DWORD_PTR dwData; 959 INT_PTR iString; 960 } TBBUTTON,NEAR *PTBBUTTON,*LPTBBUTTON; 961 typedef const TBBUTTON *LPCTBBUTTON; 962 963 typedef struct _COLORMAP { 964 COLORREF from; 965 COLORREF to; 966 } COLORMAP,*LPCOLORMAP; 967 968 WINCOMMCTRLAPI HWND WINAPI CreateToolbarEx(HWND hwnd,DWORD ws,UINT wID,int nBitmaps,HINSTANCE hBMInst,UINT_PTR wBMID,LPCTBBUTTON lpButtons,int iNumButtons,int dxButton,int dyButton,int dxBitmap,int dyBitmap,UINT uStructSize); 969 WINCOMMCTRLAPI HBITMAP WINAPI CreateMappedBitmap(HINSTANCE hInstance,INT_PTR idBitmap,UINT wFlags,LPCOLORMAP lpColorMap,int iNumMaps); 970 971 #define CMB_MASKED 0x2 972 #define TBSTATE_CHECKED 0x1 973 #define TBSTATE_PRESSED 0x2 974 #define TBSTATE_ENABLED 0x4 975 #define TBSTATE_HIDDEN 0x8 976 #define TBSTATE_INDETERMINATE 0x10 977 #define TBSTATE_WRAP 0x20 978 #define TBSTATE_ELLIPSES 0x40 979 #define TBSTATE_MARKED 0x80 980 981 #define TBSTYLE_BUTTON 0x0 982 #define TBSTYLE_SEP 0x1 983 #define TBSTYLE_CHECK 0x2 984 #define TBSTYLE_GROUP 0x4 985 #define TBSTYLE_CHECKGROUP (TBSTYLE_GROUP | TBSTYLE_CHECK) 986 #define TBSTYLE_DROPDOWN 0x8 987 #define TBSTYLE_AUTOSIZE 0x10 988 #define TBSTYLE_NOPREFIX 0x20 989 #define TBSTYLE_TOOLTIPS 0x100 990 #define TBSTYLE_WRAPABLE 0x200 991 #define TBSTYLE_ALTDRAG 0x400 992 #define TBSTYLE_FLAT 0x800 993 #define TBSTYLE_LIST 0x1000 994 #define TBSTYLE_CUSTOMERASE 0x2000 995 #define TBSTYLE_REGISTERDROP 0x4000 996 #define TBSTYLE_TRANSPARENT 0x8000 997 998 #define BTNS_BUTTON TBSTYLE_BUTTON 999 #define BTNS_SEP TBSTYLE_SEP 1000 #define BTNS_CHECK TBSTYLE_CHECK 1001 #define BTNS_GROUP TBSTYLE_GROUP 1002 #define BTNS_CHECKGROUP TBSTYLE_CHECKGROUP 1003 #define BTNS_DROPDOWN TBSTYLE_DROPDOWN 1004 #define BTNS_AUTOSIZE TBSTYLE_AUTOSIZE 1005 #define BTNS_NOPREFIX TBSTYLE_NOPREFIX 1006 #define BTNS_SHOWTEXT 0x40 1007 #define BTNS_WHOLEDROPDOWN 0x80 1008 1009 #define TBSTYLE_EX_DRAWDDARROWS 0x00000001 1010 #define TBSTYLE_EX_MULTICOLUMN 0x00000002 1011 #define TBSTYLE_EX_VERTICAL 0x00000004 1012 #define TBSTYLE_EX_MIXEDBUTTONS 0x00000008 1013 #define TBSTYLE_EX_HIDECLIPPEDBUTTONS 0x00000010 /* don't show partially obscured buttons */ 1014 #define TBSTYLE_EX_DOUBLEBUFFER 0x00000080 /* Double Buffer the toolbar */ 1015 1016 typedef struct _NMTBCUSTOMDRAW { 1017 NMCUSTOMDRAW nmcd; 1018 HBRUSH hbrMonoDither; 1019 HBRUSH hbrLines; 1020 HPEN hpenLines; 1021 COLORREF clrText; 1022 COLORREF clrMark; 1023 COLORREF clrTextHighlight; 1024 COLORREF clrBtnFace; 1025 COLORREF clrBtnHighlight; 1026 COLORREF clrHighlightHotTrack; 1027 RECT rcText; 1028 int nStringBkMode; 1029 int nHLStringBkMode; 1030 int iListGap; 1031 } NMTBCUSTOMDRAW,*LPNMTBCUSTOMDRAW; 1032 1033 #define TBCDRF_NOEDGES 0x10000 1034 #define TBCDRF_HILITEHOTTRACK 0x20000 1035 #define TBCDRF_NOOFFSET 0x40000 1036 #define TBCDRF_NOMARK 0x80000 1037 #define TBCDRF_NOETCHEDEFFECT 0x100000 1038 1039 #define TBCDRF_BLENDICON 0x200000 1040 #define TBCDRF_NOBACKGROUND 0x400000 1041 1042 #define TB_ENABLEBUTTON (WM_USER+1) 1043 #define TB_CHECKBUTTON (WM_USER+2) 1044 #define TB_PRESSBUTTON (WM_USER+3) 1045 #define TB_HIDEBUTTON (WM_USER+4) 1046 #define TB_INDETERMINATE (WM_USER+5) 1047 #define TB_MARKBUTTON (WM_USER+6) 1048 #define TB_ISBUTTONENABLED (WM_USER+9) 1049 #define TB_ISBUTTONCHECKED (WM_USER+10) 1050 #define TB_ISBUTTONPRESSED (WM_USER+11) 1051 #define TB_ISBUTTONHIDDEN (WM_USER+12) 1052 #define TB_ISBUTTONINDETERMINATE (WM_USER+13) 1053 #define TB_ISBUTTONHIGHLIGHTED (WM_USER+14) 1054 #define TB_SETSTATE (WM_USER+17) 1055 #define TB_GETSTATE (WM_USER+18) 1056 #define TB_ADDBITMAP (WM_USER+19) 1057 1058 typedef struct tagTBADDBITMAP { 1059 HINSTANCE hInst; 1060 UINT_PTR nID; 1061 } TBADDBITMAP,*LPTBADDBITMAP; 1062 1063 #define HINST_COMMCTRL ((HINSTANCE)-1) 1064 #define IDB_STD_SMALL_COLOR 0 1065 #define IDB_STD_LARGE_COLOR 1 1066 #define IDB_VIEW_SMALL_COLOR 4 1067 #define IDB_VIEW_LARGE_COLOR 5 1068 #define IDB_HIST_SMALL_COLOR 8 1069 #define IDB_HIST_LARGE_COLOR 9 1070 1071 #define STD_CUT 0 1072 #define STD_COPY 1 1073 #define STD_PASTE 2 1074 #define STD_UNDO 3 1075 #define STD_REDOW 4 1076 #define STD_DELETE 5 1077 #define STD_FILENEW 6 1078 #define STD_FILEOPEN 7 1079 #define STD_FILESAVE 8 1080 #define STD_PRINTPRE 9 1081 #define STD_PROPERTIES 10 1082 #define STD_HELP 11 1083 #define STD_FIND 12 1084 #define STD_REPLACE 13 1085 #define STD_PRINT 14 1086 1087 #define VIEW_LARGEICONS 0 1088 #define VIEW_SMALLICONS 1 1089 #define VIEW_LIST 2 1090 #define VIEW_DETAILS 3 1091 #define VIEW_SORTNAME 4 1092 #define VIEW_SORTSIZE 5 1093 #define VIEW_SORTDATE 6 1094 #define VIEW_SORTTYPE 7 1095 #define VIEW_PARENTFOLDER 8 1096 #define VIEW_NETCONNECT 9 1097 #define VIEW_NETDISCONNECT 10 1098 #define VIEW_NEWFOLDER 11 1099 #define VIEW_VIEWMENU 12 1100 #define HIST_BACK 0 1101 #define HIST_FORWARD 1 1102 #define HIST_FAVORITES 2 1103 #define HIST_ADDTOFAVORITES 3 1104 #define HIST_VIEWTREE 4 1105 1106 #define TB_ADDBUTTONSA (WM_USER+20) 1107 #define TB_INSERTBUTTONA (WM_USER+21) 1108 #define TB_DELETEBUTTON (WM_USER+22) 1109 #define TB_GETBUTTON (WM_USER+23) 1110 #define TB_BUTTONCOUNT (WM_USER+24) 1111 #define TB_COMMANDTOINDEX (WM_USER+25) 1112 1113 typedef struct tagTBSAVEPARAMSA { 1114 HKEY hkr; 1115 LPCSTR pszSubKey; 1116 LPCSTR pszValueName; 1117 } TBSAVEPARAMSA,*LPTBSAVEPARAMSA; 1118 1119 typedef struct tagTBSAVEPARAMSW { 1120 HKEY hkr; 1121 LPCWSTR pszSubKey; 1122 LPCWSTR pszValueName; 1123 } TBSAVEPARAMSW,*LPTBSAVEPARAMW; 1124 1125 #define TBSAVEPARAMS __MINGW_NAME_AW(TBSAVEPARAMS) 1126 #define LPTBSAVEPARAMS __MINGW_NAME_AW(LPTBSAVEPARAMS) 1127 1128 #define TB_SAVERESTOREA (WM_USER+26) 1129 #define TB_SAVERESTOREW (WM_USER+76) 1130 #define TB_CUSTOMIZE (WM_USER+27) 1131 #define TB_ADDSTRINGA (WM_USER+28) 1132 #define TB_ADDSTRINGW (WM_USER+77) 1133 #define TB_GETITEMRECT (WM_USER+29) 1134 #define TB_BUTTONSTRUCTSIZE (WM_USER+30) 1135 #define TB_SETBUTTONSIZE (WM_USER+31) 1136 #define TB_SETBITMAPSIZE (WM_USER+32) 1137 #define TB_AUTOSIZE (WM_USER+33) 1138 #define TB_GETTOOLTIPS (WM_USER+35) 1139 #define TB_SETTOOLTIPS (WM_USER+36) 1140 #define TB_SETPARENT (WM_USER+37) 1141 #define TB_SETROWS (WM_USER+39) 1142 #define TB_GETROWS (WM_USER+40) 1143 #define TB_SETCMDID (WM_USER+42) 1144 #define TB_CHANGEBITMAP (WM_USER+43) 1145 #define TB_GETBITMAP (WM_USER+44) 1146 #define TB_GETBUTTONTEXTA (WM_USER+45) 1147 #define TB_GETBUTTONTEXTW (WM_USER+75) 1148 #define TB_REPLACEBITMAP (WM_USER+46) 1149 #define TB_SETINDENT (WM_USER+47) 1150 #define TB_SETIMAGELIST (WM_USER+48) 1151 #define TB_GETIMAGELIST (WM_USER+49) 1152 #define TB_LOADIMAGES (WM_USER+50) 1153 #define TB_GETRECT (WM_USER+51) 1154 #define TB_SETHOTIMAGELIST (WM_USER+52) 1155 #define TB_GETHOTIMAGELIST (WM_USER+53) 1156 #define TB_SETDISABLEDIMAGELIST (WM_USER+54) 1157 #define TB_GETDISABLEDIMAGELIST (WM_USER+55) 1158 #define TB_SETSTYLE (WM_USER+56) 1159 #define TB_GETSTYLE (WM_USER+57) 1160 #define TB_GETBUTTONSIZE (WM_USER+58) 1161 #define TB_SETBUTTONWIDTH (WM_USER+59) 1162 #define TB_SETMAXTEXTROWS (WM_USER+60) 1163 #define TB_GETTEXTROWS (WM_USER+61) 1164 1165 #define TB_GETBUTTONTEXT __MINGW_NAME_AW(TB_GETBUTTONTEXT) 1166 #define TB_SAVERESTORE __MINGW_NAME_AW(TB_SAVERESTORE) 1167 #define TB_ADDSTRING __MINGW_NAME_AW(TB_ADDSTRING) 1168 1169 #define TB_GETOBJECT (WM_USER+62) 1170 #define TB_GETHOTITEM (WM_USER+71) 1171 #define TB_SETHOTITEM (WM_USER+72) 1172 #define TB_SETANCHORHIGHLIGHT (WM_USER+73) 1173 #define TB_GETANCHORHIGHLIGHT (WM_USER+74) 1174 #define TB_MAPACCELERATORA (WM_USER+78) 1175 1176 #define TB_SETBOUNDINGSIZE (WM_USER+93) 1177 1178 typedef struct { 1179 int iButton; 1180 DWORD dwFlags; 1181 } TBINSERTMARK,*LPTBINSERTMARK; 1182 #define TBIMHT_AFTER 0x1 1183 #define TBIMHT_BACKGROUND 0x2 1184 1185 #define TB_GETINSERTMARK (WM_USER+79) 1186 #define TB_SETINSERTMARK (WM_USER+80) 1187 #define TB_INSERTMARKHITTEST (WM_USER+81) 1188 #define TB_MOVEBUTTON (WM_USER+82) 1189 #define TB_GETMAXSIZE (WM_USER+83) 1190 #define TB_SETEXTENDEDSTYLE (WM_USER+84) 1191 #define TB_GETEXTENDEDSTYLE (WM_USER+85) 1192 #define TB_GETPADDING (WM_USER+86) 1193 #define TB_SETPADDING (WM_USER+87) 1194 #define TB_SETINSERTMARKCOLOR (WM_USER+88) 1195 #define TB_GETINSERTMARKCOLOR (WM_USER+89) 1196 1197 #define TB_SETCOLORSCHEME CCM_SETCOLORSCHEME 1198 #define TB_GETCOLORSCHEME CCM_GETCOLORSCHEME 1199 1200 #define TB_SETUNICODEFORMAT CCM_SETUNICODEFORMAT 1201 #define TB_GETUNICODEFORMAT CCM_GETUNICODEFORMAT 1202 1203 #define TB_MAPACCELERATORW (WM_USER+90) 1204 1205 #define TB_MAPACCELERATOR __MINGW_NAME_AW(TB_MAPACCELERATOR) 1206 1207 typedef struct { 1208 HINSTANCE hInstOld; 1209 UINT_PTR nIDOld; 1210 HINSTANCE hInstNew; 1211 UINT_PTR nIDNew; 1212 int nButtons; 1213 } TBREPLACEBITMAP,*LPTBREPLACEBITMAP; 1214 1215 #define TBBF_LARGE 0x1 1216 1217 #define TB_GETBITMAPFLAGS (WM_USER+41) 1218 1219 #define TBIF_IMAGE 0x1 1220 #define TBIF_TEXT 0x2 1221 #define TBIF_STATE 0x4 1222 #define TBIF_STYLE 0x8 1223 #define TBIF_LPARAM 0x10 1224 #define TBIF_COMMAND 0x20 1225 #define TBIF_SIZE 0x40 1226 #define TBIF_BYINDEX 0x80000000 1227 1228 typedef struct { 1229 UINT cbSize; 1230 DWORD dwMask; 1231 int idCommand; 1232 int iImage; 1233 BYTE fsState; 1234 BYTE fsStyle; 1235 WORD cx; 1236 DWORD_PTR lParam; 1237 LPSTR pszText; 1238 int cchText; 1239 } TBBUTTONINFOA,*LPTBBUTTONINFOA; 1240 1241 typedef struct { 1242 UINT cbSize; 1243 DWORD dwMask; 1244 int idCommand; 1245 int iImage; 1246 BYTE fsState; 1247 BYTE fsStyle; 1248 WORD cx; 1249 DWORD_PTR lParam; 1250 LPWSTR pszText; 1251 int cchText; 1252 } TBBUTTONINFOW,*LPTBBUTTONINFOW; 1253 1254 #define TBBUTTONINFO __MINGW_NAME_AW(TBBUTTONINFO) 1255 #define LPTBBUTTONINFO __MINGW_NAME_AW(LPTBBUTTONINFO) 1256 1257 #define TB_GETBUTTONINFOW (WM_USER+63) 1258 #define TB_SETBUTTONINFOW (WM_USER+64) 1259 #define TB_GETBUTTONINFOA (WM_USER+65) 1260 #define TB_SETBUTTONINFOA (WM_USER+66) 1261 1262 #define TB_GETBUTTONINFO __MINGW_NAME_AW(TB_GETBUTTONINFO) 1263 #define TB_SETBUTTONINFO __MINGW_NAME_AW(TB_SETBUTTONINFO) 1264 1265 #define TB_INSERTBUTTONW (WM_USER+67) 1266 #define TB_ADDBUTTONSW (WM_USER+68) 1267 1268 #define TB_HITTEST (WM_USER+69) 1269 1270 #define TB_INSERTBUTTON __MINGW_NAME_AW(TB_INSERTBUTTON) 1271 #define TB_ADDBUTTONS __MINGW_NAME_AW(TB_ADDBUTTONS) 1272 1273 #define TB_SETDRAWTEXTFLAGS (WM_USER+70) 1274 1275 #define TB_GETSTRINGW (WM_USER+91) 1276 #define TB_GETSTRINGA (WM_USER+92) 1277 1278 #define TB_GETSTRING __MINGW_NAME_AW(TB_GETSTRING) 1279 1280 #define TB_SETHOTITEM2 (WM_USER+94) 1281 #define TB_HASACCELERATOR (WM_USER+95) 1282 #define TB_SETLISTGAP (WM_USER+96) 1283 #define TB_GETIMAGELISTCOUNT (WM_USER+98) 1284 #define TB_GETIDEALSIZE (WM_USER+99) 1285 #define TB_TRANSLATEACCELERATOR CCM_TRANSLATEACCELERATOR 1286 1287 #define TBMF_PAD 0x1 1288 #define TBMF_BARPAD 0x2 1289 #define TBMF_BUTTONSPACING 0x4 1290 1291 typedef struct { 1292 UINT cbSize; 1293 DWORD dwMask; 1294 int cxPad; 1295 int cyPad; 1296 int cxBarPad; 1297 int cyBarPad; 1298 int cxButtonSpacing; 1299 int cyButtonSpacing; 1300 } TBMETRICS,*LPTBMETRICS; 1301 1302 #define TB_GETMETRICS (WM_USER+101) 1303 #define TB_SETMETRICS (WM_USER+102) 1304 #define TB_SETWINDOWTHEME CCM_SETWINDOWTHEME 1305 1306 #define TBN_GETBUTTONINFOA (TBN_FIRST-0) 1307 #define TBN_BEGINDRAG (TBN_FIRST-1) 1308 #define TBN_ENDDRAG (TBN_FIRST-2) 1309 #define TBN_BEGINADJUST (TBN_FIRST-3) 1310 #define TBN_ENDADJUST (TBN_FIRST-4) 1311 #define TBN_RESET (TBN_FIRST-5) 1312 #define TBN_QUERYINSERT (TBN_FIRST-6) 1313 #define TBN_QUERYDELETE (TBN_FIRST-7) 1314 #define TBN_TOOLBARCHANGE (TBN_FIRST-8) 1315 #define TBN_CUSTHELP (TBN_FIRST-9) 1316 #define TBN_DROPDOWN (TBN_FIRST - 10) 1317 #define TBN_GETOBJECT (TBN_FIRST - 12) 1318 typedef struct tagNMTBHOTITEM { 1319 NMHDR hdr; 1320 int idOld; 1321 int idNew; 1322 DWORD dwFlags; 1323 } NMTBHOTITEM,*LPNMTBHOTITEM; 1324 1325 #define HICF_OTHER 0x0 1326 #define HICF_MOUSE 0x1 1327 #define HICF_ARROWKEYS 0x2 1328 #define HICF_ACCELERATOR 0x4 1329 #define HICF_DUPACCEL 0x8 1330 #define HICF_ENTERING 0x10 1331 #define HICF_LEAVING 0x20 1332 #define HICF_RESELECT 0x40 1333 #define HICF_LMOUSE 0x80 1334 #define HICF_TOGGLEDROPDOWN 0x100 1335 1336 #define TBN_HOTITEMCHANGE (TBN_FIRST - 13) 1337 #define TBN_DRAGOUT (TBN_FIRST - 14) 1338 #define TBN_DELETINGBUTTON (TBN_FIRST - 15) 1339 #define TBN_GETDISPINFOA (TBN_FIRST - 16) 1340 #define TBN_GETDISPINFOW (TBN_FIRST - 17) 1341 #define TBN_GETINFOTIPA (TBN_FIRST - 18) 1342 #define TBN_GETINFOTIPW (TBN_FIRST - 19) 1343 #define TBN_GETBUTTONINFOW (TBN_FIRST - 20) 1344 #define TBN_RESTORE (TBN_FIRST - 21) 1345 #define TBN_SAVE (TBN_FIRST - 22) 1346 #define TBN_INITCUSTOMIZE (TBN_FIRST - 23) 1347 #define TBN_WRAPHOTITEM (TBN_FIRST - 24) 1348 #define TBN_DUPACCELERATOR (TBN_FIRST - 25) 1349 #define TBN_WRAPACCELERATOR (TBN_FIRST - 26) 1350 #define TBN_DRAGOVER (TBN_FIRST - 27) 1351 #define TBN_MAPACCELERATOR (TBN_FIRST - 28) 1352 #define TBNRF_HIDEHELP 0x1 1353 #define TBNRF_ENDCUSTOMIZE 0x2 1354 1355 typedef struct tagNMTBSAVE { 1356 NMHDR hdr; 1357 DWORD *pData; 1358 DWORD *pCurrent; 1359 UINT cbData; 1360 int iItem; 1361 int cButtons; 1362 TBBUTTON tbButton; 1363 } NMTBSAVE,*LPNMTBSAVE; 1364 1365 typedef struct tagNMTBRESTORE { 1366 NMHDR hdr; 1367 DWORD *pData; 1368 DWORD *pCurrent; 1369 UINT cbData; 1370 int iItem; 1371 int cButtons; 1372 int cbBytesPerRecord; 1373 TBBUTTON tbButton; 1374 } NMTBRESTORE,*LPNMTBRESTORE; 1375 1376 typedef struct tagNMTBGETINFOTIPA { 1377 NMHDR hdr; 1378 LPSTR pszText; 1379 int cchTextMax; 1380 int iItem; 1381 LPARAM lParam; 1382 } NMTBGETINFOTIPA,*LPNMTBGETINFOTIPA; 1383 1384 typedef struct tagNMTBGETINFOTIPW { 1385 NMHDR hdr; 1386 LPWSTR pszText; 1387 int cchTextMax; 1388 int iItem; 1389 LPARAM lParam; 1390 } NMTBGETINFOTIPW,*LPNMTBGETINFOTIPW; 1391 1392 #define TBN_GETINFOTIP __MINGW_NAME_AW(TBN_GETINFOTIP) 1393 #define NMTBGETINFOTIP __MINGW_NAME_AW(NMTBGETINFOTIP) 1394 #define LPNMTBGETINFOTIP __MINGW_NAME_AW(LPNMTBGETINFOTIP) 1395 1396 #define TBNF_IMAGE 0x1 1397 #define TBNF_TEXT 0x2 1398 #define TBNF_DI_SETITEM 0x10000000 1399 1400 typedef struct { 1401 NMHDR hdr; 1402 DWORD dwMask; 1403 int idCommand; 1404 DWORD_PTR lParam; 1405 int iImage; 1406 LPSTR pszText; 1407 int cchText; 1408 } NMTBDISPINFOA,*LPNMTBDISPINFOA; 1409 1410 typedef struct { 1411 NMHDR hdr; 1412 DWORD dwMask; 1413 int idCommand; 1414 DWORD_PTR lParam; 1415 int iImage; 1416 LPWSTR pszText; 1417 int cchText; 1418 } NMTBDISPINFOW,*LPNMTBDISPINFOW; 1419 1420 #define TBN_GETDISPINFO __MINGW_NAME_AW(TBN_GETDISPINFO) 1421 #define NMTBDISPINFO __MINGW_NAME_AW(NMTBDISPINFO) 1422 #define LPNMTBDISPINFO __MINGW_NAME_AW(LPNMTBDISPINFO) 1423 1424 #define TBDDRET_DEFAULT 0 1425 #define TBDDRET_NODEFAULT 1 1426 #define TBDDRET_TREATPRESSED 2 1427 1428 #define TBN_GETBUTTONINFO __MINGW_NAME_AW(TBN_GETBUTTONINFO) 1429 1430 #define TBNOTIFYA NMTOOLBARA 1431 #define TBNOTIFYW NMTOOLBARW 1432 #define LPTBNOTIFYA LPNMTOOLBARA 1433 #define LPTBNOTIFYW LPNMTOOLBARW 1434 1435 #define TBNOTIFY NMTOOLBAR 1436 #define LPTBNOTIFY LPNMTOOLBAR 1437 1438 typedef struct tagNMTOOLBARA { 1439 NMHDR hdr; 1440 int iItem; 1441 TBBUTTON tbButton; 1442 int cchText; 1443 LPSTR pszText; 1444 RECT rcButton; 1445 } NMTOOLBARA,*LPNMTOOLBARA; 1446 1447 typedef struct tagNMTOOLBARW { 1448 NMHDR hdr; 1449 int iItem; 1450 TBBUTTON tbButton; 1451 int cchText; 1452 LPWSTR pszText; 1453 RECT rcButton; 1454 } NMTOOLBARW,*LPNMTOOLBARW; 1455 1456 #define NMTOOLBAR __MINGW_NAME_AW(NMTOOLBAR) 1457 #define LPNMTOOLBAR __MINGW_NAME_AW(LPNMTOOLBAR) 1458 1459 #endif /* !NOTOOLBAR */ 1460 1461 #ifndef NOREBAR 1462 1463 #define REBARCLASSNAMEW L"ReBarWindow32" 1464 #define REBARCLASSNAMEA "ReBarWindow32" 1465 1466 #define REBARCLASSNAME __MINGW_NAME_AW(REBARCLASSNAME) 1467 1468 #define RBIM_IMAGELIST 0x1 1469 1470 #define RBS_TOOLTIPS 0x100 1471 #define RBS_VARHEIGHT 0x200 1472 #define RBS_BANDBORDERS 0x400 1473 #define RBS_FIXEDORDER 0x800 1474 #define RBS_REGISTERDROP 0x1000 1475 #define RBS_AUTOSIZE 0x2000 1476 #define RBS_VERTICALGRIPPER 0x4000 1477 #define RBS_DBLCLKTOGGLE 0x8000 1478 1479 typedef struct tagREBARINFO { 1480 UINT cbSize; 1481 UINT fMask; 1482 #ifndef NOIMAGEAPIS 1483 HIMAGELIST himl; 1484 #else 1485 HANDLE himl; 1486 #endif 1487 } REBARINFO,*LPREBARINFO; 1488 1489 #define RBBS_BREAK 0x1 1490 #define RBBS_FIXEDSIZE 0x2 1491 #define RBBS_CHILDEDGE 0x4 1492 #define RBBS_HIDDEN 0x8 1493 #define RBBS_NOVERT 0x10 1494 #define RBBS_FIXEDBMP 0x20 1495 #define RBBS_VARIABLEHEIGHT 0x40 1496 #define RBBS_GRIPPERALWAYS 0x80 1497 #define RBBS_NOGRIPPER 0x100 1498 #define RBBS_USECHEVRON 0x200 1499 #define RBBS_HIDETITLE 0x400 1500 #define RBBS_TOPALIGN 0x800 1501 1502 #define RBBIM_STYLE 0x1 1503 #define RBBIM_COLORS 0x2 1504 #define RBBIM_TEXT 0x4 1505 #define RBBIM_IMAGE 0x8 1506 #define RBBIM_CHILD 0x10 1507 #define RBBIM_CHILDSIZE 0x20 1508 #define RBBIM_SIZE 0x40 1509 #define RBBIM_BACKGROUND 0x80 1510 #define RBBIM_ID 0x100 1511 #define RBBIM_IDEALSIZE 0x200 1512 #define RBBIM_LPARAM 0x400 1513 #define RBBIM_HEADERSIZE 0x800 1514 1515 typedef struct tagREBARBANDINFOA { 1516 UINT cbSize; 1517 UINT fMask; 1518 UINT fStyle; 1519 COLORREF clrFore; 1520 COLORREF clrBack; 1521 LPSTR lpText; 1522 UINT cch; 1523 int iImage; 1524 HWND hwndChild; 1525 UINT cxMinChild; 1526 UINT cyMinChild; 1527 UINT cx; 1528 HBITMAP hbmBack; 1529 UINT wID; 1530 UINT cyChild; 1531 UINT cyMaxChild; 1532 UINT cyIntegral; 1533 UINT cxIdeal; 1534 LPARAM lParam; 1535 UINT cxHeader; 1536 } REBARBANDINFOA,*LPREBARBANDINFOA; 1537 typedef REBARBANDINFOA CONST *LPCREBARBANDINFOA; 1538 1539 #define REBARBANDINFOA_V3_SIZE CCSIZEOF_STRUCT(REBARBANDINFOA,wID) 1540 #define REBARBANDINFOW_V3_SIZE CCSIZEOF_STRUCT(REBARBANDINFOW,wID) 1541 #define REBARBANDINFOA_V6_SIZE CCSIZEOF_STRUCT(REBARBANDINFOA,cxHeader) 1542 #define REBARBANDINFOW_V6_SIZE CCSIZEOF_STRUCT(REBARBANDINFOW,cxHeader) 1543 1544 typedef struct tagREBARBANDINFOW { 1545 UINT cbSize; 1546 UINT fMask; 1547 UINT fStyle; 1548 COLORREF clrFore; 1549 COLORREF clrBack; 1550 LPWSTR lpText; 1551 UINT cch; 1552 int iImage; 1553 HWND hwndChild; 1554 UINT cxMinChild; 1555 UINT cyMinChild; 1556 UINT cx; 1557 HBITMAP hbmBack; 1558 UINT wID; 1559 UINT cyChild; 1560 UINT cyMaxChild; 1561 UINT cyIntegral; 1562 UINT cxIdeal; 1563 LPARAM lParam; 1564 UINT cxHeader; 1565 } REBARBANDINFOW,*LPREBARBANDINFOW; 1566 1567 typedef REBARBANDINFOW CONST *LPCREBARBANDINFOW; 1568 1569 #define REBARBANDINFO __MINGW_NAME_AW(REBARBANDINFO) 1570 #define LPREBARBANDINFO __MINGW_NAME_AW(LPREBARBANDINFO) 1571 #define LPCREBARBANDINFO __MINGW_NAME_AW(LPCREBARBANDINFO) 1572 1573 #define REBARBANDINFO_V3_SIZE __MINGW_NAME_AW_EXT(REBARBANDINFO,_V3_SIZE) 1574 1575 #define RB_INSERTBANDA (WM_USER+1) 1576 #define RB_DELETEBAND (WM_USER+2) 1577 #define RB_GETBARINFO (WM_USER+3) 1578 #define RB_SETBARINFO (WM_USER+4) 1579 #define RB_SETBANDINFOA (WM_USER+6) 1580 #define RB_SETPARENT (WM_USER+7) 1581 #define RB_HITTEST (WM_USER+8) 1582 #define RB_GETRECT (WM_USER+9) 1583 #define RB_INSERTBANDW (WM_USER+10) 1584 #define RB_SETBANDINFOW (WM_USER+11) 1585 #define RB_GETBANDCOUNT (WM_USER+12) 1586 #define RB_GETROWCOUNT (WM_USER+13) 1587 #define RB_GETROWHEIGHT (WM_USER+14) 1588 #define RB_IDTOINDEX (WM_USER+16) 1589 #define RB_GETTOOLTIPS (WM_USER+17) 1590 #define RB_SETTOOLTIPS (WM_USER+18) 1591 #define RB_SETBKCOLOR (WM_USER+19) 1592 #define RB_GETBKCOLOR (WM_USER+20) 1593 #define RB_SETTEXTCOLOR (WM_USER+21) 1594 #define RB_GETTEXTCOLOR (WM_USER+22) 1595 1596 #define RBSTR_CHANGERECT 0x1 1597 1598 #define RB_SIZETORECT (WM_USER+23) 1599 #define RB_SETCOLORSCHEME CCM_SETCOLORSCHEME 1600 #define RB_GETCOLORSCHEME CCM_GETCOLORSCHEME 1601 1602 #define RB_INSERTBAND __MINGW_NAME_AW(RB_INSERTBAND) 1603 #define RB_SETBANDINFO __MINGW_NAME_AW(RB_SETBANDINFO) 1604 1605 #define RB_BEGINDRAG (WM_USER+24) 1606 #define RB_ENDDRAG (WM_USER+25) 1607 #define RB_DRAGMOVE (WM_USER+26) 1608 #define RB_GETBARHEIGHT (WM_USER+27) 1609 #define RB_GETBANDINFOW (WM_USER+28) 1610 #define RB_GETBANDINFOA (WM_USER+29) 1611 1612 #define RB_GETBANDINFO __MINGW_NAME_AW(RB_GETBANDINFO) 1613 1614 #define RB_MINIMIZEBAND (WM_USER+30) 1615 #define RB_MAXIMIZEBAND (WM_USER+31) 1616 #define RB_GETDROPTARGET (CCM_GETDROPTARGET) 1617 #define RB_GETBANDBORDERS (WM_USER+34) 1618 #define RB_SHOWBAND (WM_USER+35) 1619 #define RB_SETPALETTE (WM_USER+37) 1620 #define RB_GETPALETTE (WM_USER+38) 1621 #define RB_MOVEBAND (WM_USER+39) 1622 #define RB_SETUNICODEFORMAT CCM_SETUNICODEFORMAT 1623 #define RB_GETUNICODEFORMAT CCM_GETUNICODEFORMAT 1624 #define RB_GETBANDMARGINS (WM_USER+40) 1625 #define RB_SETWINDOWTHEME CCM_SETWINDOWTHEME 1626 #define RB_PUSHCHEVRON (WM_USER+43) 1627 1628 #define RBN_HEIGHTCHANGE (RBN_FIRST - 0) 1629 #define RBN_GETOBJECT (RBN_FIRST - 1) 1630 #define RBN_LAYOUTCHANGED (RBN_FIRST - 2) 1631 #define RBN_AUTOSIZE (RBN_FIRST - 3) 1632 #define RBN_BEGINDRAG (RBN_FIRST - 4) 1633 #define RBN_ENDDRAG (RBN_FIRST - 5) 1634 #define RBN_DELETINGBAND (RBN_FIRST - 6) 1635 #define RBN_DELETEDBAND (RBN_FIRST - 7) 1636 #define RBN_CHILDSIZE (RBN_FIRST - 8) 1637 #define RBN_CHEVRONPUSHED (RBN_FIRST - 10) 1638 #define RBN_MINMAX (RBN_FIRST - 21) 1639 #define RBN_AUTOBREAK (RBN_FIRST - 22) 1640 1641 typedef struct tagNMREBARCHILDSIZE { 1642 NMHDR hdr; 1643 UINT uBand; 1644 UINT wID; 1645 RECT rcChild; 1646 RECT rcBand; 1647 } NMREBARCHILDSIZE,*LPNMREBARCHILDSIZE; 1648 1649 typedef struct tagNMREBAR { 1650 NMHDR hdr; 1651 DWORD dwMask; 1652 UINT uBand; 1653 UINT fStyle; 1654 UINT wID; 1655 LPARAM lParam; 1656 } NMREBAR,*LPNMREBAR; 1657 1658 #define RBNM_ID 0x1 1659 #define RBNM_STYLE 0x2 1660 #define RBNM_LPARAM 0x4 1661 1662 typedef struct tagNMRBAUTOSIZE { 1663 NMHDR hdr; 1664 BOOL fChanged; 1665 RECT rcTarget; 1666 RECT rcActual; 1667 } NMRBAUTOSIZE,*LPNMRBAUTOSIZE; 1668 1669 typedef struct tagNMREBARCHEVRON { 1670 NMHDR hdr; 1671 UINT uBand; 1672 UINT wID; 1673 LPARAM lParam; 1674 RECT rc; 1675 LPARAM lParamNM; 1676 } NMREBARCHEVRON,*LPNMREBARCHEVRON; 1677 1678 #define RBAB_AUTOSIZE 0x1 1679 #define RBAB_ADDBAND 0x2 1680 1681 typedef struct tagNMREBARAUTOBREAK { 1682 NMHDR hdr; 1683 UINT uBand; 1684 UINT wID; 1685 LPARAM lParam; 1686 UINT uMsg; 1687 UINT fStyleCurrent; 1688 BOOL fAutoBreak; 1689 } NMREBARAUTOBREAK,*LPNMREBARAUTOBREAK; 1690 1691 #define RBHT_NOWHERE 0x1 1692 #define RBHT_CAPTION 0x2 1693 #define RBHT_CLIENT 0x3 1694 #define RBHT_GRABBER 0x4 1695 #define RBHT_CHEVRON 0x8 1696 1697 typedef struct _RB_HITTESTINFO { 1698 POINT pt; 1699 UINT flags; 1700 int iBand; 1701 } RBHITTESTINFO,*LPRBHITTESTINFO; 1702 1703 #endif /* !NOREBAR */ 1704 1705 #ifndef NOTOOLTIPS 1706 1707 #define TOOLTIPS_CLASSW L"tooltips_class32" 1708 #define TOOLTIPS_CLASSA "tooltips_class32" 1709 1710 #define TOOLTIPS_CLASS __MINGW_NAME_AW(TOOLTIPS_CLASS) 1711 1712 #define LPTOOLINFOA LPTTTOOLINFOA 1713 #define LPTOOLINFOW LPTTTOOLINFOW 1714 #define TOOLINFOA TTTOOLINFOA 1715 #define TOOLINFOW TTTOOLINFOW 1716 1717 #define LPTOOLINFO LPTTTOOLINFO 1718 #define TOOLINFO TTTOOLINFO 1719 1720 #define TTTOOLINFOA_V1_SIZE CCSIZEOF_STRUCT(TTTOOLINFOA,lpszText) 1721 #define TTTOOLINFOW_V1_SIZE CCSIZEOF_STRUCT(TTTOOLINFOW,lpszText) 1722 #define TTTOOLINFOA_V2_SIZE CCSIZEOF_STRUCT(TTTOOLINFOA,lParam) 1723 #define TTTOOLINFOW_V2_SIZE CCSIZEOF_STRUCT(TTTOOLINFOW,lParam) 1724 #define TTTOOLINFOA_V3_SIZE CCSIZEOF_STRUCT(TTTOOLINFOA,lpReserved) 1725 #define TTTOOLINFOW_V3_SIZE CCSIZEOF_STRUCT(TTTOOLINFOW,lpReserved) 1726 1727 typedef struct tagTOOLINFOA { 1728 UINT cbSize; 1729 UINT uFlags; 1730 HWND hwnd; 1731 UINT_PTR uId; 1732 RECT rect; 1733 HINSTANCE hinst; 1734 LPSTR lpszText; 1735 LPARAM lParam; 1736 void *lpReserved; 1737 } TTTOOLINFOA,NEAR *PTOOLINFOA,*LPTTTOOLINFOA; 1738 1739 typedef struct tagTOOLINFOW { 1740 UINT cbSize; 1741 UINT uFlags; 1742 HWND hwnd; 1743 UINT_PTR uId; 1744 RECT rect; 1745 HINSTANCE hinst; 1746 LPWSTR lpszText; 1747 LPARAM lParam; 1748 void *lpReserved; 1749 } TTTOOLINFOW,NEAR *PTOOLINFOW,*LPTTTOOLINFOW; 1750 1751 #define TTTOOLINFO __MINGW_NAME_AW(TTTOOLINFO) 1752 #define PTOOLINFO __MINGW_NAME_AW(PTOOLINFO) 1753 #define LPTTTOOLINFO __MINGW_NAME_AW(LPTTTOOLINFO) 1754 1755 #define TTTOOLINFO_V1_SIZE __MINGW_NAME_AW_EXT(TTTOOLINFO,_V1_SIZE) 1756 1757 #define TTS_ALWAYSTIP 0x1 1758 #define TTS_NOPREFIX 0x2 1759 #define TTS_NOANIMATE 0x10 1760 #define TTS_NOFADE 0x20 1761 #define TTS_BALLOON 0x40 1762 #define TTS_CLOSE 0x80 1763 1764 #define TTF_IDISHWND 0x1 1765 #define TTF_CENTERTIP 0x2 1766 #define TTF_RTLREADING 0x4 1767 #define TTF_SUBCLASS 0x10 1768 #define TTF_TRACK 0x20 1769 #define TTF_ABSOLUTE 0x80 1770 #define TTF_TRANSPARENT 0x100 1771 #define TTF_PARSELINKS 0x1000 1772 #define TTF_DI_SETITEM 0x8000 1773 1774 #define TTDT_AUTOMATIC 0 1775 #define TTDT_RESHOW 1 1776 #define TTDT_AUTOPOP 2 1777 #define TTDT_INITIAL 3 1778 1779 #define TTI_NONE 0 1780 #define TTI_INFO 1 1781 #define TTI_WARNING 2 1782 #define TTI_ERROR 3 1783 #if (_WIN32_WINNT >= 0x0600) 1784 #define TTI_INFO_LARGE 4 1785 #define TTI_WARNING_LARGE 5 1786 #define TTI_ERROR_LARGE 6 1787 #endif 1788 1789 #define TTM_ACTIVATE (WM_USER+1) 1790 #define TTM_SETDELAYTIME (WM_USER+3) 1791 #define TTM_ADDTOOLA (WM_USER+4) 1792 #define TTM_ADDTOOLW (WM_USER+50) 1793 #define TTM_DELTOOLA (WM_USER+5) 1794 #define TTM_DELTOOLW (WM_USER+51) 1795 #define TTM_NEWTOOLRECTA (WM_USER+6) 1796 #define TTM_NEWTOOLRECTW (WM_USER+52) 1797 #define TTM_RELAYEVENT (WM_USER+7) 1798 1799 #define TTM_GETTOOLINFOA (WM_USER+8) 1800 #define TTM_GETTOOLINFOW (WM_USER+53) 1801 1802 #define TTM_SETTOOLINFOA (WM_USER+9) 1803 #define TTM_SETTOOLINFOW (WM_USER+54) 1804 1805 #define TTM_HITTESTA (WM_USER +10) 1806 #define TTM_HITTESTW (WM_USER +55) 1807 #define TTM_GETTEXTA (WM_USER +11) 1808 #define TTM_GETTEXTW (WM_USER +56) 1809 #define TTM_UPDATETIPTEXTA (WM_USER +12) 1810 #define TTM_UPDATETIPTEXTW (WM_USER +57) 1811 #define TTM_GETTOOLCOUNT (WM_USER +13) 1812 #define TTM_ENUMTOOLSA (WM_USER +14) 1813 #define TTM_ENUMTOOLSW (WM_USER +58) 1814 #define TTM_GETCURRENTTOOLA (WM_USER+15) 1815 #define TTM_GETCURRENTTOOLW (WM_USER+59) 1816 #define TTM_WINDOWFROMPOINT (WM_USER+16) 1817 #define TTM_TRACKACTIVATE (WM_USER+17) 1818 #define TTM_TRACKPOSITION (WM_USER+18) 1819 #define TTM_SETTIPBKCOLOR (WM_USER+19) 1820 #define TTM_SETTIPTEXTCOLOR (WM_USER+20) 1821 #define TTM_GETDELAYTIME (WM_USER+21) 1822 #define TTM_GETTIPBKCOLOR (WM_USER+22) 1823 #define TTM_GETTIPTEXTCOLOR (WM_USER+23) 1824 #define TTM_SETMAXTIPWIDTH (WM_USER+24) 1825 #define TTM_GETMAXTIPWIDTH (WM_USER+25) 1826 #define TTM_SETMARGIN (WM_USER+26) 1827 #define TTM_GETMARGIN (WM_USER+27) 1828 #define TTM_POP (WM_USER+28) 1829 #define TTM_UPDATE (WM_USER+29) 1830 #define TTM_GETBUBBLESIZE (WM_USER+30) 1831 #define TTM_ADJUSTRECT (WM_USER+31) 1832 #define TTM_SETTITLEA (WM_USER+32) 1833 #define TTM_SETTITLEW (WM_USER+33) 1834 1835 #define TTM_POPUP (WM_USER+34) 1836 #define TTM_GETTITLE (WM_USER+35) 1837 typedef struct _TTGETTITLE { 1838 DWORD dwSize; 1839 UINT uTitleBitmap; 1840 UINT cch; 1841 WCHAR *pszTitle; 1842 } TTGETTITLE,*PTTGETTITLE; 1843 1844 #define TTM_ADDTOOL __MINGW_NAME_AW(TTM_ADDTOOL) 1845 #define TTM_DELTOOL __MINGW_NAME_AW(TTM_DELTOOL) 1846 #define TTM_NEWTOOLRECT __MINGW_NAME_AW(TTM_NEWTOOLRECT) 1847 #define TTM_GETTOOLINFO __MINGW_NAME_AW(TTM_GETTOOLINFO) 1848 #define TTM_SETTOOLINFO __MINGW_NAME_AW(TTM_SETTOOLINFO) 1849 #define TTM_HITTEST __MINGW_NAME_AW(TTM_HITTEST) 1850 #define TTM_GETTEXT __MINGW_NAME_AW(TTM_GETTEXT) 1851 #define TTM_UPDATETIPTEXT __MINGW_NAME_AW(TTM_UPDATETIPTEXT) 1852 #define TTM_ENUMTOOLS __MINGW_NAME_AW(TTM_ENUMTOOLS) 1853 #define TTM_GETCURRENTTOOL __MINGW_NAME_AW(TTM_GETCURRENTTOOL) 1854 #define TTM_SETTITLE __MINGW_NAME_AW(TTM_SETTITLE) 1855 1856 #define TTM_SETWINDOWTHEME CCM_SETWINDOWTHEME 1857 1858 #define LPHITTESTINFOW LPTTHITTESTINFOW 1859 #define LPHITTESTINFOA LPTTHITTESTINFOA 1860 #define LPHITTESTINFO LPTTHITTESTINFO 1861 1862 typedef struct _TT_HITTESTINFOA { 1863 HWND hwnd; 1864 POINT pt; 1865 TTTOOLINFOA ti; 1866 } TTHITTESTINFOA,*LPTTHITTESTINFOA; 1867 1868 typedef struct _TT_HITTESTINFOW { 1869 HWND hwnd; 1870 POINT pt; 1871 TTTOOLINFOW ti; 1872 } TTHITTESTINFOW,*LPTTHITTESTINFOW; 1873 1874 #define TTHITTESTINFO __MINGW_NAME_AW(TTHITTESTINFO) 1875 #define LPTTHITTESTINFO __MINGW_NAME_AW(LPTTHITTESTINFO) 1876 1877 #define TTN_GETDISPINFOA (TTN_FIRST - 0) 1878 #define TTN_GETDISPINFOW (TTN_FIRST - 10) 1879 #define TTN_SHOW (TTN_FIRST - 1) 1880 #define TTN_POP (TTN_FIRST - 2) 1881 #define TTN_LINKCLICK (TTN_FIRST - 3) 1882 1883 #define TTN_GETDISPINFO __MINGW_NAME_AW(TTN_GETDISPINFO) 1884 1885 #define TTN_NEEDTEXT TTN_GETDISPINFO 1886 #define TTN_NEEDTEXTA TTN_GETDISPINFOA 1887 #define TTN_NEEDTEXTW TTN_GETDISPINFOW 1888 1889 #define TOOLTIPTEXTW NMTTDISPINFOW 1890 #define TOOLTIPTEXTA NMTTDISPINFOA 1891 #define LPTOOLTIPTEXTA LPNMTTDISPINFOA 1892 #define LPTOOLTIPTEXTW LPNMTTDISPINFOW 1893 1894 #define TOOLTIPTEXT NMTTDISPINFO 1895 #define LPTOOLTIPTEXT LPNMTTDISPINFO 1896 1897 #define NMTTDISPINFOA_V1_SIZE CCSIZEOF_STRUCT(NMTTDISPINFOA,uFlags) 1898 #define NMTTDISPINFOW_V1_SIZE CCSIZEOF_STRUCT(NMTTDISPINFOW,uFlags) 1899 1900 typedef struct tagNMTTDISPINFOA { 1901 NMHDR hdr; 1902 LPSTR lpszText; 1903 char szText[80]; 1904 HINSTANCE hinst; 1905 UINT uFlags; 1906 LPARAM lParam; 1907 } NMTTDISPINFOA,*LPNMTTDISPINFOA; 1908 1909 typedef struct tagNMTTDISPINFOW { 1910 NMHDR hdr; 1911 LPWSTR lpszText; 1912 WCHAR szText[80]; 1913 HINSTANCE hinst; 1914 UINT uFlags; 1915 LPARAM lParam; 1916 } NMTTDISPINFOW,*LPNMTTDISPINFOW; 1917 1918 1919 #define NMTTDISPINFO __MINGW_NAME_AW(NMTTDISPINFO) 1920 #define LPNMTTDISPINFO __MINGW_NAME_AW(LPNMTTDISPINFO) 1921 1922 #define NMTTDISPINFO_V1_SIZE __MINGW_NAME_AW_EXT(NMTTDISPINFO,_V1_SIZE) 1923 1924 #endif /* !NOTOOLTIPS */ 1925 1926 #ifndef NOSTATUSBAR 1927 1928 #define SBARS_SIZEGRIP 0x100 1929 #define SBARS_TOOLTIPS 0x800 1930 #define SBT_TOOLTIPS 0x800 1931 1932 WINCOMMCTRLAPI void WINAPI DrawStatusTextA(HDC hDC,LPCRECT lprc,LPCSTR pszText,UINT uFlags); 1933 WINCOMMCTRLAPI void WINAPI DrawStatusTextW(HDC hDC,LPCRECT lprc,LPCWSTR pszText,UINT uFlags); 1934 1935 WINCOMMCTRLAPI HWND WINAPI CreateStatusWindowA(LONG style,LPCSTR lpszText,HWND hwndParent,UINT wID); 1936 WINCOMMCTRLAPI HWND WINAPI CreateStatusWindowW(LONG style,LPCWSTR lpszText,HWND hwndParent,UINT wID); 1937 1938 #define CreateStatusWindow __MINGW_NAME_AW(CreateStatusWindow) 1939 #define DrawStatusText __MINGW_NAME_AW(DrawStatusText) 1940 1941 #define STATUSCLASSNAMEW L"msctls_statusbar32" 1942 #define STATUSCLASSNAMEA "msctls_statusbar32" 1943 1944 #define STATUSCLASSNAME __MINGW_NAME_AW(STATUSCLASSNAME) 1945 1946 #define SB_SETTEXTA (WM_USER+1) 1947 #define SB_SETTEXTW (WM_USER+11) 1948 #define SB_GETTEXTA (WM_USER+2) 1949 #define SB_GETTEXTW (WM_USER+13) 1950 #define SB_GETTEXTLENGTHA (WM_USER+3) 1951 #define SB_GETTEXTLENGTHW (WM_USER+12) 1952 1953 #define SB_GETTEXT __MINGW_NAME_AW(SB_GETTEXT) 1954 #define SB_SETTEXT __MINGW_NAME_AW(SB_SETTEXT) 1955 #define SB_GETTEXTLENGTH __MINGW_NAME_AW(SB_GETTEXTLENGTH) 1956 #define SB_SETTIPTEXT __MINGW_NAME_AW(SB_SETTIPTEXT) 1957 #define SB_GETTIPTEXT __MINGW_NAME_AW(SB_GETTIPTEXT) 1958 1959 #define SB_SETPARTS (WM_USER+4) 1960 #define SB_GETPARTS (WM_USER+6) 1961 #define SB_GETBORDERS (WM_USER+7) 1962 #define SB_SETMINHEIGHT (WM_USER+8) 1963 #define SB_SIMPLE (WM_USER+9) 1964 #define SB_GETRECT (WM_USER+10) 1965 #define SB_ISSIMPLE (WM_USER+14) 1966 #define SB_SETICON (WM_USER+15) 1967 #define SB_SETTIPTEXTA (WM_USER+16) 1968 #define SB_SETTIPTEXTW (WM_USER+17) 1969 #define SB_GETTIPTEXTA (WM_USER+18) 1970 #define SB_GETTIPTEXTW (WM_USER+19) 1971 #define SB_GETICON (WM_USER+20) 1972 #define SB_SETUNICODEFORMAT CCM_SETUNICODEFORMAT 1973 #define SB_GETUNICODEFORMAT CCM_GETUNICODEFORMAT 1974 1975 #define SBT_OWNERDRAW 0x1000 1976 #define SBT_NOBORDERS 0x100 1977 #define SBT_POPOUT 0x200 1978 #define SBT_RTLREADING 0x400 1979 #define SBT_NOTABPARSING 0x800 1980 1981 #define SB_SETBKCOLOR CCM_SETBKCOLOR 1982 1983 #define SBN_SIMPLEMODECHANGE (SBN_FIRST - 0) 1984 1985 #define SB_SIMPLEID 0xff 1986 1987 #endif /* !NOSTATUSBAR */ 1988 1989 #ifndef NOMENUHELP 1990 1991 WINCOMMCTRLAPI void WINAPI MenuHelp(UINT uMsg,WPARAM wParam,LPARAM lParam,HMENU hMainMenu,HINSTANCE hInst,HWND hwndStatus,UINT *lpwIDs); 1992 1993 WINCOMMCTRLAPI 1994 BOOL 1995 WINAPI 1996 ShowHideMenuCtl( 1997 _In_ HWND hWnd, 1998 _In_ UINT_PTR uFlags, 1999 _In_z_ LPINT lpInfo); 2000 2001 WINCOMMCTRLAPI 2002 void 2003 WINAPI 2004 GetEffectiveClientRect( 2005 _In_ HWND hWnd, 2006 _Out_ LPRECT lprc, 2007 _In_z_ const INT *lpInfo); 2008 2009 #define MINSYSCOMMAND SC_SIZE 2010 2011 #endif /* !NOMENUHELP */ 2012 2013 #ifndef NOTRACKBAR 2014 2015 #define TRACKBAR_CLASSA "msctls_trackbar32" 2016 #define TRACKBAR_CLASSW L"msctls_trackbar32" 2017 2018 #define TRACKBAR_CLASS __MINGW_NAME_AW(TRACKBAR_CLASS) 2019 2020 #define TBS_AUTOTICKS 0x1 2021 #define TBS_VERT 0x2 2022 #define TBS_HORZ 0x0 2023 #define TBS_TOP 0x4 2024 #define TBS_BOTTOM 0x0 2025 #define TBS_LEFT 0x4 2026 #define TBS_RIGHT 0x0 2027 #define TBS_BOTH 0x8 2028 #define TBS_NOTICKS 0x10 2029 #define TBS_ENABLESELRANGE 0x20 2030 #define TBS_FIXEDLENGTH 0x40 2031 #define TBS_NOTHUMB 0x80 2032 #define TBS_TOOLTIPS 0x100 2033 #define TBS_REVERSED 0x200 2034 #define TBS_DOWNISLEFT 0x400 2035 2036 #define TBM_GETPOS (WM_USER) 2037 #define TBM_GETRANGEMIN (WM_USER+1) 2038 #define TBM_GETRANGEMAX (WM_USER+2) 2039 #define TBM_GETTIC (WM_USER+3) 2040 #define TBM_SETTIC (WM_USER+4) 2041 #define TBM_SETPOS (WM_USER+5) 2042 #define TBM_SETRANGE (WM_USER+6) 2043 #define TBM_SETRANGEMIN (WM_USER+7) 2044 #define TBM_SETRANGEMAX (WM_USER+8) 2045 #define TBM_CLEARTICS (WM_USER+9) 2046 #define TBM_SETSEL (WM_USER+10) 2047 #define TBM_SETSELSTART (WM_USER+11) 2048 #define TBM_SETSELEND (WM_USER+12) 2049 #define TBM_GETPTICS (WM_USER+14) 2050 #define TBM_GETTICPOS (WM_USER+15) 2051 #define TBM_GETNUMTICS (WM_USER+16) 2052 #define TBM_GETSELSTART (WM_USER+17) 2053 #define TBM_GETSELEND (WM_USER+18) 2054 #define TBM_CLEARSEL (WM_USER+19) 2055 #define TBM_SETTICFREQ (WM_USER+20) 2056 #define TBM_SETPAGESIZE (WM_USER+21) 2057 #define TBM_GETPAGESIZE (WM_USER+22) 2058 #define TBM_SETLINESIZE (WM_USER+23) 2059 #define TBM_GETLINESIZE (WM_USER+24) 2060 #define TBM_GETTHUMBRECT (WM_USER+25) 2061 #define TBM_GETCHANNELRECT (WM_USER+26) 2062 #define TBM_SETTHUMBLENGTH (WM_USER+27) 2063 #define TBM_GETTHUMBLENGTH (WM_USER+28) 2064 #define TBM_SETTOOLTIPS (WM_USER+29) 2065 #define TBM_GETTOOLTIPS (WM_USER+30) 2066 #define TBM_SETTIPSIDE (WM_USER+31) 2067 2068 #define TBTS_TOP 0 2069 #define TBTS_LEFT 1 2070 #define TBTS_BOTTOM 2 2071 #define TBTS_RIGHT 3 2072 2073 #define TBM_SETBUDDY (WM_USER+32) 2074 #define TBM_GETBUDDY (WM_USER+33) 2075 #define TBM_SETUNICODEFORMAT CCM_SETUNICODEFORMAT 2076 #define TBM_GETUNICODEFORMAT CCM_GETUNICODEFORMAT 2077 2078 #define TB_LINEUP 0 2079 #define TB_LINEDOWN 1 2080 #define TB_PAGEUP 2 2081 #define TB_PAGEDOWN 3 2082 #define TB_THUMBPOSITION 4 2083 #define TB_THUMBTRACK 5 2084 #define TB_TOP 6 2085 #define TB_BOTTOM 7 2086 #define TB_ENDTRACK 8 2087 2088 #define TBCD_TICS 0x1 2089 #define TBCD_THUMB 0x2 2090 #define TBCD_CHANNEL 0x3 2091 2092 #endif /* !NOTRACKBAR */ 2093 2094 #ifndef NODRAGLIST 2095 2096 typedef struct tagDRAGLISTINFO { 2097 UINT uNotification; 2098 HWND hWnd; 2099 POINT ptCursor; 2100 } DRAGLISTINFO,*LPDRAGLISTINFO; 2101 2102 #define DL_BEGINDRAG (WM_USER+133) 2103 #define DL_DRAGGING (WM_USER+134) 2104 #define DL_DROPPED (WM_USER+135) 2105 #define DL_CANCELDRAG (WM_USER+136) 2106 2107 #define DL_CURSORSET 0 2108 #define DL_STOPCURSOR 1 2109 #define DL_COPYCURSOR 2 2110 #define DL_MOVECURSOR 3 2111 2112 #define DRAGLISTMSGSTRING TEXT("commctrl_DragListMsg") 2113 2114 WINCOMMCTRLAPI BOOL WINAPI MakeDragList(HWND hLB); 2115 WINCOMMCTRLAPI void WINAPI DrawInsert(HWND handParent,HWND hLB,int nItem); 2116 2117 WINCOMMCTRLAPI int WINAPI LBItemFromPt(HWND hLB,POINT pt,BOOL bAutoScroll); 2118 2119 #endif /* !NODRAGLIST */ 2120 2121 #ifndef NOUPDOWN 2122 2123 #define UPDOWN_CLASSA "msctls_updown32" 2124 #define UPDOWN_CLASSW L"msctls_updown32" 2125 2126 #define UPDOWN_CLASS __MINGW_NAME_AW(UPDOWN_CLASS) 2127 2128 typedef struct _UDACCEL { 2129 UINT nSec; 2130 UINT nInc; 2131 } UDACCEL,*LPUDACCEL; 2132 2133 #define UD_MAXVAL 0x7fff 2134 #define UD_MINVAL (-UD_MAXVAL) 2135 2136 #define UDS_WRAP 0x1 2137 #define UDS_SETBUDDYINT 0x2 2138 #define UDS_ALIGNRIGHT 0x4 2139 #define UDS_ALIGNLEFT 0x8 2140 #define UDS_AUTOBUDDY 0x10 2141 #define UDS_ARROWKEYS 0x20 2142 #define UDS_HORZ 0x40 2143 #define UDS_NOTHOUSANDS 0x80 2144 #define UDS_HOTTRACK 0x100 2145 2146 #define UDM_SETRANGE (WM_USER+101) 2147 #define UDM_GETRANGE (WM_USER+102) 2148 #define UDM_SETPOS (WM_USER+103) 2149 #define UDM_GETPOS (WM_USER+104) 2150 #define UDM_SETBUDDY (WM_USER+105) 2151 #define UDM_GETBUDDY (WM_USER+106) 2152 #define UDM_SETACCEL (WM_USER+107) 2153 #define UDM_GETACCEL (WM_USER+108) 2154 #define UDM_SETBASE (WM_USER+109) 2155 #define UDM_GETBASE (WM_USER+110) 2156 #define UDM_SETRANGE32 (WM_USER+111) 2157 #define UDM_GETRANGE32 (WM_USER+112) 2158 #define UDM_SETUNICODEFORMAT CCM_SETUNICODEFORMAT 2159 #define UDM_GETUNICODEFORMAT CCM_GETUNICODEFORMAT 2160 #define UDM_SETPOS32 (WM_USER+113) 2161 #define UDM_GETPOS32 (WM_USER+114) 2162 2163 WINCOMMCTRLAPI HWND WINAPI CreateUpDownControl(DWORD dwStyle,int x,int y,int cx,int cy,HWND hParent,int nID,HINSTANCE hInst,HWND hBuddy,int nUpper,int nLower,int nPos); 2164 2165 #define NM_UPDOWN NMUPDOWN 2166 #define LPNM_UPDOWN LPNMUPDOWN 2167 2168 typedef struct _NM_UPDOWN { 2169 NMHDR hdr; 2170 int iPos; 2171 int iDelta; 2172 } NMUPDOWN,*LPNMUPDOWN; 2173 2174 #define UDN_DELTAPOS (UDN_FIRST - 1) 2175 2176 #endif /* !NOUPDOWN */ 2177 2178 #ifndef NOPROGRESS 2179 2180 #define PROGRESS_CLASSA "msctls_progress32" 2181 #define PROGRESS_CLASSW L"msctls_progress32" 2182 2183 #define PROGRESS_CLASS __MINGW_NAME_AW(PROGRESS_CLASS) 2184 2185 #define PBS_SMOOTH 0x1 2186 #define PBS_VERTICAL 0x4 2187 2188 #define PBM_SETRANGE (WM_USER+1) 2189 #define PBM_SETPOS (WM_USER+2) 2190 #define PBM_DELTAPOS (WM_USER+3) 2191 #define PBM_SETSTEP (WM_USER+4) 2192 #define PBM_STEPIT (WM_USER+5) 2193 #define PBM_SETRANGE32 (WM_USER+6) 2194 typedef struct { 2195 int iLow; 2196 int iHigh; 2197 } PBRANGE,*PPBRANGE; 2198 #define PBM_GETRANGE (WM_USER+7) 2199 #define PBM_GETPOS (WM_USER+8) 2200 #define PBM_SETBARCOLOR (WM_USER+9) 2201 #define PBM_SETBKCOLOR CCM_SETBKCOLOR 2202 2203 #define PBS_MARQUEE 0x8 2204 #define PBM_SETMARQUEE (WM_USER+10) 2205 2206 #if (_WIN32_WINNT >= 0x0600) 2207 #define PBM_GETSTEP (WM_USER+13) 2208 #define PBM_GETBKCOLOR (WM_USER+14) 2209 #define PBM_GETBARCOLOR (WM_USER+15) 2210 #define PBM_SETSTATE (WM_USER+16) 2211 #define PBM_GETSTATE (WM_USER+17) 2212 #define PBS_SMOOTHREVERSE 0x10 2213 #define PBST_NORMAL 1 2214 #define PBST_ERROR 2 2215 #define PBST_PAUSED 3 2216 #endif /* (_WIN32_WINNT >= 0x0600) */ 2217 2218 #endif /* !NOPROGRESS */ 2219 2220 2221 #ifndef NOHOTKEY 2222 2223 #define HOTKEYF_SHIFT 0x1 2224 #define HOTKEYF_CONTROL 0x2 2225 #define HOTKEYF_ALT 0x4 2226 #define HOTKEYF_EXT 0x8 2227 #define HKCOMB_NONE 0x1 2228 #define HKCOMB_S 0x2 2229 #define HKCOMB_C 0x4 2230 #define HKCOMB_A 0x8 2231 #define HKCOMB_SC 0x10 2232 #define HKCOMB_SA 0x20 2233 #define HKCOMB_CA 0x40 2234 #define HKCOMB_SCA 0x80 2235 2236 #define HKM_SETHOTKEY (WM_USER+1) 2237 #define HKM_GETHOTKEY (WM_USER+2) 2238 #define HKM_SETRULES (WM_USER+3) 2239 2240 #define HOTKEY_CLASSA "msctls_hotkey32" 2241 #define HOTKEY_CLASSW L"msctls_hotkey32" 2242 2243 #define HOTKEY_CLASS __MINGW_NAME_AW(HOTKEY_CLASS) 2244 2245 #endif /* !NOHOTKEY */ 2246 2247 #define CCS_TOP 0x1L 2248 #define CCS_NOMOVEY 0x2L 2249 #define CCS_BOTTOM 0x3L 2250 #define CCS_NORESIZE 0x4L 2251 #define CCS_NOPARENTALIGN 0x8L 2252 #define CCS_ADJUSTABLE 0x20L 2253 #define CCS_NODIVIDER 0x40L 2254 #define CCS_VERT 0x80L 2255 #define CCS_LEFT (CCS_VERT | CCS_TOP) 2256 #define CCS_RIGHT (CCS_VERT | CCS_BOTTOM) 2257 #define CCS_NOMOVEX (CCS_VERT | CCS_NOMOVEY) 2258 2259 #ifndef NOLISTVIEW 2260 2261 #define WC_LISTVIEWA "SysListView32" 2262 #define WC_LISTVIEWW L"SysListView32" 2263 2264 #define WC_LISTVIEW __MINGW_NAME_AW(WC_LISTVIEW) 2265 2266 #define LVS_ICON 0x0 2267 #define LVS_REPORT 0x1 2268 #define LVS_SMALLICON 0x2 2269 #define LVS_LIST 0x3 2270 #define LVS_TYPEMASK 0x3 2271 #define LVS_SINGLESEL 0x4 2272 #define LVS_SHOWSELALWAYS 0x8 2273 #define LVS_SORTASCENDING 0x10 2274 #define LVS_SORTDESCENDING 0x20 2275 #define LVS_SHAREIMAGELISTS 0x40 2276 #define LVS_NOLABELWRAP 0x80 2277 #define LVS_AUTOARRANGE 0x100 2278 #define LVS_EDITLABELS 0x200 2279 #define LVS_OWNERDATA 0x1000 2280 #define LVS_NOSCROLL 0x2000 2281 2282 #define LVS_TYPESTYLEMASK 0xfc00 2283 2284 #define LVS_ALIGNTOP 0x0 2285 #define LVS_ALIGNLEFT 0x800 2286 #define LVS_ALIGNMASK 0xc00 2287 2288 #define LVS_OWNERDRAWFIXED 0x400 2289 #define LVS_NOCOLUMNHEADER 0x4000 2290 #define LVS_NOSORTHEADER 0x8000 2291 2292 #define LVM_SETUNICODEFORMAT CCM_SETUNICODEFORMAT 2293 #define ListView_SetUnicodeFormat(hwnd,fUnicode) (BOOL)SNDMSG((hwnd),LVM_SETUNICODEFORMAT,(WPARAM)(fUnicode),0) 2294 #define LVM_GETUNICODEFORMAT CCM_GETUNICODEFORMAT 2295 #define ListView_GetUnicodeFormat(hwnd) (BOOL)SNDMSG((hwnd),LVM_GETUNICODEFORMAT,0,0) 2296 #define LVM_GETBKCOLOR (LVM_FIRST+0) 2297 #define ListView_GetBkColor(hwnd) (COLORREF)SNDMSG((hwnd),LVM_GETBKCOLOR,0,0L) 2298 #define LVM_SETBKCOLOR (LVM_FIRST+1) 2299 #define ListView_SetBkColor(hwnd,clrBk) (BOOL)SNDMSG((hwnd),LVM_SETBKCOLOR,0,(LPARAM)(COLORREF)(clrBk)) 2300 #define LVM_GETIMAGELIST (LVM_FIRST+2) 2301 #define ListView_GetImageList(hwnd,iImageList) (HIMAGELIST)SNDMSG((hwnd),LVM_GETIMAGELIST,(WPARAM)(INT)(iImageList),0L) 2302 2303 #define LVSIL_NORMAL 0 2304 #define LVSIL_SMALL 1 2305 #define LVSIL_STATE 2 2306 #define LVSIL_GROUPHEADER 3 2307 2308 #define LVM_SETIMAGELIST (LVM_FIRST+3) 2309 #define ListView_SetImageList(hwnd,himl,iImageList) (HIMAGELIST)SNDMSG((hwnd),LVM_SETIMAGELIST,(WPARAM)(iImageList),(LPARAM)(HIMAGELIST)(himl)) 2310 2311 #define LVM_GETITEMCOUNT (LVM_FIRST+4) 2312 #define ListView_GetItemCount(hwnd) (int)SNDMSG((hwnd),LVM_GETITEMCOUNT,0,0L) 2313 2314 #define LVIF_TEXT 0x1 2315 #define LVIF_IMAGE 0x2 2316 #define LVIF_PARAM 0x4 2317 #define LVIF_STATE 0x8 2318 #define LVIF_INDENT 0x10 2319 #define LVIF_NORECOMPUTE 0x800 2320 #define LVIF_GROUPID 0x100 2321 #define LVIF_COLUMNS 0x200 2322 2323 #define LVIS_FOCUSED 0x1 2324 #define LVIS_SELECTED 0x2 2325 #define LVIS_CUT 0x4 2326 #define LVIS_DROPHILITED 0x8 2327 #define LVIS_GLOW 0x10 2328 #define LVIS_ACTIVATING 0x20 2329 2330 #define LVIS_OVERLAYMASK 0xf00 2331 #define LVIS_STATEIMAGEMASK 0xF000 2332 2333 #define INDEXTOSTATEIMAGEMASK(i) ((i) << 12) 2334 2335 #define I_INDENTCALLBACK (-1) 2336 #define LV_ITEMA LVITEMA 2337 #define LV_ITEMW LVITEMW 2338 2339 #define I_GROUPIDCALLBACK (-1) 2340 #define I_GROUPIDNONE (-2) 2341 2342 #define LV_ITEM LVITEM 2343 2344 #define LVITEMA_V1_SIZE CCSIZEOF_STRUCT(LVITEMA,lParam) 2345 #define LVITEMW_V1_SIZE CCSIZEOF_STRUCT(LVITEMW,lParam) 2346 2347 typedef struct tagLVITEMA { 2348 UINT mask; 2349 int iItem; 2350 int iSubItem; 2351 UINT state; 2352 UINT stateMask; 2353 LPSTR pszText; 2354 int cchTextMax; 2355 int iImage; 2356 LPARAM lParam; 2357 int iIndent; 2358 int iGroupId; 2359 UINT cColumns; 2360 PUINT puColumns; 2361 } LVITEMA,*LPLVITEMA; 2362 2363 typedef struct tagLVITEMW 2364 { 2365 UINT mask; 2366 int iItem; 2367 int iSubItem; 2368 UINT state; 2369 UINT stateMask; 2370 LPWSTR pszText; 2371 int cchTextMax; 2372 int iImage; 2373 LPARAM lParam; 2374 int iIndent; 2375 int iGroupId; 2376 UINT cColumns; 2377 PUINT puColumns; 2378 } LVITEMW,*LPLVITEMW; 2379 2380 #define LVITEM __MINGW_NAME_AW(LVITEM) 2381 #define LPLVITEM __MINGW_NAME_AW(LPLVITEM) 2382 2383 #define LVITEM_V1_SIZE __MINGW_NAME_AW_EXT(LVITEM,_V1_SIZE) 2384 2385 #define LPSTR_TEXTCALLBACKW ((LPWSTR)-1L) 2386 #define LPSTR_TEXTCALLBACKA ((LPSTR)-1L) 2387 2388 #define LPSTR_TEXTCALLBACK __MINGW_NAME_AW(LPSTR_TEXTCALLBACK) 2389 2390 #define I_IMAGECALLBACK (-1) 2391 #define I_IMAGENONE (-2) 2392 #define I_COLUMNSCALLBACK ((UINT)-1) 2393 2394 #define LVM_GETITEMA (LVM_FIRST+5) 2395 #define LVM_GETITEMW (LVM_FIRST+75) 2396 2397 #define LVM_GETITEM __MINGW_NAME_AW(LVM_GETITEM) 2398 2399 #define ListView_GetItem(hwnd,pitem) (BOOL)SNDMSG((hwnd),LVM_GETITEM,0,(LPARAM)(LV_ITEM *)(pitem)) 2400 2401 #define LVM_SETITEMA (LVM_FIRST+6) 2402 #define LVM_SETITEMW (LVM_FIRST+76) 2403 2404 #define LVM_SETITEM __MINGW_NAME_AW(LVM_SETITEM) 2405 2406 #define ListView_SetItem(hwnd,pitem) (BOOL)SNDMSG((hwnd),LVM_SETITEM,0,(LPARAM)(const LV_ITEM *)(pitem)) 2407 2408 #define LVM_INSERTITEMA (LVM_FIRST+7) 2409 #define LVM_INSERTITEMW (LVM_FIRST+77) 2410 2411 #define LVM_INSERTITEM __MINGW_NAME_AW(LVM_INSERTITEM) 2412 2413 #define ListView_InsertItem(hwnd,pitem) (int)SNDMSG((hwnd),LVM_INSERTITEM,0,(LPARAM)(const LV_ITEM *)(pitem)) 2414 2415 #define LVM_DELETEITEM (LVM_FIRST+8) 2416 #define ListView_DeleteItem(hwnd,i) (BOOL)SNDMSG((hwnd),LVM_DELETEITEM,(WPARAM)(int)(i),0L) 2417 2418 #define LVM_DELETEALLITEMS (LVM_FIRST+9) 2419 #define ListView_DeleteAllItems(hwnd) (BOOL)SNDMSG((hwnd),LVM_DELETEALLITEMS,0,0L) 2420 2421 #define LVM_GETCALLBACKMASK (LVM_FIRST+10) 2422 #define ListView_GetCallbackMask(hwnd) (BOOL)SNDMSG((hwnd),LVM_GETCALLBACKMASK,0,0) 2423 2424 #define LVM_SETCALLBACKMASK (LVM_FIRST+11) 2425 #define ListView_SetCallbackMask(hwnd,mask) (BOOL)SNDMSG((hwnd),LVM_SETCALLBACKMASK,(WPARAM)(UINT)(mask),0) 2426 2427 #define LVNI_ALL 0x0 2428 #define LVNI_FOCUSED 0x1 2429 #define LVNI_SELECTED 0x2 2430 #define LVNI_CUT 0x4 2431 #define LVNI_DROPHILITED 0x8 2432 2433 #define LVNI_ABOVE 0x100 2434 #define LVNI_BELOW 0x200 2435 #define LVNI_TOLEFT 0x400 2436 #define LVNI_TORIGHT 0x800 2437 2438 #define LVM_GETNEXTITEM (LVM_FIRST+12) 2439 #define ListView_GetNextItem(hwnd,i,flags) (int)SNDMSG((hwnd),LVM_GETNEXTITEM,(WPARAM)(int)(i),MAKELPARAM((flags),0)) 2440 2441 #define LVFI_PARAM 0x0001 2442 #define LVFI_STRING 0x0002 2443 #define LVFI_SUBSTRING 0x0004 2444 #define LVFI_PARTIAL 0x0008 2445 #define LVFI_WRAP 0x0020 2446 #define LVFI_NEARESTXY 0x0040 2447 2448 #define LV_FINDINFOA LVFINDINFOA 2449 #define LV_FINDINFOW LVFINDINFOW 2450 #define LV_FINDINFO LVFINDINFO 2451 2452 typedef struct tagLVFINDINFOA { 2453 UINT flags; 2454 LPCSTR psz; 2455 LPARAM lParam; 2456 POINT pt; 2457 UINT vkDirection; 2458 } LVFINDINFOA,*LPFINDINFOA; 2459 2460 typedef struct tagLVFINDINFOW { 2461 UINT flags; 2462 LPCWSTR psz; 2463 LPARAM lParam; 2464 POINT pt; 2465 UINT vkDirection; 2466 } LVFINDINFOW,*LPFINDINFOW; 2467 2468 #define LVFINDINFO __MINGW_NAME_AW(LVFINDINFO) 2469 2470 #define LVM_FINDITEMA (LVM_FIRST+13) 2471 #define LVM_FINDITEMW (LVM_FIRST+83) 2472 2473 #define LVM_FINDITEM __MINGW_NAME_AW(LVM_FINDITEM) 2474 2475 #define ListView_FindItem(hwnd,iStart,plvfi) (int)SNDMSG((hwnd),LVM_FINDITEM,(WPARAM)(int)(iStart),(LPARAM)(const LV_FINDINFO *)(plvfi)) 2476 2477 #define LVIR_BOUNDS 0 2478 #define LVIR_ICON 1 2479 #define LVIR_LABEL 2 2480 #define LVIR_SELECTBOUNDS 3 2481 2482 #define LVM_GETITEMRECT (LVM_FIRST+14) 2483 #define ListView_GetItemRect(hwnd,i,prc,code) (BOOL)SNDMSG((hwnd),LVM_GETITEMRECT,(WPARAM)(int)(i),((prc) ? (((RECT *)(prc))->left = (code),(LPARAM)(RECT *)(prc)) : (LPARAM)(RECT *)NULL)) 2484 2485 #define LVM_SETITEMPOSITION (LVM_FIRST+15) 2486 #define ListView_SetItemPosition(hwndLV,i,x,y) (BOOL)SNDMSG((hwndLV),LVM_SETITEMPOSITION,(WPARAM)(int)(i),MAKELPARAM((x),(y))) 2487 2488 #define LVM_GETITEMPOSITION (LVM_FIRST+16) 2489 #define ListView_GetItemPosition(hwndLV,i,ppt) (BOOL)SNDMSG((hwndLV),LVM_GETITEMPOSITION,(WPARAM)(int)(i),(LPARAM)(POINT *)(ppt)) 2490 2491 #define LVM_GETSTRINGWIDTHA (LVM_FIRST+17) 2492 #define LVM_GETSTRINGWIDTHW (LVM_FIRST+87) 2493 2494 #define LVM_GETSTRINGWIDTH __MINGW_NAME_AW(LVM_GETSTRINGWIDTH) 2495 2496 #define ListView_GetStringWidth(hwndLV,psz) (int)SNDMSG((hwndLV),LVM_GETSTRINGWIDTH,0,(LPARAM)(LPCTSTR)(psz)) 2497 2498 #define LVHT_NOWHERE 0x1 2499 #define LVHT_ONITEMICON 0x2 2500 #define LVHT_ONITEMLABEL 0x4 2501 #define LVHT_ONITEMSTATEICON 0x8 2502 #define LVHT_ONITEM (LVHT_ONITEMICON | LVHT_ONITEMLABEL | LVHT_ONITEMSTATEICON) 2503 2504 #define LVHT_ABOVE 0x8 2505 #define LVHT_BELOW 0x10 2506 #define LVHT_TORIGHT 0x20 2507 #define LVHT_TOLEFT 0x40 2508 2509 #define LV_HITTESTINFO LVHITTESTINFO 2510 2511 #define LVHITTESTINFO_V1_SIZE CCSIZEOF_STRUCT(LVHITTESTINFO,iItem) 2512 2513 typedef struct tagLVHITTESTINFO { 2514 POINT pt; 2515 UINT flags; 2516 int iItem; 2517 int iSubItem; 2518 } LVHITTESTINFO,*LPLVHITTESTINFO; 2519 2520 #define LVM_HITTEST (LVM_FIRST+18) 2521 #define ListView_HitTest(hwndLV,pinfo) (int)SNDMSG((hwndLV),LVM_HITTEST,0,(LPARAM)(LV_HITTESTINFO *)(pinfo)) 2522 2523 #define LVM_ENSUREVISIBLE (LVM_FIRST+19) 2524 #define ListView_EnsureVisible(hwndLV,i,fPartialOK) (BOOL)SNDMSG((hwndLV),LVM_ENSUREVISIBLE,(WPARAM)(int)(i),MAKELPARAM((fPartialOK),0)) 2525 2526 #define LVM_SCROLL (LVM_FIRST+20) 2527 #define ListView_Scroll(hwndLV,dx,dy) (BOOL)SNDMSG((hwndLV),LVM_SCROLL,(WPARAM)(int)(dx),(LPARAM)(int)(dy)) 2528 2529 #define LVM_REDRAWITEMS (LVM_FIRST+21) 2530 #define ListView_RedrawItems(hwndLV,iFirst,iLast) (BOOL)SNDMSG((hwndLV),LVM_REDRAWITEMS,(WPARAM)(int)(iFirst),(LPARAM)(int)(iLast)) 2531 2532 #define LVA_DEFAULT 0x0 2533 #define LVA_ALIGNLEFT 0x1 2534 #define LVA_ALIGNTOP 0x2 2535 #define LVA_SNAPTOGRID 0x5 2536 2537 #define LVM_ARRANGE (LVM_FIRST+22) 2538 #define ListView_Arrange(hwndLV,code) (BOOL)SNDMSG((hwndLV),LVM_ARRANGE,(WPARAM)(UINT)(code),0L) 2539 2540 #define LVM_EDITLABELA (LVM_FIRST+23) 2541 #define LVM_EDITLABELW (LVM_FIRST+118) 2542 2543 #define LVM_EDITLABEL __MINGW_NAME_AW(LVM_EDITLABEL) 2544 2545 #define ListView_EditLabel(hwndLV,i) (HWND)SNDMSG((hwndLV),LVM_EDITLABEL,(WPARAM)(int)(i),0L) 2546 2547 #define LVM_GETEDITCONTROL (LVM_FIRST+24) 2548 #define ListView_GetEditControl(hwndLV) (HWND)SNDMSG((hwndLV),LVM_GETEDITCONTROL,0,0L) 2549 2550 #define LV_COLUMNA LVCOLUMNA 2551 #define LV_COLUMNW LVCOLUMNW 2552 #define LV_COLUMN LVCOLUMN 2553 2554 #define LVCOLUMNA_V1_SIZE CCSIZEOF_STRUCT(LVCOLUMNA,iSubItem) 2555 #define LVCOLUMNW_V1_SIZE CCSIZEOF_STRUCT(LVCOLUMNW,iSubItem) 2556 2557 typedef struct tagLVCOLUMNA { 2558 UINT mask; 2559 int fmt; 2560 int cx; 2561 LPSTR pszText; 2562 int cchTextMax; 2563 int iSubItem; 2564 int iImage; 2565 int iOrder; 2566 } LVCOLUMNA,*LPLVCOLUMNA; 2567 2568 typedef struct tagLVCOLUMNW { 2569 UINT mask; 2570 int fmt; 2571 int cx; 2572 LPWSTR pszText; 2573 int cchTextMax; 2574 int iSubItem; 2575 # if (_WIN32_IE >= 0x0300) 2576 int iImage; 2577 int iOrder; 2578 # endif 2579 # if (_WIN32_WINNT >= 0x0600) 2580 int cxMin; 2581 int cxDefault; 2582 int cxIdeal; 2583 # endif 2584 } LVCOLUMNW,*LPLVCOLUMNW; 2585 2586 #define LVCOLUMN __MINGW_NAME_AW(LVCOLUMN) 2587 #define LPLVCOLUMN __MINGW_NAME_AW(LPLVCOLUMN) 2588 2589 #define LVCOLUMN_V1_SIZE __MINGW_NAME_AW_EXT(LVCOLUMN,_V1_SIZE) 2590 2591 #define LVCF_FMT 0x1 2592 #define LVCF_WIDTH 0x2 2593 #define LVCF_TEXT 0x4 2594 #define LVCF_SUBITEM 0x8 2595 #define LVCF_IMAGE 0x10 2596 #define LVCF_ORDER 0x20 2597 #if (_WIN32_WINNT >= 0x0600) 2598 #define LVCF_MINWIDTH 0x40 2599 #define LVCF_DEFAULTWIDTH 0x80 2600 #define LVCF_IDEALWIDTH 0x100 2601 #endif /* (_WIN32_WINNT >= 0x0600) */ 2602 2603 #define LVCFMT_LEFT 0x0 2604 #define LVCFMT_RIGHT 0x1 2605 #define LVCFMT_CENTER 0x2 2606 #define LVCFMT_JUSTIFYMASK 0x3 2607 #define LVCFMT_IMAGE 0x800 2608 #define LVCFMT_BITMAP_ON_RIGHT 0x1000 2609 #define LVCFMT_COL_HAS_IMAGES 0x8000 2610 #if (_WIN32_WINNT >= 0x0600) 2611 #define LVCFMT_FIXED_WIDTH 0x100 2612 #define LVCFMT_NO_DPI_SCALE 0x40000 2613 #define LVCFMT_FIXED_RATIO 0x80000 2614 #define LVCFMT_LINE_BREAK 0x100000 2615 #define LVCFMT_FILL 0x200000 2616 #define LVCFMT_WRAP 0x400000 2617 #define LVCFMT_NO_TITLE 0x800000 2618 #define LVCFMT_SPLITBUTTON 0x1000000 2619 #define LVCFMT_TILE_PLACEMENTMASK (LVCFMT_LINE_BREAK|LVCFMT_FILL) 2620 #endif /* (_WIN32_WINNT >= 0x0600) */ 2621 2622 #define LVM_GETCOLUMNA (LVM_FIRST+25) 2623 #define LVM_GETCOLUMNW (LVM_FIRST+95) 2624 2625 #define LVM_GETCOLUMN __MINGW_NAME_AW(LVM_GETCOLUMN) 2626 2627 #define ListView_GetColumn(hwnd,iCol,pcol) (BOOL)SNDMSG((hwnd),LVM_GETCOLUMN,(WPARAM)(int)(iCol),(LPARAM)(LV_COLUMN *)(pcol)) 2628 2629 #define LVM_SETCOLUMNA (LVM_FIRST+26) 2630 #define LVM_SETCOLUMNW (LVM_FIRST+96) 2631 2632 #define LVM_SETCOLUMN __MINGW_NAME_AW(LVM_SETCOLUMN) 2633 2634 #define ListView_SetColumn(hwnd,iCol,pcol) (BOOL)SNDMSG((hwnd),LVM_SETCOLUMN,(WPARAM)(int)(iCol),(LPARAM)(const LV_COLUMN *)(pcol)) 2635 2636 #define LVM_INSERTCOLUMNA (LVM_FIRST+27) 2637 #define LVM_INSERTCOLUMNW (LVM_FIRST+97) 2638 2639 #define LVM_INSERTCOLUMN __MINGW_NAME_AW(LVM_INSERTCOLUMN) 2640 2641 #define ListView_InsertColumn(hwnd,iCol,pcol) (int)SNDMSG((hwnd),LVM_INSERTCOLUMN,(WPARAM)(int)(iCol),(LPARAM)(const LV_COLUMN *)(pcol)) 2642 2643 #define LVM_DELETECOLUMN (LVM_FIRST+28) 2644 #define ListView_DeleteColumn(hwnd,iCol) (BOOL)SNDMSG((hwnd),LVM_DELETECOLUMN,(WPARAM)(int)(iCol),0) 2645 2646 #define LVM_GETCOLUMNWIDTH (LVM_FIRST+29) 2647 #define ListView_GetColumnWidth(hwnd,iCol) (int)SNDMSG((hwnd),LVM_GETCOLUMNWIDTH,(WPARAM)(int)(iCol),0) 2648 2649 #define LVSCW_AUTOSIZE -1 2650 #define LVSCW_AUTOSIZE_USEHEADER -2 2651 #define LVM_SETCOLUMNWIDTH (LVM_FIRST+30) 2652 2653 #define ListView_SetColumnWidth(hwnd,iCol,cx) (BOOL)SNDMSG((hwnd),LVM_SETCOLUMNWIDTH,(WPARAM)(int)(iCol),MAKELPARAM((cx),0)) 2654 2655 #define LVM_GETHEADER (LVM_FIRST+31) 2656 #define ListView_GetHeader(hwnd) (HWND)SNDMSG((hwnd),LVM_GETHEADER,0,0L) 2657 #define LVM_CREATEDRAGIMAGE (LVM_FIRST+33) 2658 #define ListView_CreateDragImage(hwnd,i,lpptUpLeft) (HIMAGELIST)SNDMSG((hwnd),LVM_CREATEDRAGIMAGE,(WPARAM)(int)(i),(LPARAM)(LPPOINT)(lpptUpLeft)) 2659 #define LVM_GETVIEWRECT (LVM_FIRST+34) 2660 #define ListView_GetViewRect(hwnd,prc) (BOOL)SNDMSG((hwnd),LVM_GETVIEWRECT,0,(LPARAM)(RECT *)(prc)) 2661 #define LVM_GETTEXTCOLOR (LVM_FIRST+35) 2662 #define ListView_GetTextColor(hwnd) (COLORREF)SNDMSG((hwnd),LVM_GETTEXTCOLOR,0,0L) 2663 #define LVM_SETTEXTCOLOR (LVM_FIRST+36) 2664 #define ListView_SetTextColor(hwnd,clrText) (BOOL)SNDMSG((hwnd),LVM_SETTEXTCOLOR,0,(LPARAM)(COLORREF)(clrText)) 2665 #define LVM_GETTEXTBKCOLOR (LVM_FIRST+37) 2666 #define ListView_GetTextBkColor(hwnd) (COLORREF)SNDMSG((hwnd),LVM_GETTEXTBKCOLOR,0,0L) 2667 #define LVM_SETTEXTBKCOLOR (LVM_FIRST+38) 2668 #define ListView_SetTextBkColor(hwnd,clrTextBk) (BOOL)SNDMSG((hwnd),LVM_SETTEXTBKCOLOR,0,(LPARAM)(COLORREF)(clrTextBk)) 2669 #define LVM_GETTOPINDEX (LVM_FIRST+39) 2670 #define ListView_GetTopIndex(hwndLV) (int)SNDMSG((hwndLV),LVM_GETTOPINDEX,0,0) 2671 #define LVM_GETCOUNTPERPAGE (LVM_FIRST+40) 2672 #define ListView_GetCountPerPage(hwndLV) (int)SNDMSG((hwndLV),LVM_GETCOUNTPERPAGE,0,0) 2673 #define LVM_GETORIGIN (LVM_FIRST+41) 2674 #define ListView_GetOrigin(hwndLV,ppt) (BOOL)SNDMSG((hwndLV),LVM_GETORIGIN,(WPARAM)0,(LPARAM)(POINT *)(ppt)) 2675 #define LVM_UPDATE (LVM_FIRST+42) 2676 #define ListView_Update(hwndLV,i) (BOOL)SNDMSG((hwndLV),LVM_UPDATE,(WPARAM)(i),0L) 2677 #define LVM_SETITEMSTATE (LVM_FIRST+43) 2678 #define ListView_SetItemState(hwndLV,i,data,mask) { LV_ITEM _ms_lvi; _ms_lvi.stateMask = mask; _ms_lvi.state = data; SNDMSG((hwndLV),LVM_SETITEMSTATE,(WPARAM)(i),(LPARAM)(LV_ITEM *)&_ms_lvi);} 2679 #define ListView_SetCheckState(hwndLV,i,fCheck) ListView_SetItemState(hwndLV,i,INDEXTOSTATEIMAGEMASK((fCheck)?2:1),LVIS_STATEIMAGEMASK) 2680 #define LVM_GETITEMSTATE (LVM_FIRST+44) 2681 #define ListView_GetItemState(hwndLV,i,mask) (UINT)SNDMSG((hwndLV),LVM_GETITEMSTATE,(WPARAM)(i),(LPARAM)(mask)) 2682 #define ListView_GetCheckState(hwndLV,i) ((((UINT)(SNDMSG((hwndLV),LVM_GETITEMSTATE,(WPARAM)(i),LVIS_STATEIMAGEMASK))) >> 12) -1) 2683 2684 #define LVM_GETITEMTEXTA (LVM_FIRST+45) 2685 #define LVM_GETITEMTEXTW (LVM_FIRST+115) 2686 2687 #define LVM_GETITEMTEXT __MINGW_NAME_AW(LVM_GETITEMTEXT) 2688 2689 #define ListView_GetItemText(hwndLV,i,iSubItem_,pszText_,cchTextMax_) { LV_ITEM _ms_lvi; _ms_lvi.iSubItem = iSubItem_; _ms_lvi.cchTextMax = cchTextMax_; _ms_lvi.pszText = pszText_; SNDMSG((hwndLV),LVM_GETITEMTEXT,(WPARAM)(i),(LPARAM)(LV_ITEM *)&_ms_lvi);} 2690 2691 #define LVM_SETITEMTEXTA (LVM_FIRST+46) 2692 #define LVM_SETITEMTEXTW (LVM_FIRST+116) 2693 2694 #define LVM_SETITEMTEXT __MINGW_NAME_AW(LVM_SETITEMTEXT) 2695 2696 #define ListView_SetItemText(hwndLV,i,iSubItem_,pszText_) { LV_ITEM _ms_lvi; _ms_lvi.iSubItem = iSubItem_; _ms_lvi.pszText = pszText_; SNDMSG((hwndLV),LVM_SETITEMTEXT,(WPARAM)(i),(LPARAM)(LV_ITEM *)&_ms_lvi);} 2697 2698 #define LVSICF_NOINVALIDATEALL 0x1 2699 #define LVSICF_NOSCROLL 0x2 2700 2701 #define LVM_SETITEMCOUNT (LVM_FIRST+47) 2702 #define ListView_SetItemCount(hwndLV,cItems) SNDMSG((hwndLV),LVM_SETITEMCOUNT,(WPARAM)(cItems),0) 2703 #define ListView_SetItemCountEx(hwndLV,cItems,dwFlags) SNDMSG((hwndLV),LVM_SETITEMCOUNT,(WPARAM)(cItems),(LPARAM)(dwFlags)) 2704 2705 typedef int (CALLBACK *PFNLVCOMPARE)(LPARAM,LPARAM,LPARAM); 2706 2707 #define LVM_SORTITEMS (LVM_FIRST+48) 2708 #define ListView_SortItems(hwndLV,_pfnCompare,_lPrm) (BOOL)SNDMSG((hwndLV),LVM_SORTITEMS,(WPARAM)(LPARAM)(_lPrm),(LPARAM)(PFNLVCOMPARE)(_pfnCompare)) 2709 2710 #define LVM_SETITEMPOSITION32 (LVM_FIRST+49) 2711 #define ListView_SetItemPosition32(hwndLV,i,x0,y0) { POINT ptNewPos; ptNewPos.x = x0; ptNewPos.y = y0; SNDMSG((hwndLV),LVM_SETITEMPOSITION32,(WPARAM)(int)(i),(LPARAM)&ptNewPos); } 2712 2713 #define LVM_GETSELECTEDCOUNT (LVM_FIRST+50) 2714 #define ListView_GetSelectedCount(hwndLV) (UINT)SNDMSG((hwndLV),LVM_GETSELECTEDCOUNT,0,0L) 2715 2716 #define LVM_GETITEMSPACING (LVM_FIRST+51) 2717 #define ListView_GetItemSpacing(hwndLV,fSmall) (DWORD)SNDMSG((hwndLV),LVM_GETITEMSPACING,fSmall,0L) 2718 2719 #define LVM_GETISEARCHSTRINGA (LVM_FIRST+52) 2720 #define LVM_GETISEARCHSTRINGW (LVM_FIRST+117) 2721 2722 #define LVM_GETISEARCHSTRING __MINGW_NAME_AW(LVM_GETISEARCHSTRING) 2723 2724 #define ListView_GetISearchString(hwndLV,lpsz) (BOOL)SNDMSG((hwndLV),LVM_GETISEARCHSTRING,0,(LPARAM)(LPTSTR)(lpsz)) 2725 2726 #define LVM_SETICONSPACING (LVM_FIRST+53) 2727 2728 #define ListView_SetIconSpacing(hwndLV,cx,cy) (DWORD)SNDMSG((hwndLV),LVM_SETICONSPACING,0,MAKELONG(cx,cy)) 2729 #define LVM_SETEXTENDEDLISTVIEWSTYLE (LVM_FIRST+54) 2730 #define ListView_SetExtendedListViewStyle(hwndLV,dw) (DWORD)SNDMSG((hwndLV),LVM_SETEXTENDEDLISTVIEWSTYLE,0,dw) 2731 #define ListView_SetExtendedListViewStyleEx(hwndLV,dwMask,dw) (DWORD)SNDMSG((hwndLV),LVM_SETEXTENDEDLISTVIEWSTYLE,dwMask,dw) 2732 #define LVM_GETEXTENDEDLISTVIEWSTYLE (LVM_FIRST+55) 2733 #define ListView_GetExtendedListViewStyle(hwndLV) (DWORD)SNDMSG((hwndLV),LVM_GETEXTENDEDLISTVIEWSTYLE,0,0) 2734 #define LVS_EX_GRIDLINES 0x1 2735 #define LVS_EX_SUBITEMIMAGES 0x2 2736 #define LVS_EX_CHECKBOXES 0x4 2737 #define LVS_EX_TRACKSELECT 0x8 2738 #define LVS_EX_HEADERDRAGDROP 0x10 2739 #define LVS_EX_FULLROWSELECT 0x20 2740 #define LVS_EX_ONECLICKACTIVATE 0x40 2741 #define LVS_EX_TWOCLICKACTIVATE 0x80 2742 #define LVS_EX_FLATSB 0x100 2743 #define LVS_EX_REGIONAL 0x200 2744 #define LVS_EX_INFOTIP 0x400 2745 #define LVS_EX_UNDERLINEHOT 0x800 2746 #define LVS_EX_UNDERLINECOLD 0x1000 2747 #define LVS_EX_MULTIWORKAREAS 0x2000 2748 #define LVS_EX_LABELTIP 0x4000 2749 #define LVS_EX_BORDERSELECT 0x8000 2750 #define LVS_EX_DOUBLEBUFFER 0x10000 2751 #define LVS_EX_HIDELABELS 0x20000 2752 #define LVS_EX_SINGLEROW 0x40000 2753 #define LVS_EX_SNAPTOGRID 0x80000 2754 #define LVS_EX_SIMPLESELECT 0x100000 2755 #if _WIN32_WINNT >= 0x0600 2756 #define LVS_EX_JUSTIFYCOLUMNS 0x200000 2757 #define LVS_EX_TRANSPARENTBKGND 0x400000 2758 #define LVS_EX_TRANSPARENTSHADOWTEXT 0x800000 2759 #define LVS_EX_AUTOAUTOARRANGE 0x1000000 2760 #define LVS_EX_HEADERINALLVIEWS 0x2000000 2761 #define LVS_EX_AUTOCHECKSELECT 0x8000000 2762 #define LVS_EX_AUTOSIZECOLUMNS 0x10000000 2763 #define LVS_EX_COLUMNSNAPPOINTS 0x40000000 2764 #define LVS_EX_COLUMNOVERFLOW 0x80000000 2765 #endif 2766 2767 #define LVM_GETSUBITEMRECT (LVM_FIRST+56) 2768 #define ListView_GetSubItemRect(hwnd,iItem,iSubItem,code,prc) (BOOL)SNDMSG((hwnd),LVM_GETSUBITEMRECT,(WPARAM)(int)(iItem),((prc) ? ((((LPRECT)(prc))->top = iSubItem),(((LPRECT)(prc))->left = code),(LPARAM)(prc)) : (LPARAM)(LPRECT)NULL)) 2769 #define LVM_SUBITEMHITTEST (LVM_FIRST+57) 2770 #define ListView_SubItemHitTest(hwnd,plvhti) (int)SNDMSG((hwnd),LVM_SUBITEMHITTEST,0,(LPARAM)(LPLVHITTESTINFO)(plvhti)) 2771 #define LVM_SETCOLUMNORDERARRAY (LVM_FIRST+58) 2772 #define ListView_SetColumnOrderArray(hwnd,iCount,pi) (BOOL)SNDMSG((hwnd),LVM_SETCOLUMNORDERARRAY,(WPARAM)(iCount),(LPARAM)(LPINT)(pi)) 2773 #define LVM_GETCOLUMNORDERARRAY (LVM_FIRST+59) 2774 #define ListView_GetColumnOrderArray(hwnd,iCount,pi) (BOOL)SNDMSG((hwnd),LVM_GETCOLUMNORDERARRAY,(WPARAM)(iCount),(LPARAM)(LPINT)(pi)) 2775 #define LVM_SETHOTITEM (LVM_FIRST+60) 2776 #define ListView_SetHotItem(hwnd,i) (int)SNDMSG((hwnd),LVM_SETHOTITEM,(WPARAM)(i),0) 2777 #define LVM_GETHOTITEM (LVM_FIRST+61) 2778 #define ListView_GetHotItem(hwnd) (int)SNDMSG((hwnd),LVM_GETHOTITEM,0,0) 2779 #define LVM_SETHOTCURSOR (LVM_FIRST+62) 2780 #define ListView_SetHotCursor(hwnd,hcur) (HCURSOR)SNDMSG((hwnd),LVM_SETHOTCURSOR,0,(LPARAM)(hcur)) 2781 #define LVM_GETHOTCURSOR (LVM_FIRST+63) 2782 #define ListView_GetHotCursor(hwnd) (HCURSOR)SNDMSG((hwnd),LVM_GETHOTCURSOR,0,0) 2783 #define LVM_APPROXIMATEVIEWRECT (LVM_FIRST+64) 2784 #define ListView_ApproximateViewRect(hwnd,iWidth,iHeight,iCount) (DWORD)SNDMSG((hwnd),LVM_APPROXIMATEVIEWRECT,iCount,MAKELPARAM(iWidth,iHeight)) 2785 2786 #define LV_MAX_WORKAREAS 16 2787 #define LVM_SETWORKAREAS (LVM_FIRST+65) 2788 #define ListView_SetWorkAreas(hwnd,nWorkAreas,prc) (BOOL)SNDMSG((hwnd),LVM_SETWORKAREAS,(WPARAM)(int)(nWorkAreas),(LPARAM)(RECT *)(prc)) 2789 #define LVM_GETWORKAREAS (LVM_FIRST+70) 2790 #define ListView_GetWorkAreas(hwnd,nWorkAreas,prc) (BOOL)SNDMSG((hwnd),LVM_GETWORKAREAS,(WPARAM)(int)(nWorkAreas),(LPARAM)(RECT *)(prc)) 2791 #define LVM_GETNUMBEROFWORKAREAS (LVM_FIRST+73) 2792 #define ListView_GetNumberOfWorkAreas(hwnd,pnWorkAreas) (BOOL)SNDMSG((hwnd),LVM_GETNUMBEROFWORKAREAS,0,(LPARAM)(UINT *)(pnWorkAreas)) 2793 #define LVM_GETSELECTIONMARK (LVM_FIRST+66) 2794 #define ListView_GetSelectionMark(hwnd) (int)SNDMSG((hwnd),LVM_GETSELECTIONMARK,0,0) 2795 #define LVM_SETSELECTIONMARK (LVM_FIRST+67) 2796 #define ListView_SetSelectionMark(hwnd,i) (int)SNDMSG((hwnd),LVM_SETSELECTIONMARK,0,(LPARAM)(i)) 2797 #define LVM_SETHOVERTIME (LVM_FIRST+71) 2798 #define ListView_SetHoverTime(hwndLV,dwHoverTimeMs) (DWORD)SNDMSG((hwndLV),LVM_SETHOVERTIME,0,(LPARAM)(dwHoverTimeMs)) 2799 #define LVM_GETHOVERTIME (LVM_FIRST+72) 2800 #define ListView_GetHoverTime(hwndLV) (DWORD)SNDMSG((hwndLV),LVM_GETHOVERTIME,0,0) 2801 #define LVM_SETTOOLTIPS (LVM_FIRST+74) 2802 #define ListView_SetToolTips(hwndLV,hwndNewHwnd) (HWND)SNDMSG((hwndLV),LVM_SETTOOLTIPS,(WPARAM)(hwndNewHwnd),0) 2803 #define LVM_GETTOOLTIPS (LVM_FIRST+78) 2804 #define ListView_GetToolTips(hwndLV) (HWND)SNDMSG((hwndLV),LVM_GETTOOLTIPS,0,0) 2805 #define LVM_SORTITEMSEX (LVM_FIRST+81) 2806 #define ListView_SortItemsEx(hwndLV,_pfnCompare,_lPrm) (BOOL)SNDMSG((hwndLV),LVM_SORTITEMSEX,(WPARAM)(LPARAM)(_lPrm),(LPARAM)(PFNLVCOMPARE)(_pfnCompare)) 2807 2808 typedef struct tagLVBKIMAGEA { 2809 ULONG ulFlags; 2810 HBITMAP hbm; 2811 LPSTR pszImage; 2812 UINT cchImageMax; 2813 int xOffsetPercent; 2814 int yOffsetPercent; 2815 } LVBKIMAGEA,*LPLVBKIMAGEA; 2816 2817 typedef struct tagLVBKIMAGEW { 2818 ULONG ulFlags; 2819 HBITMAP hbm; 2820 LPWSTR pszImage; 2821 UINT cchImageMax; 2822 int xOffsetPercent; 2823 int yOffsetPercent; 2824 } LVBKIMAGEW,*LPLVBKIMAGEW; 2825 2826 #define LVBKIF_SOURCE_NONE 0x0 2827 #define LVBKIF_SOURCE_HBITMAP 0x1 2828 #define LVBKIF_SOURCE_URL 0x2 2829 #define LVBKIF_SOURCE_MASK 0x3 2830 #define LVBKIF_STYLE_NORMAL 0x0 2831 #define LVBKIF_STYLE_TILE 0x10 2832 #define LVBKIF_STYLE_MASK 0x10 2833 #define LVBKIF_FLAG_TILEOFFSET 0x100 2834 #define LVBKIF_TYPE_WATERMARK 0x10000000 2835 2836 #define LVM_SETBKIMAGEA (LVM_FIRST+68) 2837 #define LVM_SETBKIMAGEW (LVM_FIRST+138) 2838 #define LVM_GETBKIMAGEA (LVM_FIRST+69) 2839 #define LVM_GETBKIMAGEW (LVM_FIRST+139) 2840 2841 #define LVM_SETSELECTEDCOLUMN (LVM_FIRST+140) 2842 #define ListView_SetSelectedColumn(hwnd,iCol) SNDMSG((hwnd),LVM_SETSELECTEDCOLUMN,(WPARAM)iCol,0) 2843 #define LVM_SETTILEWIDTH (LVM_FIRST+141) 2844 #define ListView_SetTileWidth(hwnd,cpWidth) SNDMSG((hwnd),LVM_SETTILEWIDTH,(WPARAM)cpWidth,0) 2845 #define LV_VIEW_ICON 0x0 2846 #define LV_VIEW_DETAILS 0x1 2847 #define LV_VIEW_SMALLICON 0x2 2848 #define LV_VIEW_LIST 0x3 2849 #define LV_VIEW_TILE 0x4 2850 #define LV_VIEW_MAX 0x4 2851 #define LVM_SETVIEW (LVM_FIRST+142) 2852 #define ListView_SetView(hwnd,iView) (DWORD)SNDMSG((hwnd),LVM_SETVIEW,(WPARAM)(DWORD)iView,0) 2853 #define LVM_GETVIEW (LVM_FIRST+143) 2854 #define ListView_GetView(hwnd) (DWORD)SNDMSG((hwnd),LVM_GETVIEW,0,0) 2855 #define LVGF_NONE 0x0 2856 #define LVGF_HEADER 0x1 2857 #define LVGF_FOOTER 0x2 2858 #define LVGF_STATE 0x4 2859 #define LVGF_ALIGN 0x8 2860 #define LVGF_GROUPID 0x10 2861 2862 #define LVGS_NORMAL 0x0 2863 #define LVGS_COLLAPSED 0x1 2864 #define LVGS_HIDDEN 0x2 2865 2866 #define LVGA_HEADER_LEFT 0x1 2867 #define LVGA_HEADER_CENTER 0x2 2868 #define LVGA_HEADER_RIGHT 0x4 2869 #define LVGA_FOOTER_LEFT 0x8 2870 #define LVGA_FOOTER_CENTER 0x10 2871 #define LVGA_FOOTER_RIGHT 0x20 2872 2873 typedef struct tagLVGROUP { 2874 UINT cbSize; 2875 UINT mask; 2876 LPWSTR pszHeader; 2877 int cchHeader; 2878 LPWSTR pszFooter; 2879 int cchFooter; 2880 int iGroupId; 2881 UINT stateMask; 2882 UINT state; 2883 UINT uAlign; 2884 } LVGROUP,*PLVGROUP; 2885 2886 #define LVM_INSERTGROUP (LVM_FIRST+145) 2887 #define ListView_InsertGroup(hwnd,index,pgrp) SNDMSG((hwnd),LVM_INSERTGROUP,(WPARAM)index,(LPARAM)pgrp) 2888 #define LVM_SETGROUPINFO (LVM_FIRST+147) 2889 #define ListView_SetGroupInfo(hwnd,iGroupId,pgrp) SNDMSG((hwnd),LVM_SETGROUPINFO,(WPARAM)iGroupId,(LPARAM)pgrp) 2890 #define LVM_GETGROUPINFO (LVM_FIRST+149) 2891 #define ListView_GetGroupInfo(hwnd,iGroupId,pgrp) SNDMSG((hwnd),LVM_GETGROUPINFO,(WPARAM)iGroupId,(LPARAM)pgrp) 2892 #define LVM_REMOVEGROUP (LVM_FIRST+150) 2893 #define ListView_RemoveGroup(hwnd,iGroupId) SNDMSG((hwnd),LVM_REMOVEGROUP,(WPARAM)iGroupId,0) 2894 #define LVM_MOVEGROUP (LVM_FIRST+151) 2895 #define ListView_MoveGroup(hwnd,iGroupId,toIndex) SNDMSG((hwnd),LVM_MOVEGROUP,(WPARAM)iGroupId,(LPARAM)toIndex) 2896 #define LVM_MOVEITEMTOGROUP (LVM_FIRST+154) 2897 #define ListView_MoveItemToGroup(hwnd,idItemFrom,idGroupTo) SNDMSG((hwnd),LVM_MOVEITEMTOGROUP,(WPARAM)idItemFrom,(LPARAM)idGroupTo) 2898 #define LVGMF_NONE 0x0 2899 #define LVGMF_BORDERSIZE 0x1 2900 #define LVGMF_BORDERCOLOR 0x2 2901 #define LVGMF_TEXTCOLOR 0x4 2902 2903 typedef struct tagLVGROUPMETRICS { 2904 UINT cbSize; 2905 UINT mask; 2906 UINT Left; 2907 UINT Top; 2908 UINT Right; 2909 UINT Bottom; 2910 COLORREF crLeft; 2911 COLORREF crTop; 2912 COLORREF crRight; 2913 COLORREF crBottom; 2914 COLORREF crHeader; 2915 COLORREF crFooter; 2916 } LVGROUPMETRICS,*PLVGROUPMETRICS; 2917 2918 #define LVM_SETGROUPMETRICS (LVM_FIRST+155) 2919 #define ListView_SetGroupMetrics(hwnd,pGroupMetrics) SNDMSG((hwnd),LVM_SETGROUPMETRICS,0,(LPARAM)pGroupMetrics) 2920 #define LVM_GETGROUPMETRICS (LVM_FIRST+156) 2921 #define ListView_GetGroupMetrics(hwnd,pGroupMetrics) SNDMSG((hwnd),LVM_GETGROUPMETRICS,0,(LPARAM)pGroupMetrics) 2922 #define LVM_ENABLEGROUPVIEW (LVM_FIRST+157) 2923 #define ListView_EnableGroupView(hwnd,fEnable) SNDMSG((hwnd),LVM_ENABLEGROUPVIEW,(WPARAM)fEnable,0) 2924 2925 typedef int (CALLBACK *PFNLVGROUPCOMPARE)(int,int,void *); 2926 2927 #define LVM_SORTGROUPS (LVM_FIRST+158) 2928 #define ListView_SortGroups(hwnd,_pfnGroupCompate,_plv) SNDMSG((hwnd),LVM_SORTGROUPS,(WPARAM)_pfnGroupCompate,(LPARAM)_plv) 2929 2930 typedef struct tagLVINSERTGROUPSORTED { 2931 PFNLVGROUPCOMPARE pfnGroupCompare; 2932 void *pvData; 2933 LVGROUP lvGroup; 2934 } LVINSERTGROUPSORTED,*PLVINSERTGROUPSORTED; 2935 2936 #define LVM_INSERTGROUPSORTED (LVM_FIRST+159) 2937 #define ListView_InsertGroupSorted(hwnd,structInsert) SNDMSG((hwnd),LVM_INSERTGROUPSORTED,(WPARAM)structInsert,0) 2938 #define LVM_REMOVEALLGROUPS (LVM_FIRST+160) 2939 #define ListView_RemoveAllGroups(hwnd) SNDMSG((hwnd),LVM_REMOVEALLGROUPS,0,0) 2940 #define LVM_HASGROUP (LVM_FIRST+161) 2941 #define ListView_HasGroup(hwnd,dwGroupId) SNDMSG((hwnd),LVM_HASGROUP,dwGroupId,0) 2942 2943 #define LVTVIF_AUTOSIZE 0x0 2944 #define LVTVIF_FIXEDWIDTH 0x1 2945 #define LVTVIF_FIXEDHEIGHT 0x2 2946 #define LVTVIF_FIXEDSIZE 0x3 2947 2948 #define LVTVIM_TILESIZE 0x1 2949 #define LVTVIM_COLUMNS 0x2 2950 #define LVTVIM_LABELMARGIN 0x4 2951 2952 typedef struct tagLVTILEVIEWINFO { 2953 UINT cbSize; 2954 DWORD dwMask; 2955 DWORD dwFlags; 2956 SIZE sizeTile; 2957 int cLines; 2958 RECT rcLabelMargin; 2959 } LVTILEVIEWINFO,*PLVTILEVIEWINFO; 2960 2961 typedef struct tagLVTILEINFO { 2962 UINT cbSize; 2963 int iItem; 2964 UINT cColumns; 2965 PUINT puColumns; 2966 } LVTILEINFO,*PLVTILEINFO; 2967 2968 #define LVM_SETTILEVIEWINFO (LVM_FIRST+162) 2969 #define ListView_SetTileViewInfo(hwnd,ptvi) SNDMSG((hwnd),LVM_SETTILEVIEWINFO,0,(LPARAM)ptvi) 2970 #define LVM_GETTILEVIEWINFO (LVM_FIRST+163) 2971 #define ListView_GetTileViewInfo(hwnd,ptvi) SNDMSG((hwnd),LVM_GETTILEVIEWINFO,0,(LPARAM)ptvi) 2972 #define LVM_SETTILEINFO (LVM_FIRST+164) 2973 #define ListView_SetTileInfo(hwnd,pti) SNDMSG((hwnd),LVM_SETTILEINFO,0,(LPARAM)pti) 2974 #define LVM_GETTILEINFO (LVM_FIRST+165) 2975 #define ListView_GetTileInfo(hwnd,pti) SNDMSG((hwnd),LVM_GETTILEINFO,0,(LPARAM)pti) 2976 2977 typedef struct { 2978 UINT cbSize; 2979 DWORD dwFlags; 2980 int iItem; 2981 DWORD dwReserved; 2982 } LVINSERTMARK,*LPLVINSERTMARK; 2983 2984 #define LVIM_AFTER 0x1 2985 2986 #define LVM_SETINSERTMARK (LVM_FIRST+166) 2987 #define ListView_SetInsertMark(hwnd,lvim) (BOOL)SNDMSG((hwnd),LVM_SETINSERTMARK,(WPARAM) 0,(LPARAM) (lvim)) 2988 #define LVM_GETINSERTMARK (LVM_FIRST+167) 2989 #define ListView_GetInsertMark(hwnd,lvim) (BOOL)SNDMSG((hwnd),LVM_GETINSERTMARK,(WPARAM) 0,(LPARAM) (lvim)) 2990 #define LVM_INSERTMARKHITTEST (LVM_FIRST+168) 2991 #define ListView_InsertMarkHitTest(hwnd,point,lvim) (int)SNDMSG((hwnd),LVM_INSERTMARKHITTEST,(WPARAM)(LPPOINT)(point),(LPARAM)(LPLVINSERTMARK)(lvim)) 2992 #define LVM_GETINSERTMARKRECT (LVM_FIRST+169) 2993 #define ListView_GetInsertMarkRect(hwnd,rc) (int)SNDMSG((hwnd),LVM_GETINSERTMARKRECT,(WPARAM)0,(LPARAM)(LPRECT)(rc)) 2994 #define LVM_SETINSERTMARKCOLOR (LVM_FIRST+170) 2995 #define ListView_SetInsertMarkColor(hwnd,color) (COLORREF)SNDMSG((hwnd),LVM_SETINSERTMARKCOLOR,(WPARAM)0,(LPARAM)(COLORREF)(color)) 2996 #define LVM_GETINSERTMARKCOLOR (LVM_FIRST+171) 2997 #define ListView_GetInsertMarkColor(hwnd) (COLORREF)SNDMSG((hwnd),LVM_GETINSERTMARKCOLOR,(WPARAM)0,(LPARAM)0) 2998 2999 typedef struct tagLVSETINFOTIP { 3000 UINT cbSize; 3001 DWORD dwFlags; 3002 LPWSTR pszText; 3003 int iItem; 3004 int iSubItem; 3005 } LVSETINFOTIP,*PLVSETINFOTIP; 3006 3007 #define LVM_SETINFOTIP (LVM_FIRST+173) 3008 #define ListView_SetInfoTip(hwndLV,plvInfoTip) (BOOL)SNDMSG((hwndLV),LVM_SETINFOTIP,(WPARAM)0,(LPARAM)plvInfoTip) 3009 #define LVM_GETSELECTEDCOLUMN (LVM_FIRST+174) 3010 #define ListView_GetSelectedColumn(hwnd) (UINT)SNDMSG((hwnd),LVM_GETSELECTEDCOLUMN,0,0) 3011 #define LVM_ISGROUPVIEWENABLED (LVM_FIRST+175) 3012 #define ListView_IsGroupViewEnabled(hwnd) (BOOL)SNDMSG((hwnd),LVM_ISGROUPVIEWENABLED,0,0) 3013 #define LVM_GETOUTLINECOLOR (LVM_FIRST+176) 3014 #define ListView_GetOutlineColor(hwnd) (COLORREF)SNDMSG((hwnd),LVM_GETOUTLINECOLOR,0,0) 3015 #define LVM_SETOUTLINECOLOR (LVM_FIRST+177) 3016 #define ListView_SetOutlineColor(hwnd,color) (COLORREF)SNDMSG((hwnd),LVM_SETOUTLINECOLOR,(WPARAM)0,(LPARAM)(COLORREF)(color)) 3017 #define LVM_CANCELEDITLABEL (LVM_FIRST+179) 3018 #define ListView_CancelEditLabel(hwnd) (VOID)SNDMSG((hwnd),LVM_CANCELEDITLABEL,(WPARAM)0,(LPARAM)0) 3019 #define LVM_MAPINDEXTOID (LVM_FIRST+180) 3020 #define ListView_MapIndexToID(hwnd,index) (UINT)SNDMSG((hwnd),LVM_MAPINDEXTOID,(WPARAM)index,(LPARAM)0) 3021 #define LVM_MAPIDTOINDEX (LVM_FIRST+181) 3022 #define ListView_MapIDToIndex(hwnd,id) (UINT)SNDMSG((hwnd),LVM_MAPIDTOINDEX,(WPARAM)id,(LPARAM)0) 3023 #define LVM_ISITEMVISIBLE (LVM_FIRST+182) 3024 #define ListView_IsItemVisible(hwnd,index) (UINT)SNDMSG((hwnd),LVM_ISITEMVISIBLE,(WPARAM)(index),(LPARAM)0) 3025 3026 #define LVBKIMAGE __MINGW_NAME_AW(LVBKIMAGE) 3027 #define LPLVBKIMAGE __MINGW_NAME_AW(LPLVBKIMAGE) 3028 #define LVM_SETBKIMAGE __MINGW_NAME_AW(LVM_SETBKIMAGE) 3029 #define LVM_GETBKIMAGE __MINGW_NAME_AW(LVM_GETBKIMAGE) 3030 3031 #define ListView_SetBkImage(hwnd,plvbki) (BOOL)SNDMSG((hwnd),LVM_SETBKIMAGE,0,(LPARAM)(plvbki)) 3032 #define ListView_GetBkImage(hwnd,plvbki) (BOOL)SNDMSG((hwnd),LVM_GETBKIMAGE,0,(LPARAM)(plvbki)) 3033 3034 #define LPNM_LISTVIEW LPNMLISTVIEW 3035 #define NM_LISTVIEW NMLISTVIEW 3036 3037 typedef struct tagNMLISTVIEW { 3038 NMHDR hdr; 3039 int iItem; 3040 int iSubItem; 3041 UINT uNewState; 3042 UINT uOldState; 3043 UINT uChanged; 3044 POINT ptAction; 3045 LPARAM lParam; 3046 } NMLISTVIEW,*LPNMLISTVIEW; 3047 3048 typedef struct tagNMITEMACTIVATE { 3049 NMHDR hdr; 3050 int iItem; 3051 int iSubItem; 3052 UINT uNewState; 3053 UINT uOldState; 3054 UINT uChanged; 3055 POINT ptAction; 3056 LPARAM lParam; 3057 UINT uKeyFlags; 3058 } NMITEMACTIVATE,*LPNMITEMACTIVATE; 3059 3060 #define LVKF_ALT 0x1 3061 #define LVKF_CONTROL 0x2 3062 #define LVKF_SHIFT 0x4 3063 3064 #define NMLVCUSTOMDRAW_V3_SIZE CCSIZEOF_STRUCT(NMLVCUSTOMDRW,clrTextBk) 3065 3066 typedef struct tagNMLVCUSTOMDRAW { 3067 NMCUSTOMDRAW nmcd; 3068 COLORREF clrText; 3069 COLORREF clrTextBk; 3070 int iSubItem; 3071 DWORD dwItemType; 3072 COLORREF clrFace; 3073 int iIconEffect; 3074 int iIconPhase; 3075 int iPartId; 3076 int iStateId; 3077 RECT rcText; 3078 UINT uAlign; 3079 } NMLVCUSTOMDRAW,*LPNMLVCUSTOMDRAW; 3080 3081 #define LVCDI_ITEM 0x0 3082 #define LVCDI_GROUP 0x1 3083 3084 #define LVCDRF_NOSELECT 0x10000 3085 #define LVCDRF_NOGROUPFRAME 0x20000 3086 3087 typedef struct tagNMLVCACHEHINT { 3088 NMHDR hdr; 3089 int iFrom; 3090 int iTo; 3091 } NMLVCACHEHINT,*LPNMLVCACHEHINT; 3092 3093 #define LPNM_CACHEHINT LPNMLVCACHEHINT 3094 #define PNM_CACHEHINT LPNMLVCACHEHINT 3095 #define NM_CACHEHINT NMLVCACHEHINT 3096 3097 typedef struct tagNMLVFINDITEMA { 3098 NMHDR hdr; 3099 int iStart; 3100 LVFINDINFOA lvfi; 3101 } NMLVFINDITEMA,*LPNMLVFINDITEMA; 3102 3103 typedef struct tagNMLVFINDITEMW { 3104 NMHDR hdr; 3105 int iStart; 3106 LVFINDINFOW lvfi; 3107 } NMLVFINDITEMW,*LPNMLVFINDITEMW; 3108 3109 #define PNM_FINDITEMA LPNMLVFINDITEMA 3110 #define LPNM_FINDITEMA LPNMLVFINDITEMA 3111 #define NM_FINDITEMA NMLVFINDITEMA 3112 3113 #define PNM_FINDITEMW LPNMLVFINDITEMW 3114 #define LPNM_FINDITEMW LPNMLVFINDITEMW 3115 #define NM_FINDITEMW NMLVFINDITEMW 3116 3117 #define PNM_FINDITEM __MINGW_NAME_AW(PNM_FINDITEM) 3118 #define LPNM_FINDITEM __MINGW_NAME_AW(LPNM_FINDITEM) 3119 #define NM_FINDITEM __MINGW_NAME_AW(NM_FINDITEM) 3120 #define NMLVFINDITEM __MINGW_NAME_AW(NMLVFINDITEM) 3121 #define LPNMLVFINDITEM __MINGW_NAME_AW(LPNMLVFINDITEM) 3122 3123 typedef struct tagNMLVODSTATECHANGE { 3124 NMHDR hdr; 3125 int iFrom; 3126 int iTo; 3127 UINT uNewState; 3128 UINT uOldState; 3129 } NMLVODSTATECHANGE,*LPNMLVODSTATECHANGE; 3130 3131 #define PNM_ODSTATECHANGE LPNMLVODSTATECHANGE 3132 #define LPNM_ODSTATECHANGE LPNMLVODSTATECHANGE 3133 #define NM_ODSTATECHANGE NMLVODSTATECHANGE 3134 3135 #define LVN_ITEMCHANGING (LVN_FIRST-0) 3136 #define LVN_ITEMCHANGED (LVN_FIRST-1) 3137 #define LVN_INSERTITEM (LVN_FIRST-2) 3138 #define LVN_DELETEITEM (LVN_FIRST-3) 3139 #define LVN_DELETEALLITEMS (LVN_FIRST-4) 3140 #define LVN_BEGINLABELEDITA (LVN_FIRST-5) 3141 #define LVN_BEGINLABELEDITW (LVN_FIRST-75) 3142 #define LVN_ENDLABELEDITA (LVN_FIRST-6) 3143 #define LVN_ENDLABELEDITW (LVN_FIRST-76) 3144 #define LVN_COLUMNCLICK (LVN_FIRST-8) 3145 #define LVN_BEGINDRAG (LVN_FIRST-9) 3146 #define LVN_BEGINRDRAG (LVN_FIRST-11) 3147 3148 #define LVN_ODCACHEHINT (LVN_FIRST-13) 3149 #define LVN_ODFINDITEMA (LVN_FIRST-52) 3150 #define LVN_ODFINDITEMW (LVN_FIRST-79) 3151 3152 #define LVN_ITEMACTIVATE (LVN_FIRST-14) 3153 #define LVN_ODSTATECHANGED (LVN_FIRST-15) 3154 3155 #define LVN_ODFINDITEM __MINGW_NAME_AW(LVN_ODFINDITEM) 3156 3157 #define LVN_HOTTRACK (LVN_FIRST-21) 3158 #define LVN_GETDISPINFOA (LVN_FIRST-50) 3159 #define LVN_GETDISPINFOW (LVN_FIRST-77) 3160 #define LVN_SETDISPINFOA (LVN_FIRST-51) 3161 #define LVN_SETDISPINFOW (LVN_FIRST-78) 3162 3163 #define LVN_BEGINLABELEDIT __MINGW_NAME_AW(LVN_BEGINLABELEDIT) 3164 #define LVN_ENDLABELEDIT __MINGW_NAME_AW(LVN_ENDLABELEDIT) 3165 #define LVN_GETDISPINFO __MINGW_NAME_AW(LVN_GETDISPINFO) 3166 #define LVN_SETDISPINFO __MINGW_NAME_AW(LVN_SETDISPINFO) 3167 3168 #define LVN_INCREMENTALSEARCHA (LVN_FIRST-62) 3169 #define LVN_INCREMENTALSEARCHW (LVN_FIRST-63) 3170 3171 #define LVIF_DI_SETITEM 0x1000 3172 3173 #define LV_DISPINFOA NMLVDISPINFOA 3174 #define LV_DISPINFOW NMLVDISPINFOW 3175 #define LV_DISPINFO NMLVDISPINFO 3176 3177 typedef struct tagLVDISPINFO { 3178 NMHDR hdr; 3179 LVITEMA item; 3180 } NMLVDISPINFOA,*LPNMLVDISPINFOA; 3181 3182 typedef struct tagLVDISPINFOW { 3183 NMHDR hdr; 3184 LVITEMW item; 3185 } NMLVDISPINFOW,*LPNMLVDISPINFOW; 3186 3187 #define NMLVDISPINFO __MINGW_NAME_AW(NMLVDISPINFO) 3188 3189 #define LVN_KEYDOWN (LVN_FIRST-55) 3190 3191 #define LV_KEYDOWN NMLVKEYDOWN 3192 3193 #include <pshpack1.h> 3194 3195 typedef struct tagLVKEYDOWN { 3196 NMHDR hdr; 3197 WORD wVKey; 3198 UINT flags; 3199 } NMLVKEYDOWN,*LPNMLVKEYDOWN; 3200 3201 #include <poppack.h> 3202 3203 #define LVN_MARQUEEBEGIN (LVN_FIRST-56) 3204 3205 typedef struct tagNMLVGETINFOTIPA { 3206 NMHDR hdr; 3207 DWORD dwFlags; 3208 LPSTR pszText; 3209 int cchTextMax; 3210 int iItem; 3211 int iSubItem; 3212 LPARAM lParam; 3213 } NMLVGETINFOTIPA,*LPNMLVGETINFOTIPA; 3214 3215 typedef struct tagNMLVGETINFOTIPW { 3216 NMHDR hdr; 3217 DWORD dwFlags; 3218 LPWSTR pszText; 3219 int cchTextMax; 3220 int iItem; 3221 int iSubItem; 3222 LPARAM lParam; 3223 } NMLVGETINFOTIPW,*LPNMLVGETINFOTIPW; 3224 3225 #define LVGIT_UNFOLDED 0x1 3226 3227 #define LVN_GETINFOTIPA (LVN_FIRST-57) 3228 #define LVN_GETINFOTIPW (LVN_FIRST-58) 3229 3230 #define LVN_GETINFOTIP __MINGW_NAME_AW(LVN_GETINFOTIP) 3231 #define NMLVGETINFOTIP __MINGW_NAME_AW(NMLVGETINFOTIP) 3232 #define LPNMLVGETINFOTIP __MINGW_NAME_AW(LPNMLVGETINFOTIP) 3233 3234 typedef struct tagNMLVSCROLL { 3235 NMHDR hdr; 3236 int dx; 3237 int dy; 3238 } NMLVSCROLL,*LPNMLVSCROLL; 3239 3240 #define LVN_BEGINSCROLL (LVN_FIRST-80) 3241 #define LVN_ENDSCROLL (LVN_FIRST-81) 3242 3243 #endif /* !NOLISTVIEW */ 3244 3245 #ifndef NOTREEVIEW 3246 3247 #define WC_TREEVIEWA "SysTreeView32" 3248 #define WC_TREEVIEWW L"SysTreeView32" 3249 3250 #define WC_TREEVIEW __MINGW_NAME_AW(WC_TREEVIEW) 3251 3252 #define TVS_HASBUTTONS 0x1 3253 #define TVS_HASLINES 0x2 3254 #define TVS_LINESATROOT 0x4 3255 #define TVS_EDITLABELS 0x8 3256 #define TVS_DISABLEDRAGDROP 0x10 3257 #define TVS_SHOWSELALWAYS 0x20 3258 #define TVS_RTLREADING 0x40 3259 #define TVS_NOTOOLTIPS 0x80 3260 #define TVS_CHECKBOXES 0x100 3261 #define TVS_TRACKSELECT 0x200 3262 #define TVS_SINGLEEXPAND 0x400 3263 #define TVS_INFOTIP 0x800 3264 #define TVS_FULLROWSELECT 0x1000 3265 #define TVS_NOSCROLL 0x2000 3266 #define TVS_NONEVENHEIGHT 0x4000 3267 #define TVS_NOHSCROLL 0x8000 3268 3269 typedef struct _TREEITEM *HTREEITEM; 3270 3271 #define TVIF_TEXT 0x1 3272 #define TVIF_IMAGE 0x2 3273 #define TVIF_PARAM 0x4 3274 #define TVIF_STATE 0x8 3275 #define TVIF_HANDLE 0x10 3276 #define TVIF_SELECTEDIMAGE 0x20 3277 #define TVIF_CHILDREN 0x40 3278 #if(_WIN32_IE >= 0x0400) 3279 #define TVIF_INTEGRAL 0x80 3280 #endif 3281 #if(_WIN32_IE >= 0x0600) 3282 #define TVIF_STATEEX 0x100 3283 #endif 3284 #define TVIF_EXPANDEDIMAGE 0x200 3285 #define TVIS_SELECTED 0x2 3286 #define TVIS_CUT 0x4 3287 #define TVIS_DROPHILITED 0x8 3288 #define TVIS_BOLD 0x10 3289 #define TVIS_EXPANDED 0x20 3290 #define TVIS_EXPANDEDONCE 0x40 3291 #define TVIS_EXPANDPARTIAL 0x80 3292 #define TVIS_OVERLAYMASK 0xf00 3293 #define TVIS_STATEIMAGEMASK 0xF000 3294 #define TVIS_USERMASK 0xF000 3295 3296 #define TVIS_FOCUSED 0x0001 3297 3298 #define I_CHILDRENCALLBACK (-1) 3299 3300 #define LPTV_ITEMW LPTVITEMW 3301 #define LPTV_ITEMA LPTVITEMA 3302 #define TV_ITEMW TVITEMW 3303 #define TV_ITEMA TVITEMA 3304 #define LPTV_ITEM LPTVITEM 3305 #define TV_ITEM TVITEM 3306 3307 typedef struct tagTVITEMA { 3308 UINT mask; 3309 HTREEITEM hItem; 3310 UINT state; 3311 UINT stateMask; 3312 LPSTR pszText; 3313 int cchTextMax; 3314 int iImage; 3315 int iSelectedImage; 3316 int cChildren; 3317 LPARAM lParam; 3318 } TVITEMA,*LPTVITEMA; 3319 3320 typedef struct tagTVITEMW { 3321 UINT mask; 3322 HTREEITEM hItem; 3323 UINT state; 3324 UINT stateMask; 3325 LPWSTR pszText; 3326 int cchTextMax; 3327 int iImage; 3328 int iSelectedImage; 3329 int cChildren; 3330 LPARAM lParam; 3331 } TVITEMW,*LPTVITEMW; 3332 3333 typedef struct tagTVITEMEXA { 3334 UINT mask; 3335 HTREEITEM hItem; 3336 UINT state; 3337 UINT stateMask; 3338 LPSTR pszText; 3339 int cchTextMax; 3340 int iImage; 3341 int iSelectedImage; 3342 int cChildren; 3343 LPARAM lParam; 3344 int iIntegral; 3345 UINT uStateEx; /* _WIN32_IE >= 0x600 */ 3346 HWND hwnd; /* _WIN32_IE >= 0x600 */ 3347 int iExpandedImage; /* _WIN32_IE >= 0x600 */ 3348 } TVITEMEXA, *LPTVITEMEXA; 3349 3350 typedef struct tagTVITEMEXW { 3351 UINT mask; 3352 HTREEITEM hItem; 3353 UINT state; 3354 UINT stateMask; 3355 LPWSTR pszText; 3356 int cchTextMax; 3357 int iImage; 3358 int iSelectedImage; 3359 int cChildren; 3360 LPARAM lParam; 3361 int iIntegral; 3362 UINT uStateEx; /* _WIN32_IE >= 0x600 */ 3363 HWND hwnd; /* _WIN32_IE >= 0x600 */ 3364 int iExpandedImage; /* _WIN32_IE >= 0x600 */ 3365 } TVITEMEXW, *LPTVITEMEXW; 3366 3367 __MINGW_TYPEDEF_AW(TVITEMEX) 3368 __MINGW_TYPEDEF_AW(LPTVITEMEX) 3369 3370 #define TVITEM __MINGW_NAME_AW(TVITEM) 3371 #define LPTVITEM __MINGW_NAME_AW(LPTVITEM) 3372 3373 #define TVI_ROOT ((HTREEITEM)(ULONG_PTR)-0x10000) 3374 #define TVI_FIRST ((HTREEITEM)(ULONG_PTR)-0xffff) 3375 #define TVI_LAST ((HTREEITEM)(ULONG_PTR)-0xfffe) 3376 #define TVI_SORT ((HTREEITEM)(ULONG_PTR)-0xfffd) 3377 3378 #define LPTV_INSERTSTRUCTA LPTVINSERTSTRUCTA 3379 #define LPTV_INSERTSTRUCTW LPTVINSERTSTRUCTW 3380 #define TV_INSERTSTRUCTA TVINSERTSTRUCTA 3381 #define TV_INSERTSTRUCTW TVINSERTSTRUCTW 3382 #define TV_INSERTSTRUCT TVINSERTSTRUCT 3383 #define LPTV_INSERTSTRUCT LPTVINSERTSTRUCT 3384 3385 #define TVINSERTSTRUCTA_V1_SIZE CCSIZEOF_STRUCT(TVINSERTSTRUCTA,item) 3386 #define TVINSERTSTRUCTW_V1_SIZE CCSIZEOF_STRUCT(TVINSERTSTRUCTW,item) 3387 3388 typedef struct tagTVINSERTSTRUCTA { 3389 HTREEITEM hParent; 3390 HTREEITEM hInsertAfter; 3391 __C89_NAMELESS union { 3392 TVITEMEXA itemex; 3393 TV_ITEMA item; 3394 } DUMMYUNIONNAME; 3395 } TVINSERTSTRUCTA,*LPTVINSERTSTRUCTA; 3396 3397 typedef struct tagTVINSERTSTRUCTW { 3398 HTREEITEM hParent; 3399 HTREEITEM hInsertAfter; 3400 __C89_NAMELESS union { 3401 TVITEMEXW itemex; 3402 TV_ITEMW item; 3403 } DUMMYUNIONNAME; 3404 } TVINSERTSTRUCTW,*LPTVINSERTSTRUCTW; 3405 3406 3407 #define TVINSERTSTRUCT __MINGW_NAME_AW(TVINSERTSTRUCT) 3408 #define LPTVINSERTSTRUCT __MINGW_NAME_AW(LPTVINSERTSTRUCT) 3409 3410 #define TVINSERTSTRUCT_V1_SIZE __MINGW_NAME_AW_EXT(TVINSERTSTRUCT,_V1_SIZE) 3411 3412 #define TVM_INSERTITEMA (TV_FIRST+0) 3413 #define TVM_INSERTITEMW (TV_FIRST+50) 3414 3415 #define TVM_INSERTITEM __MINGW_NAME_AW(TVM_INSERTITEM) 3416 3417 #define TreeView_InsertItem(hwnd,lpis) (HTREEITEM)SNDMSG((hwnd),TVM_INSERTITEM,0,(LPARAM)(LPTV_INSERTSTRUCT)(lpis)) 3418 3419 #define TVM_DELETEITEM (TV_FIRST+1) 3420 #define TreeView_DeleteItem(hwnd,hitem) (BOOL)SNDMSG((hwnd),TVM_DELETEITEM,0,(LPARAM)(HTREEITEM)(hitem)) 3421 3422 #define TreeView_DeleteAllItems(hwnd) (BOOL)SNDMSG((hwnd),TVM_DELETEITEM,0,(LPARAM)TVI_ROOT) 3423 3424 #define TVM_EXPAND (TV_FIRST+2) 3425 #define TreeView_Expand(hwnd,hitem,code) (BOOL)SNDMSG((hwnd),TVM_EXPAND,(WPARAM)(code),(LPARAM)(HTREEITEM)(hitem)) 3426 3427 #define TVE_COLLAPSE 0x1 3428 #define TVE_EXPAND 0x2 3429 #define TVE_TOGGLE 0x3 3430 #define TVE_EXPANDPARTIAL 0x4000 3431 #define TVE_COLLAPSERESET 0x8000 3432 3433 #define TVM_GETITEMRECT (TV_FIRST+4) 3434 #define TreeView_GetItemRect(hwnd,hitem,prc,code) (*(HTREEITEM *)prc = (hitem),(BOOL)SNDMSG((hwnd),TVM_GETITEMRECT,(WPARAM)(code),(LPARAM)(RECT *)(prc))) 3435 3436 #define TVM_GETCOUNT (TV_FIRST+5) 3437 #define TreeView_GetCount(hwnd) (UINT)SNDMSG((hwnd),TVM_GETCOUNT,0,0) 3438 3439 #define TVM_GETINDENT (TV_FIRST+6) 3440 #define TreeView_GetIndent(hwnd) (UINT)SNDMSG((hwnd),TVM_GETINDENT,0,0) 3441 3442 #define TVM_SETINDENT (TV_FIRST+7) 3443 #define TreeView_SetIndent(hwnd,indent) (BOOL)SNDMSG((hwnd),TVM_SETINDENT,(WPARAM)(indent),0) 3444 3445 #define TVM_GETIMAGELIST (TV_FIRST+8) 3446 #define TreeView_GetImageList(hwnd,iImage) (HIMAGELIST)SNDMSG((hwnd),TVM_GETIMAGELIST,iImage,0) 3447 3448 #define TVSIL_NORMAL 0 3449 #define TVSIL_STATE 2 3450 3451 #define TVM_SETIMAGELIST (TV_FIRST+9) 3452 #define TreeView_SetImageList(hwnd,himl,iImage) (HIMAGELIST)SNDMSG((hwnd),TVM_SETIMAGELIST,iImage,(LPARAM)(HIMAGELIST)(himl)) 3453 3454 #define TVM_GETNEXTITEM (TV_FIRST+10) 3455 #define TreeView_GetNextItem(hwnd,hitem,code) (HTREEITEM)SNDMSG((hwnd),TVM_GETNEXTITEM,(WPARAM)(code),(LPARAM)(HTREEITEM)(hitem)) 3456 3457 #define TVGN_ROOT 0x0 3458 #define TVGN_NEXT 0x1 3459 #define TVGN_PREVIOUS 0x2 3460 #define TVGN_PARENT 0x3 3461 #define TVGN_CHILD 0x4 3462 #define TVGN_FIRSTVISIBLE 0x5 3463 #define TVGN_NEXTVISIBLE 0x6 3464 #define TVGN_PREVIOUSVISIBLE 0x7 3465 #define TVGN_DROPHILITE 0x8 3466 #define TVGN_CARET 0x9 3467 #define TVGN_LASTVISIBLE 0xa 3468 3469 #define TVSI_NOSINGLEEXPAND 0x8000 3470 3471 #define TreeView_GetChild(hwnd,hitem) TreeView_GetNextItem(hwnd,hitem,TVGN_CHILD) 3472 #define TreeView_GetNextSibling(hwnd,hitem) TreeView_GetNextItem(hwnd,hitem,TVGN_NEXT) 3473 #define TreeView_GetPrevSibling(hwnd,hitem) TreeView_GetNextItem(hwnd,hitem,TVGN_PREVIOUS) 3474 #define TreeView_GetParent(hwnd,hitem) TreeView_GetNextItem(hwnd,hitem,TVGN_PARENT) 3475 #define TreeView_GetFirstVisible(hwnd) TreeView_GetNextItem(hwnd,NULL,TVGN_FIRSTVISIBLE) 3476 #define TreeView_GetNextVisible(hwnd,hitem) TreeView_GetNextItem(hwnd,hitem,TVGN_NEXTVISIBLE) 3477 #define TreeView_GetPrevVisible(hwnd,hitem) TreeView_GetNextItem(hwnd,hitem,TVGN_PREVIOUSVISIBLE) 3478 #define TreeView_GetSelection(hwnd) TreeView_GetNextItem(hwnd,NULL,TVGN_CARET) 3479 #define TreeView_GetDropHilight(hwnd) TreeView_GetNextItem(hwnd,NULL,TVGN_DROPHILITE) 3480 #define TreeView_GetRoot(hwnd) TreeView_GetNextItem(hwnd,NULL,TVGN_ROOT) 3481 #define TreeView_GetLastVisible(hwnd) TreeView_GetNextItem(hwnd,NULL,TVGN_LASTVISIBLE) 3482 3483 #define TVM_SELECTITEM (TV_FIRST+11) 3484 #define TreeView_Select(hwnd,hitem,code) (BOOL)SNDMSG((hwnd),TVM_SELECTITEM,(WPARAM)(code),(LPARAM)(HTREEITEM)(hitem)) 3485 3486 #define TreeView_SelectItem(hwnd,hitem) TreeView_Select(hwnd,hitem,TVGN_CARET) 3487 #define TreeView_SelectDropTarget(hwnd,hitem) TreeView_Select(hwnd,hitem,TVGN_DROPHILITE) 3488 #define TreeView_SelectSetFirstVisible(hwnd,hitem) TreeView_Select(hwnd,hitem,TVGN_FIRSTVISIBLE) 3489 3490 #define TVM_GETITEMA (TV_FIRST+12) 3491 #define TVM_GETITEMW (TV_FIRST+62) 3492 3493 #define TVM_GETITEM __MINGW_NAME_AW(TVM_GETITEM) 3494 3495 #define TreeView_GetItem(hwnd,pitem) (BOOL)SNDMSG((hwnd),TVM_GETITEM,0,(LPARAM)(TV_ITEM *)(pitem)) 3496 3497 #define TVM_SETITEMA (TV_FIRST+13) 3498 #define TVM_SETITEMW (TV_FIRST+63) 3499 3500 #define TVM_SETITEM __MINGW_NAME_AW(TVM_SETITEM) 3501 3502 #define TreeView_SetItem(hwnd,pitem) (BOOL)SNDMSG((hwnd),TVM_SETITEM,0,(LPARAM)(const TV_ITEM *)(pitem)) 3503 3504 #define TVM_EDITLABELA (TV_FIRST+14) 3505 #define TVM_EDITLABELW (TV_FIRST+65) 3506 3507 #define TVM_EDITLABEL __MINGW_NAME_AW(TVM_EDITLABEL) 3508 3509 #define TreeView_EditLabel(hwnd,hitem) (HWND)SNDMSG((hwnd),TVM_EDITLABEL,0,(LPARAM)(HTREEITEM)(hitem)) 3510 3511 #define TVM_GETEDITCONTROL (TV_FIRST+15) 3512 #define TreeView_GetEditControl(hwnd) (HWND)SNDMSG((hwnd),TVM_GETEDITCONTROL,0,0) 3513 3514 #define TVM_GETVISIBLECOUNT (TV_FIRST+16) 3515 #define TreeView_GetVisibleCount(hwnd) (UINT)SNDMSG((hwnd),TVM_GETVISIBLECOUNT,0,0) 3516 3517 #define TVM_HITTEST (TV_FIRST+17) 3518 #define TreeView_HitTest(hwnd,lpht) (HTREEITEM)SNDMSG((hwnd),TVM_HITTEST,0,(LPARAM)(LPTV_HITTESTINFO)(lpht)) 3519 3520 #define LPTV_HITTESTINFO LPTVHITTESTINFO 3521 #define TV_HITTESTINFO TVHITTESTINFO 3522 3523 typedef struct tagTVHITTESTINFO { 3524 POINT pt; 3525 UINT flags; 3526 HTREEITEM hItem; 3527 } TVHITTESTINFO,*LPTVHITTESTINFO; 3528 3529 #define TVHT_NOWHERE 0x1 3530 #define TVHT_ONITEMICON 0x2 3531 #define TVHT_ONITEMLABEL 0x4 3532 #define TVHT_ONITEM (TVHT_ONITEMICON | TVHT_ONITEMLABEL | TVHT_ONITEMSTATEICON) 3533 #define TVHT_ONITEMINDENT 0x8 3534 #define TVHT_ONITEMBUTTON 0x10 3535 #define TVHT_ONITEMRIGHT 0x20 3536 #define TVHT_ONITEMSTATEICON 0x40 3537 3538 #define TVHT_ABOVE 0x100 3539 #define TVHT_BELOW 0x200 3540 #define TVHT_TORIGHT 0x400 3541 #define TVHT_TOLEFT 0x800 3542 3543 #define TVM_CREATEDRAGIMAGE (TV_FIRST+18) 3544 #define TreeView_CreateDragImage(hwnd,hitem) (HIMAGELIST)SNDMSG((hwnd),TVM_CREATEDRAGIMAGE,0,(LPARAM)(HTREEITEM)(hitem)) 3545 3546 #define TVM_SORTCHILDREN (TV_FIRST+19) 3547 #define TreeView_SortChildren(hwnd,hitem,recurse) (BOOL)SNDMSG((hwnd),TVM_SORTCHILDREN,(WPARAM)(recurse),(LPARAM)(HTREEITEM)(hitem)) 3548 3549 #define TVM_ENSUREVISIBLE (TV_FIRST+20) 3550 #define TreeView_EnsureVisible(hwnd,hitem) (BOOL)SNDMSG((hwnd),TVM_ENSUREVISIBLE,0,(LPARAM)(HTREEITEM)(hitem)) 3551 3552 #define TVM_SORTCHILDRENCB (TV_FIRST+21) 3553 #define TreeView_SortChildrenCB(hwnd,psort,recurse) (BOOL)SNDMSG((hwnd),TVM_SORTCHILDRENCB,(WPARAM)(recurse),(LPARAM)(LPTV_SORTCB)(psort)) 3554 3555 #define TVM_ENDEDITLABELNOW (TV_FIRST+22) 3556 #define TreeView_EndEditLabelNow(hwnd,fCancel) (BOOL)SNDMSG((hwnd),TVM_ENDEDITLABELNOW,(WPARAM)(fCancel),0) 3557 3558 #define TVM_GETISEARCHSTRINGA (TV_FIRST+23) 3559 #define TVM_GETISEARCHSTRINGW (TV_FIRST+64) 3560 3561 #define TVM_GETISEARCHSTRING __MINGW_NAME_AW(TVM_GETISEARCHSTRING) 3562 3563 #define TVM_SETTOOLTIPS (TV_FIRST+24) 3564 #define TreeView_SetToolTips(hwnd,hwndTT) (HWND)SNDMSG((hwnd),TVM_SETTOOLTIPS,(WPARAM)(hwndTT),0) 3565 #define TVM_GETTOOLTIPS (TV_FIRST+25) 3566 #define TreeView_GetToolTips(hwnd) (HWND)SNDMSG((hwnd),TVM_GETTOOLTIPS,0,0) 3567 #define TreeView_GetISearchString(hwndTV,lpsz) (BOOL)SNDMSG((hwndTV),TVM_GETISEARCHSTRING,0,(LPARAM)(LPTSTR)(lpsz)) 3568 3569 #define TVM_SETINSERTMARK (TV_FIRST+26) 3570 #define TreeView_SetInsertMark(hwnd,hItem,fAfter) (BOOL)SNDMSG((hwnd),TVM_SETINSERTMARK,(WPARAM) (fAfter),(LPARAM) (hItem)) 3571 #define TVM_SETUNICODEFORMAT CCM_SETUNICODEFORMAT 3572 #define TreeView_SetUnicodeFormat(hwnd,fUnicode) (BOOL)SNDMSG((hwnd),TVM_SETUNICODEFORMAT,(WPARAM)(fUnicode),0) 3573 #define TVM_GETUNICODEFORMAT CCM_GETUNICODEFORMAT 3574 #define TreeView_GetUnicodeFormat(hwnd) (BOOL)SNDMSG((hwnd),TVM_GETUNICODEFORMAT,0,0) 3575 3576 #define TVM_SETITEMHEIGHT (TV_FIRST+27) 3577 #define TreeView_SetItemHeight(hwnd,iHeight) (int)SNDMSG((hwnd),TVM_SETITEMHEIGHT,(WPARAM)(iHeight),0) 3578 #define TVM_GETITEMHEIGHT (TV_FIRST+28) 3579 #define TreeView_GetItemHeight(hwnd) (int)SNDMSG((hwnd),TVM_GETITEMHEIGHT,0,0) 3580 #define TVM_SETBKCOLOR (TV_FIRST+29) 3581 #define TreeView_SetBkColor(hwnd,clr) (COLORREF)SNDMSG((hwnd),TVM_SETBKCOLOR,0,(LPARAM)(clr)) 3582 #define TVM_SETTEXTCOLOR (TV_FIRST+30) 3583 #define TreeView_SetTextColor(hwnd,clr) (COLORREF)SNDMSG((hwnd),TVM_SETTEXTCOLOR,0,(LPARAM)(clr)) 3584 #define TVM_GETBKCOLOR (TV_FIRST+31) 3585 #define TreeView_GetBkColor(hwnd) (COLORREF)SNDMSG((hwnd),TVM_GETBKCOLOR,0,0) 3586 #define TVM_GETTEXTCOLOR (TV_FIRST+32) 3587 #define TreeView_GetTextColor(hwnd) (COLORREF)SNDMSG((hwnd),TVM_GETTEXTCOLOR,0,0) 3588 #define TVM_SETSCROLLTIME (TV_FIRST+33) 3589 #define TreeView_SetScrollTime(hwnd,uTime) (UINT)SNDMSG((hwnd),TVM_SETSCROLLTIME,uTime,0) 3590 #define TVM_GETSCROLLTIME (TV_FIRST+34) 3591 #define TreeView_GetScrollTime(hwnd) (UINT)SNDMSG((hwnd),TVM_GETSCROLLTIME,0,0) 3592 #define TVM_SETINSERTMARKCOLOR (TV_FIRST+37) 3593 #define TreeView_SetInsertMarkColor(hwnd,clr) (COLORREF)SNDMSG((hwnd),TVM_SETINSERTMARKCOLOR,0,(LPARAM)(clr)) 3594 #define TVM_GETINSERTMARKCOLOR (TV_FIRST+38) 3595 #define TreeView_GetInsertMarkColor(hwnd) (COLORREF)SNDMSG((hwnd),TVM_GETINSERTMARKCOLOR,0,0) 3596 3597 #define TreeView_SetItemState(hwndTV,hti,data,_mask) { TVITEM _ms_TVi; _ms_TVi.mask = TVIF_STATE; _ms_TVi.hItem = hti; _ms_TVi.stateMask = _mask; _ms_TVi.state = data; SNDMSG((hwndTV),TVM_SETITEM,0,(LPARAM)(TV_ITEM *)&_ms_TVi);} 3598 #define TreeView_SetCheckState(hwndTV,hti,fCheck) TreeView_SetItemState(hwndTV,hti,INDEXTOSTATEIMAGEMASK((fCheck)?2:1),TVIS_STATEIMAGEMASK) 3599 #define TVM_GETITEMSTATE (TV_FIRST+39) 3600 #define TreeView_GetItemState(hwndTV,hti,mask) (UINT)SNDMSG((hwndTV),TVM_GETITEMSTATE,(WPARAM)(hti),(LPARAM)(mask)) 3601 #define TreeView_GetCheckState(hwndTV,hti) ((((UINT)(SNDMSG((hwndTV),TVM_GETITEMSTATE,(WPARAM)(hti),TVIS_STATEIMAGEMASK))) >> 12) -1) 3602 #define TVM_SETLINECOLOR (TV_FIRST+40) 3603 #define TreeView_SetLineColor(hwnd,clr) (COLORREF)SNDMSG((hwnd),TVM_SETLINECOLOR,0,(LPARAM)(clr)) 3604 #define TVM_GETLINECOLOR (TV_FIRST+41) 3605 #define TreeView_GetLineColor(hwnd) (COLORREF)SNDMSG((hwnd),TVM_GETLINECOLOR,0,0) 3606 3607 #define TVM_MAPACCIDTOHTREEITEM (TV_FIRST+42) 3608 #define TreeView_MapAccIDToHTREEITEM(hwnd,id) (HTREEITEM)SNDMSG((hwnd),TVM_MAPACCIDTOHTREEITEM,id,0) 3609 3610 #define TVM_MAPHTREEITEMTOACCID (TV_FIRST+43) 3611 #define TreeView_MapHTREEITEMToAccID(hwnd,htreeitem) (UINT)SNDMSG((hwnd),TVM_MAPHTREEITEMTOACCID,(WPARAM)htreeitem,0) 3612 3613 typedef int (CALLBACK *PFNTVCOMPARE)(LPARAM lParam1,LPARAM lParam2,LPARAM lParamSort); 3614 3615 #define LPTV_SORTCB LPTVSORTCB 3616 #define TV_SORTCB TVSORTCB 3617 3618 typedef struct tagTVSORTCB { 3619 HTREEITEM hParent; 3620 PFNTVCOMPARE lpfnCompare; 3621 LPARAM lParam; 3622 } TVSORTCB,*LPTVSORTCB; 3623 3624 #define LPNM_TREEVIEWA LPNMTREEVIEWA 3625 #define LPNM_TREEVIEWW LPNMTREEVIEWW 3626 #define NM_TREEVIEWW NMTREEVIEWW 3627 #define NM_TREEVIEWA NMTREEVIEWA 3628 #define LPNM_TREEVIEW LPNMTREEVIEW 3629 #define NM_TREEVIEW NMTREEVIEW 3630 3631 typedef struct tagNMTREEVIEWA { 3632 NMHDR hdr; 3633 UINT action; 3634 TVITEMA itemOld; 3635 TVITEMA itemNew; 3636 POINT ptDrag; 3637 } NMTREEVIEWA,*LPNMTREEVIEWA; 3638 3639 typedef struct tagNMTREEVIEWW { 3640 NMHDR hdr; 3641 UINT action; 3642 TVITEMW itemOld; 3643 TVITEMW itemNew; 3644 POINT ptDrag; 3645 } NMTREEVIEWW,*LPNMTREEVIEWW; 3646 3647 #define NMTREEVIEW __MINGW_NAME_AW(NMTREEVIEW) 3648 #define LPNMTREEVIEW __MINGW_NAME_AW(LPNMTREEVIEW) 3649 3650 #define TVN_SELCHANGINGA (TVN_FIRST-1) 3651 #define TVN_SELCHANGINGW (TVN_FIRST-50) 3652 #define TVN_SELCHANGEDA (TVN_FIRST-2) 3653 #define TVN_SELCHANGEDW (TVN_FIRST-51) 3654 3655 #define TVC_UNKNOWN 0x0 3656 #define TVC_BYMOUSE 0x1 3657 #define TVC_BYKEYBOARD 0x2 3658 3659 #define TVN_GETDISPINFOA (TVN_FIRST-3) 3660 #define TVN_GETDISPINFOW (TVN_FIRST-52) 3661 #define TVN_SETDISPINFOA (TVN_FIRST-4) 3662 #define TVN_SETDISPINFOW (TVN_FIRST-53) 3663 3664 #define TVIF_DI_SETITEM 0x1000 3665 3666 #define TV_DISPINFOA NMTVDISPINFOA 3667 #define TV_DISPINFOW NMTVDISPINFOW 3668 #define TV_DISPINFO NMTVDISPINFO 3669 3670 typedef struct tagTVDISPINFOA { 3671 NMHDR hdr; 3672 TVITEMA item; 3673 } NMTVDISPINFOA,*LPNMTVDISPINFOA; 3674 3675 typedef struct tagTVDISPINFOW { 3676 NMHDR hdr; 3677 TVITEMW item; 3678 } NMTVDISPINFOW,*LPNMTVDISPINFOW; 3679 3680 #define NMTVDISPINFO __MINGW_NAME_AW(NMTVDISPINFO) 3681 #define LPNMTVDISPINFO __MINGW_NAME_AW(LPNMTVDISPINFO) 3682 3683 #if (_WIN32_IE >= 0x0600) 3684 3685 typedef struct tagTVDISPINFOEXA { 3686 NMHDR hdr; 3687 TVITEMEXA item; 3688 } NMTVDISPINFOEXA, *LPNMTVDISPINFOEXA; 3689 3690 typedef struct tagTVDISPINFOEXW { 3691 NMHDR hdr; 3692 TVITEMEXW item; 3693 } NMTVDISPINFOEXW, *LPNMTVDISPINFOEXW; 3694 3695 #define NMTVDISPINFOEX __MINGW_NAME_AW(NMTVDISPINFOEX) 3696 #define LPNMTVDISPINFOEX __MINGW_NAME_AW(LPNMTVDISPINFOEX) 3697 3698 #define TV_DISPINFOEXA NMTVDISPINFOEXA 3699 #define TV_DISPINFOEXW NMTVDISPINFOEXW 3700 #define TV_DISPINFOEX NMTVDISPINFOEX 3701 3702 #endif /* (_WIN32_IE >= 0x0600) */ 3703 3704 #define TVN_ITEMEXPANDINGA (TVN_FIRST-5) 3705 #define TVN_ITEMEXPANDINGW (TVN_FIRST-54) 3706 #define TVN_ITEMEXPANDEDA (TVN_FIRST-6) 3707 #define TVN_ITEMEXPANDEDW (TVN_FIRST-55) 3708 #define TVN_BEGINDRAGA (TVN_FIRST-7) 3709 #define TVN_BEGINDRAGW (TVN_FIRST-56) 3710 #define TVN_BEGINRDRAGA (TVN_FIRST-8) 3711 #define TVN_BEGINRDRAGW (TVN_FIRST-57) 3712 #define TVN_DELETEITEMA (TVN_FIRST-9) 3713 #define TVN_DELETEITEMW (TVN_FIRST-58) 3714 #define TVN_BEGINLABELEDITA (TVN_FIRST-10) 3715 #define TVN_BEGINLABELEDITW (TVN_FIRST-59) 3716 #define TVN_ENDLABELEDITA (TVN_FIRST-11) 3717 #define TVN_ENDLABELEDITW (TVN_FIRST-60) 3718 #define TVN_KEYDOWN (TVN_FIRST-12) 3719 #define TVN_GETINFOTIPA (TVN_FIRST-13) 3720 #define TVN_GETINFOTIPW (TVN_FIRST-14) 3721 #define TVN_SINGLEEXPAND (TVN_FIRST-15) 3722 3723 #define TVNRET_DEFAULT 0 3724 #define TVNRET_SKIPOLD 1 3725 #define TVNRET_SKIPNEW 2 3726 3727 #define TV_KEYDOWN NMTVKEYDOWN 3728 3729 #include <pshpack1.h> 3730 3731 typedef struct tagTVKEYDOWN { 3732 NMHDR hdr; 3733 WORD wVKey; 3734 UINT flags; 3735 } NMTVKEYDOWN,*LPNMTVKEYDOWN; 3736 3737 #include <poppack.h> 3738 3739 #define TVN_SELCHANGING __MINGW_NAME_AW(TVN_SELCHANGING) 3740 #define TVN_SELCHANGED __MINGW_NAME_AW(TVN_SELCHANGED) 3741 #define TVN_GETDISPINFO __MINGW_NAME_AW(TVN_GETDISPINFO) 3742 #define TVN_SETDISPINFO __MINGW_NAME_AW(TVN_SETDISPINFO) 3743 #define TVN_ITEMEXPANDING __MINGW_NAME_AW(TVN_ITEMEXPANDING) 3744 #define TVN_ITEMEXPANDED __MINGW_NAME_AW(TVN_ITEMEXPANDED) 3745 #define TVN_BEGINDRAG __MINGW_NAME_AW(TVN_BEGINDRAG) 3746 #define TVN_BEGINRDRAG __MINGW_NAME_AW(TVN_BEGINRDRAG) 3747 #define TVN_DELETEITEM __MINGW_NAME_AW(TVN_DELETEITEM) 3748 #define TVN_BEGINLABELEDIT __MINGW_NAME_AW(TVN_BEGINLABELEDIT) 3749 #define TVN_ENDLABELEDIT __MINGW_NAME_AW(TVN_ENDLABELEDIT) 3750 3751 #define NMTVCUSTOMDRAW_V3_SIZE CCSIZEOF_STRUCT(NMTVCUSTOMDRAW,clrTextBk) 3752 3753 typedef struct tagNMTVCUSTOMDRAW { 3754 NMCUSTOMDRAW nmcd; 3755 COLORREF clrText; 3756 COLORREF clrTextBk; 3757 int iLevel; 3758 } NMTVCUSTOMDRAW,*LPNMTVCUSTOMDRAW; 3759 3760 typedef struct tagNMTVGETINFOTIPA { 3761 NMHDR hdr; 3762 LPSTR pszText; 3763 int cchTextMax; 3764 HTREEITEM hItem; 3765 LPARAM lParam; 3766 } NMTVGETINFOTIPA,*LPNMTVGETINFOTIPA; 3767 3768 typedef struct tagNMTVGETINFOTIPW { 3769 NMHDR hdr; 3770 LPWSTR pszText; 3771 int cchTextMax; 3772 HTREEITEM hItem; 3773 LPARAM lParam; 3774 } NMTVGETINFOTIPW,*LPNMTVGETINFOTIPW; 3775 3776 #define TVN_GETINFOTIP __MINGW_NAME_AW(TVN_GETINFOTIP) 3777 #define NMTVGETINFOTIP __MINGW_NAME_AW(NMTVGETINFOTIP) 3778 #define LPNMTVGETINFOTIP __MINGW_NAME_AW(LPNMTVGETINFOTIP) 3779 3780 #define TVCDRF_NOIMAGES 0x10000 3781 3782 #endif /* !NOTREEVIEW */ 3783 3784 #ifndef NOUSEREXCONTROLS 3785 3786 #define WC_COMBOBOXEXW L"ComboBoxEx32" 3787 #define WC_COMBOBOXEXA "ComboBoxEx32" 3788 3789 #define WC_COMBOBOXEX __MINGW_NAME_AW(WC_COMBOBOXEX) 3790 3791 #define CBEIF_TEXT 0x1 3792 #define CBEIF_IMAGE 0x2 3793 #define CBEIF_SELECTEDIMAGE 0x4 3794 #define CBEIF_OVERLAY 0x8 3795 #define CBEIF_INDENT 0x10 3796 #define CBEIF_LPARAM 0x20 3797 3798 #define CBEIF_DI_SETITEM 0x10000000 3799 3800 typedef struct tagCOMBOBOXEXITEMA { 3801 UINT mask; 3802 INT_PTR iItem; 3803 LPSTR pszText; 3804 int cchTextMax; 3805 int iImage; 3806 int iSelectedImage; 3807 int iOverlay; 3808 int iIndent; 3809 LPARAM lParam; 3810 } COMBOBOXEXITEMA,*PCOMBOBOXEXITEMA; 3811 typedef COMBOBOXEXITEMA CONST *PCCOMBOEXITEMA; 3812 3813 typedef struct tagCOMBOBOXEXITEMW 3814 { 3815 UINT mask; 3816 INT_PTR iItem; 3817 LPWSTR pszText; 3818 int cchTextMax; 3819 int iImage; 3820 int iSelectedImage; 3821 int iOverlay; 3822 int iIndent; 3823 LPARAM lParam; 3824 } COMBOBOXEXITEMW,*PCOMBOBOXEXITEMW; 3825 typedef COMBOBOXEXITEMW CONST *PCCOMBOEXITEMW; 3826 3827 #define COMBOBOXEXITEM __MINGW_NAME_AW(COMBOBOXEXITEM) 3828 #define PCOMBOBOXEXITEM __MINGW_NAME_AW(PCOMBOBOXEXITEM) 3829 #define PCCOMBOBOXEXITEM __MINGW_NAME_AW(PCCOMBOBOXEXITEM) 3830 3831 #define CBEM_INSERTITEMA (WM_USER+1) 3832 #define CBEM_SETIMAGELIST (WM_USER+2) 3833 #define CBEM_GETIMAGELIST (WM_USER+3) 3834 #define CBEM_GETITEMA (WM_USER+4) 3835 #define CBEM_SETITEMA (WM_USER+5) 3836 #define CBEM_DELETEITEM CB_DELETESTRING 3837 #define CBEM_GETCOMBOCONTROL (WM_USER+6) 3838 #define CBEM_GETEDITCONTROL (WM_USER+7) 3839 #define CBEM_SETEXSTYLE (WM_USER+8) 3840 #define CBEM_SETEXTENDEDSTYLE (WM_USER+14) 3841 #define CBEM_GETEXSTYLE (WM_USER+9) 3842 #define CBEM_GETEXTENDEDSTYLE (WM_USER+9) 3843 #define CBEM_SETUNICODEFORMAT CCM_SETUNICODEFORMAT 3844 #define CBEM_GETUNICODEFORMAT CCM_GETUNICODEFORMAT 3845 #define CBEM_HASEDITCHANGED (WM_USER+10) 3846 #define CBEM_INSERTITEMW (WM_USER+11) 3847 #define CBEM_SETITEMW (WM_USER+12) 3848 #define CBEM_GETITEMW (WM_USER+13) 3849 3850 #define CBEM_INSERTITEM __MINGW_NAME_AW(CBEM_INSERTITEM) 3851 #define CBEM_SETITEM __MINGW_NAME_AW(CBEM_SETITEM) 3852 #define CBEM_GETITEM __MINGW_NAME_AW(CBEM_GETITEM) 3853 3854 #define CBEM_SETWINDOWTHEME CCM_SETWINDOWTHEME 3855 3856 #define CBES_EX_NOEDITIMAGE 0x1 3857 #define CBES_EX_NOEDITIMAGEINDENT 0x2 3858 #define CBES_EX_PATHWORDBREAKPROC 0x4 3859 #define CBES_EX_NOSIZELIMIT 0x8 3860 #define CBES_EX_CASESENSITIVE 0x10 3861 3862 typedef struct { 3863 NMHDR hdr; 3864 COMBOBOXEXITEMA ceItem; 3865 } NMCOMBOBOXEXA,*PNMCOMBOBOXEXA; 3866 3867 typedef struct { 3868 NMHDR hdr; 3869 COMBOBOXEXITEMW ceItem; 3870 } NMCOMBOBOXEXW,*PNMCOMBOBOXEXW; 3871 3872 #define NMCOMBOBOXEX __MINGW_NAME_AW(NMCOMBOBOXEX) 3873 #define PNMCOMBOBOXEX __MINGW_NAME_AW(PNMCOMBOBOXEX) 3874 #define CBEN_GETDISPINFO __MINGW_NAME_AW(CBEN_GETDISPINFO) 3875 3876 #define CBEN_GETDISPINFOA (CBEN_FIRST - 0) 3877 #define CBEN_INSERTITEM (CBEN_FIRST - 1) 3878 #define CBEN_DELETEITEM (CBEN_FIRST - 2) 3879 #define CBEN_BEGINEDIT (CBEN_FIRST - 4) 3880 #define CBEN_ENDEDITA (CBEN_FIRST - 5) 3881 #define CBEN_ENDEDITW (CBEN_FIRST - 6) 3882 3883 #define CBEN_GETDISPINFOW (CBEN_FIRST - 7) 3884 3885 #define CBEN_DRAGBEGINA (CBEN_FIRST - 8) 3886 #define CBEN_DRAGBEGINW (CBEN_FIRST - 9) 3887 3888 #define CBEN_DRAGBEGIN __MINGW_NAME_AW(CBEN_DRAGBEGIN) 3889 3890 #define CBEN_ENDEDIT __MINGW_NAME_AW(CBEN_ENDEDIT) 3891 3892 #define CBENF_KILLFOCUS 1 3893 #define CBENF_RETURN 2 3894 #define CBENF_ESCAPE 3 3895 #define CBENF_DROPDOWN 4 3896 3897 #define CBEMAXSTRLEN 260 3898 3899 typedef struct { 3900 NMHDR hdr; 3901 int iItemid; 3902 WCHAR szText[CBEMAXSTRLEN]; 3903 }NMCBEDRAGBEGINW,*LPNMCBEDRAGBEGINW,*PNMCBEDRAGBEGINW; 3904 3905 typedef struct { 3906 NMHDR hdr; 3907 int iItemid; 3908 char szText[CBEMAXSTRLEN]; 3909 }NMCBEDRAGBEGINA,*LPNMCBEDRAGBEGINA,*PNMCBEDRAGBEGINA; 3910 3911 #define NMCBEDRAGBEGIN __MINGW_NAME_AW(NMCBEDRAGBEGIN) 3912 #define LPNMCBEDRAGBEGIN __MINGW_NAME_AW(LPNMCBEDRAGBEGIN) 3913 #define PNMCBEDRAGBEGIN __MINGW_NAME_AW(PNMCBEDRAGBEGIN) 3914 3915 typedef struct { 3916 NMHDR hdr; 3917 BOOL fChanged; 3918 int iNewSelection; 3919 WCHAR szText[CBEMAXSTRLEN]; 3920 int iWhy; 3921 } NMCBEENDEDITW,*LPNMCBEENDEDITW,*PNMCBEENDEDITW; 3922 3923 typedef struct { 3924 NMHDR hdr; 3925 BOOL fChanged; 3926 int iNewSelection; 3927 char szText[CBEMAXSTRLEN]; 3928 int iWhy; 3929 } NMCBEENDEDITA,*LPNMCBEENDEDITA,*PNMCBEENDEDITA; 3930 3931 #define NMCBEENDEDIT __MINGW_NAME_AW(NMCBEENDEDIT) 3932 #define LPNMCBEENDEDIT __MINGW_NAME_AW(LPNMCBEENDEDIT) 3933 #define PNMCBEENDEDIT __MINGW_NAME_AW(PNMCBEENDEDIT) 3934 3935 #endif /* !NOUSEREXCONTROLS */ 3936 3937 #ifndef NOTABCONTROL 3938 3939 #define WC_TABCONTROLA "SysTabControl32" 3940 #define WC_TABCONTROLW L"SysTabControl32" 3941 #define WC_TABCONTROL __MINGW_NAME_AW(WC_TABCONTROL) 3942 3943 #define TCS_SCROLLOPPOSITE 0x1 3944 #define TCS_BOTTOM 0x2 3945 #define TCS_RIGHT 0x2 3946 #define TCS_MULTISELECT 0x4 3947 #define TCS_FLATBUTTONS 0x8 3948 #define TCS_FORCEICONLEFT 0x10 3949 #define TCS_FORCELABELLEFT 0x20 3950 #define TCS_HOTTRACK 0x40 3951 #define TCS_VERTICAL 0x80 3952 #define TCS_TABS 0x0 3953 #define TCS_BUTTONS 0x100 3954 #define TCS_SINGLELINE 0x0 3955 #define TCS_MULTILINE 0x200 3956 #define TCS_RIGHTJUSTIFY 0x0 3957 #define TCS_FIXEDWIDTH 0x400 3958 #define TCS_RAGGEDRIGHT 0x800 3959 #define TCS_FOCUSONBUTTONDOWN 0x1000 3960 #define TCS_OWNERDRAWFIXED 0x2000 3961 #define TCS_TOOLTIPS 0x4000 3962 #define TCS_FOCUSNEVER 0x8000 3963 3964 #define TCS_EX_FLATSEPARATORS 0x1 3965 #define TCS_EX_REGISTERDROP 0x2 3966 3967 #define TCM_GETIMAGELIST (TCM_FIRST+2) 3968 #define TabCtrl_GetImageList(hwnd) (HIMAGELIST)SNDMSG((hwnd),TCM_GETIMAGELIST,0,0L) 3969 3970 #define TCM_SETIMAGELIST (TCM_FIRST+3) 3971 #define TabCtrl_SetImageList(hwnd,himl) (HIMAGELIST)SNDMSG((hwnd),TCM_SETIMAGELIST,0,(LPARAM)(HIMAGELIST)(himl)) 3972 3973 #define TCM_GETITEMCOUNT (TCM_FIRST+4) 3974 #define TabCtrl_GetItemCount(hwnd) (int)SNDMSG((hwnd),TCM_GETITEMCOUNT,0,0L) 3975 3976 #define TCIF_TEXT 0x1 3977 #define TCIF_IMAGE 0x2 3978 #define TCIF_RTLREADING 0x4 3979 #define TCIF_PARAM 0x8 3980 #define TCIF_STATE 0x10 3981 3982 #define TCIS_BUTTONPRESSED 0x1 3983 #define TCIS_HIGHLIGHTED 0x2 3984 3985 #define TC_ITEMHEADERA TCITEMHEADERA 3986 #define TC_ITEMHEADERW TCITEMHEADERW 3987 #define TC_ITEMHEADER TCITEMHEADER 3988 3989 typedef struct tagTCITEMHEADERA { 3990 UINT mask; 3991 UINT lpReserved1; 3992 UINT lpReserved2; 3993 LPSTR pszText; 3994 int cchTextMax; 3995 int iImage; 3996 } TCITEMHEADERA,*LPTCITEMHEADERA; 3997 3998 typedef struct tagTCITEMHEADERW { 3999 UINT mask; 4000 UINT lpReserved1; 4001 UINT lpReserved2; 4002 LPWSTR pszText; 4003 int cchTextMax; 4004 int iImage; 4005 } TCITEMHEADERW,*LPTCITEMHEADERW; 4006 4007 #define TCITEMHEADER __MINGW_NAME_AW(TCITEMHEADER) 4008 #define LPTCITEMHEADER __MINGW_NAME_AW(LPTCITEMHEADER) 4009 4010 #define TC_ITEMA TCITEMA 4011 #define TC_ITEMW TCITEMW 4012 #define TC_ITEM TCITEM 4013 4014 typedef struct tagTCITEMA { 4015 UINT mask; 4016 DWORD dwState; 4017 DWORD dwStateMask; 4018 LPSTR pszText; 4019 int cchTextMax; 4020 int iImage; 4021 LPARAM lParam; 4022 } TCITEMA,*LPTCITEMA; 4023 4024 typedef struct tagTCITEMW { 4025 UINT mask; 4026 DWORD dwState; 4027 DWORD dwStateMask; 4028 LPWSTR pszText; 4029 int cchTextMax; 4030 int iImage; 4031 LPARAM lParam; 4032 } TCITEMW,*LPTCITEMW; 4033 4034 #define TCITEM __MINGW_NAME_AW(TCITEM) 4035 #define LPTCITEM __MINGW_NAME_AW(LPTCITEM) 4036 4037 #define TCM_GETITEMA (TCM_FIRST+5) 4038 #define TCM_GETITEMW (TCM_FIRST+60) 4039 4040 #define TCM_GETITEM __MINGW_NAME_AW(TCM_GETITEM) 4041 4042 #define TabCtrl_GetItem(hwnd,iItem,pitem) (BOOL)SNDMSG((hwnd),TCM_GETITEM,(WPARAM)(int)(iItem),(LPARAM)(TC_ITEM *)(pitem)) 4043 4044 #define TCM_SETITEMA (TCM_FIRST+6) 4045 #define TCM_SETITEMW (TCM_FIRST+61) 4046 4047 #define TCM_SETITEM __MINGW_NAME_AW(TCM_SETITEM) 4048 4049 #define TabCtrl_SetItem(hwnd,iItem,pitem) (BOOL)SNDMSG((hwnd),TCM_SETITEM,(WPARAM)(int)(iItem),(LPARAM)(TC_ITEM *)(pitem)) 4050 4051 #define TCM_INSERTITEMA (TCM_FIRST+7) 4052 #define TCM_INSERTITEMW (TCM_FIRST+62) 4053 4054 #define TCM_INSERTITEM __MINGW_NAME_AW(TCM_INSERTITEM) 4055 4056 #define TabCtrl_InsertItem(hwnd,iItem,pitem) (int)SNDMSG((hwnd),TCM_INSERTITEM,(WPARAM)(int)(iItem),(LPARAM)(const TC_ITEM *)(pitem)) 4057 4058 #define TCM_DELETEITEM (TCM_FIRST+8) 4059 #define TabCtrl_DeleteItem(hwnd,i) (BOOL)SNDMSG((hwnd),TCM_DELETEITEM,(WPARAM)(int)(i),0L) 4060 4061 #define TCM_DELETEALLITEMS (TCM_FIRST+9) 4062 #define TabCtrl_DeleteAllItems(hwnd) (BOOL)SNDMSG((hwnd),TCM_DELETEALLITEMS,0,0L) 4063 4064 #define TCM_GETITEMRECT (TCM_FIRST+10) 4065 #define TabCtrl_GetItemRect(hwnd,i,prc) (BOOL)SNDMSG((hwnd),TCM_GETITEMRECT,(WPARAM)(int)(i),(LPARAM)(RECT *)(prc)) 4066 4067 #define TCM_GETCURSEL (TCM_FIRST+11) 4068 #define TabCtrl_GetCurSel(hwnd) (int)SNDMSG((hwnd),TCM_GETCURSEL,0,0) 4069 4070 #define TCM_SETCURSEL (TCM_FIRST+12) 4071 #define TabCtrl_SetCurSel(hwnd,i) (int)SNDMSG((hwnd),TCM_SETCURSEL,(WPARAM)(i),0) 4072 4073 #define TCHT_NOWHERE 0x1 4074 #define TCHT_ONITEMICON 0x2 4075 #define TCHT_ONITEMLABEL 0x4 4076 #define TCHT_ONITEM (TCHT_ONITEMICON | TCHT_ONITEMLABEL) 4077 4078 #define LPTC_HITTESTINFO LPTCHITTESTINFO 4079 #define TC_HITTESTINFO TCHITTESTINFO 4080 4081 typedef struct tagTCHITTESTINFO { 4082 POINT pt; 4083 UINT flags; 4084 } TCHITTESTINFO,*LPTCHITTESTINFO; 4085 4086 #define TCM_HITTEST (TCM_FIRST+13) 4087 #define TabCtrl_HitTest(hwndTC,pinfo) (int)SNDMSG((hwndTC),TCM_HITTEST,0,(LPARAM)(TC_HITTESTINFO *)(pinfo)) 4088 #define TCM_SETITEMEXTRA (TCM_FIRST+14) 4089 #define TabCtrl_SetItemExtra(hwndTC,cb) (BOOL)SNDMSG((hwndTC),TCM_SETITEMEXTRA,(WPARAM)(cb),0L) 4090 #define TCM_ADJUSTRECT (TCM_FIRST+40) 4091 #define TabCtrl_AdjustRect(hwnd,bLarger,prc) (int)SNDMSG(hwnd,TCM_ADJUSTRECT,(WPARAM)(BOOL)(bLarger),(LPARAM)(RECT *)prc) 4092 #define TCM_SETITEMSIZE (TCM_FIRST+41) 4093 #define TabCtrl_SetItemSize(hwnd,x,y) (DWORD)SNDMSG((hwnd),TCM_SETITEMSIZE,0,MAKELPARAM(x,y)) 4094 #define TCM_REMOVEIMAGE (TCM_FIRST+42) 4095 #define TabCtrl_RemoveImage(hwnd,i) (void)SNDMSG((hwnd),TCM_REMOVEIMAGE,i,0L) 4096 #define TCM_SETPADDING (TCM_FIRST+43) 4097 #define TabCtrl_SetPadding(hwnd,cx,cy) (void)SNDMSG((hwnd),TCM_SETPADDING,0,MAKELPARAM(cx,cy)) 4098 #define TCM_GETROWCOUNT (TCM_FIRST+44) 4099 #define TabCtrl_GetRowCount(hwnd) (int)SNDMSG((hwnd),TCM_GETROWCOUNT,0,0L) 4100 #define TCM_GETTOOLTIPS (TCM_FIRST+45) 4101 #define TabCtrl_GetToolTips(hwnd) (HWND)SNDMSG((hwnd),TCM_GETTOOLTIPS,0,0L) 4102 #define TCM_SETTOOLTIPS (TCM_FIRST+46) 4103 #define TabCtrl_SetToolTips(hwnd,hwndTT) (void)SNDMSG((hwnd),TCM_SETTOOLTIPS,(WPARAM)(hwndTT),0L) 4104 #define TCM_GETCURFOCUS (TCM_FIRST+47) 4105 #define TabCtrl_GetCurFocus(hwnd) (int)SNDMSG((hwnd),TCM_GETCURFOCUS,0,0) 4106 #define TCM_SETCURFOCUS (TCM_FIRST+48) 4107 #define TabCtrl_SetCurFocus(hwnd,i) SNDMSG((hwnd),TCM_SETCURFOCUS,i,0) 4108 #define TCM_SETMINTABWIDTH (TCM_FIRST+49) 4109 #define TabCtrl_SetMinTabWidth(hwnd,x) (int)SNDMSG((hwnd),TCM_SETMINTABWIDTH,0,x) 4110 #define TCM_DESELECTALL (TCM_FIRST+50) 4111 #define TabCtrl_DeselectAll(hwnd,fExcludeFocus) (void)SNDMSG((hwnd),TCM_DESELECTALL,fExcludeFocus,0) 4112 #define TCM_HIGHLIGHTITEM (TCM_FIRST+51) 4113 #define TabCtrl_HighlightItem(hwnd,i,fHighlight) (BOOL)SNDMSG((hwnd),TCM_HIGHLIGHTITEM,(WPARAM)(i),(LPARAM)MAKELONG (fHighlight,0)) 4114 #define TCM_SETEXTENDEDSTYLE (TCM_FIRST+52) 4115 #define TabCtrl_SetExtendedStyle(hwnd,dw) (DWORD)SNDMSG((hwnd),TCM_SETEXTENDEDSTYLE,0,dw) 4116 #define TCM_GETEXTENDEDSTYLE (TCM_FIRST+53) 4117 #define TabCtrl_GetExtendedStyle(hwnd) (DWORD)SNDMSG((hwnd),TCM_GETEXTENDEDSTYLE,0,0) 4118 #define TCM_SETUNICODEFORMAT CCM_SETUNICODEFORMAT 4119 #define TabCtrl_SetUnicodeFormat(hwnd,fUnicode) (BOOL)SNDMSG((hwnd),TCM_SETUNICODEFORMAT,(WPARAM)(fUnicode),0) 4120 #define TCM_GETUNICODEFORMAT CCM_GETUNICODEFORMAT 4121 #define TabCtrl_GetUnicodeFormat(hwnd) (BOOL)SNDMSG((hwnd),TCM_GETUNICODEFORMAT,0,0) 4122 4123 #define TCN_KEYDOWN (TCN_FIRST - 0) 4124 4125 #define TC_KEYDOWN NMTCKEYDOWN 4126 4127 #include <pshpack1.h> 4128 4129 typedef struct tagTCKEYDOWN { 4130 NMHDR hdr; 4131 WORD wVKey; 4132 UINT flags; 4133 } NMTCKEYDOWN; 4134 4135 #include <poppack.h> 4136 4137 #define TCN_SELCHANGE (TCN_FIRST - 1) 4138 #define TCN_SELCHANGING (TCN_FIRST - 2) 4139 #define TCN_GETOBJECT (TCN_FIRST - 3) 4140 #define TCN_FOCUSCHANGE (TCN_FIRST - 4) 4141 4142 #endif /* !NOTABCONTROL */ 4143 4144 #ifndef NOANIMATE 4145 4146 #define ANIMATE_CLASSW L"SysAnimate32" 4147 #define ANIMATE_CLASSA "SysAnimate32" 4148 4149 #define ANIMATE_CLASS __MINGW_NAME_AW(ANIMATE_CLASS) 4150 4151 #define ACS_CENTER 0x1 4152 #define ACS_TRANSPARENT 0x2 4153 #define ACS_AUTOPLAY 0x4 4154 #define ACS_TIMER 0x8 4155 4156 #define ACM_OPENA (WM_USER+100) 4157 #define ACM_OPENW (WM_USER+103) 4158 4159 #define ACM_OPEN __MINGW_NAME_AW(ACM_OPEN) 4160 4161 #define ACM_PLAY (WM_USER+101) 4162 #define ACM_STOP (WM_USER+102) 4163 4164 #define ACN_START 1 4165 #define ACN_STOP 2 4166 4167 #define Animate_Create(hwndP,id,dwStyle,hInstance) CreateWindow(ANIMATE_CLASS,NULL,dwStyle,0,0,0,0,hwndP,(HMENU)(id),hInstance,NULL) 4168 4169 #define Animate_Open(hwnd,szName) (BOOL)SNDMSG(hwnd,ACM_OPEN,0,(LPARAM)(LPTSTR)(szName)) 4170 #define Animate_OpenEx(hwnd,hInst,szName) (BOOL)SNDMSG(hwnd,ACM_OPEN,(WPARAM)(hInst),(LPARAM)(LPTSTR)(szName)) 4171 #define Animate_Play(hwnd,from,to,rep) (BOOL)SNDMSG(hwnd,ACM_PLAY,(WPARAM)(rep),(LPARAM)MAKELONG(from,to)) 4172 #define Animate_Stop(hwnd) (BOOL)SNDMSG(hwnd,ACM_STOP,0,0) 4173 #define Animate_Close(hwnd) Animate_Open(hwnd,NULL) 4174 #define Animate_Seek(hwnd,frame) Animate_Play(hwnd,frame,frame,1) 4175 4176 #endif /* !NOANIMATE */ 4177 4178 #ifndef NOMONTHCAL 4179 4180 #define MONTHCAL_CLASSW L"SysMonthCal32" 4181 #define MONTHCAL_CLASSA "SysMonthCal32" 4182 4183 #define MONTHCAL_CLASS __MINGW_NAME_AW(MONTHCAL_CLASS) 4184 4185 typedef DWORD MONTHDAYSTATE,*LPMONTHDAYSTATE; 4186 4187 #define MCM_FIRST 0x1000 4188 4189 #define MCM_GETCURSEL (MCM_FIRST+1) 4190 #define MonthCal_GetCurSel(hmc,pst) (BOOL)SNDMSG(hmc,MCM_GETCURSEL,0,(LPARAM)(pst)) 4191 #define MCM_SETCURSEL (MCM_FIRST+2) 4192 #define MonthCal_SetCurSel(hmc,pst) (BOOL)SNDMSG(hmc,MCM_SETCURSEL,0,(LPARAM)(pst)) 4193 #define MCM_GETMAXSELCOUNT (MCM_FIRST+3) 4194 #define MonthCal_GetMaxSelCount(hmc) (DWORD)SNDMSG(hmc,MCM_GETMAXSELCOUNT,0,0L) 4195 #define MCM_SETMAXSELCOUNT (MCM_FIRST+4) 4196 #define MonthCal_SetMaxSelCount(hmc,n) (BOOL)SNDMSG(hmc,MCM_SETMAXSELCOUNT,(WPARAM)(n),0L) 4197 #define MCM_GETSELRANGE (MCM_FIRST+5) 4198 #define MonthCal_GetSelRange(hmc,rgst) SNDMSG(hmc,MCM_GETSELRANGE,0,(LPARAM)(rgst)) 4199 #define MCM_SETSELRANGE (MCM_FIRST+6) 4200 #define MonthCal_SetSelRange(hmc,rgst) SNDMSG(hmc,MCM_SETSELRANGE,0,(LPARAM)(rgst)) 4201 #define MCM_GETMONTHRANGE (MCM_FIRST+7) 4202 #define MonthCal_GetMonthRange(hmc,gmr,rgst) (DWORD)SNDMSG(hmc,MCM_GETMONTHRANGE,(WPARAM)(gmr),(LPARAM)(rgst)) 4203 #define MCM_SETDAYSTATE (MCM_FIRST+8) 4204 #define MonthCal_SetDayState(hmc,cbds,rgds) SNDMSG(hmc,MCM_SETDAYSTATE,(WPARAM)(cbds),(LPARAM)(rgds)) 4205 #define MCM_GETMINREQRECT (MCM_FIRST+9) 4206 #define MonthCal_GetMinReqRect(hmc,prc) SNDMSG(hmc,MCM_GETMINREQRECT,0,(LPARAM)(prc)) 4207 #define MCM_SETCOLOR (MCM_FIRST+10) 4208 #define MonthCal_SetColor(hmc,iColor,clr) SNDMSG(hmc,MCM_SETCOLOR,iColor,clr) 4209 #define MCM_GETCOLOR (MCM_FIRST+11) 4210 #define MonthCal_GetColor(hmc,iColor) SNDMSG(hmc,MCM_GETCOLOR,iColor,0) 4211 4212 #define MCSC_BACKGROUND 0 4213 #define MCSC_TEXT 1 4214 #define MCSC_TITLEBK 2 4215 #define MCSC_TITLETEXT 3 4216 #define MCSC_MONTHBK 4 4217 #define MCSC_TRAILINGTEXT 5 4218 4219 #define MCM_SETTODAY (MCM_FIRST+12) 4220 #define MonthCal_SetToday(hmc,pst) SNDMSG(hmc,MCM_SETTODAY,0,(LPARAM)(pst)) 4221 #define MCM_GETTODAY (MCM_FIRST+13) 4222 #define MonthCal_GetToday(hmc,pst) (BOOL)SNDMSG(hmc,MCM_GETTODAY,0,(LPARAM)(pst)) 4223 #define MCM_HITTEST (MCM_FIRST+14) 4224 #define MonthCal_HitTest(hmc,pinfo) SNDMSG(hmc,MCM_HITTEST,0,(LPARAM)(PMCHITTESTINFO)(pinfo)) 4225 4226 typedef struct { 4227 UINT cbSize; 4228 POINT pt; 4229 UINT uHit; 4230 SYSTEMTIME st; 4231 #if(NTDDI_VERSION >= NTDDI_VISTA) 4232 RECT rc; 4233 int iOffset; 4234 int iRow; 4235 int iCol; 4236 #endif 4237 } MCHITTESTINFO, *PMCHITTESTINFO; 4238 4239 #define MCHITTESTINFO_V1_SIZE CCSIZEOF_STRUCT(MCHITTESTINFO, st) 4240 4241 #define MCHT_TITLE 0x10000 4242 #define MCHT_CALENDAR 0x20000 4243 #define MCHT_TODAYLINK 0x30000 4244 4245 #define MCHT_NEXT 0x1000000 4246 #define MCHT_PREV 0x2000000 4247 4248 #define MCHT_NOWHERE 0x0 4249 4250 #define MCHT_TITLEBK (MCHT_TITLE) 4251 #define MCHT_TITLEMONTH (MCHT_TITLE | 0x1) 4252 #define MCHT_TITLEYEAR (MCHT_TITLE | 0x2) 4253 #define MCHT_TITLEBTNNEXT (MCHT_TITLE | MCHT_NEXT | 0x3) 4254 #define MCHT_TITLEBTNPREV (MCHT_TITLE | MCHT_PREV | 0x3) 4255 4256 #define MCHT_CALENDARBK (MCHT_CALENDAR) 4257 #define MCHT_CALENDARDATE (MCHT_CALENDAR | 0x1) 4258 #define MCHT_CALENDARDATENEXT (MCHT_CALENDARDATE | MCHT_NEXT) 4259 #define MCHT_CALENDARDATEPREV (MCHT_CALENDARDATE | MCHT_PREV) 4260 #define MCHT_CALENDARDAY (MCHT_CALENDAR | 0x2) 4261 #define MCHT_CALENDARWEEKNUM (MCHT_CALENDAR | 0x3) 4262 4263 #define MCM_SETFIRSTDAYOFWEEK (MCM_FIRST+15) 4264 #define MonthCal_SetFirstDayOfWeek(hmc,iDay) SNDMSG(hmc,MCM_SETFIRSTDAYOFWEEK,0,iDay) 4265 #define MCM_GETFIRSTDAYOFWEEK (MCM_FIRST+16) 4266 #define MonthCal_GetFirstDayOfWeek(hmc) (DWORD)SNDMSG(hmc,MCM_GETFIRSTDAYOFWEEK,0,0) 4267 #define MCM_GETRANGE (MCM_FIRST+17) 4268 #define MonthCal_GetRange(hmc,rgst) (DWORD)SNDMSG(hmc,MCM_GETRANGE,0,(LPARAM)(rgst)) 4269 #define MCM_SETRANGE (MCM_FIRST+18) 4270 #define MonthCal_SetRange(hmc,gd,rgst) (BOOL)SNDMSG(hmc,MCM_SETRANGE,(WPARAM)(gd),(LPARAM)(rgst)) 4271 #define MCM_GETMONTHDELTA (MCM_FIRST+19) 4272 #define MonthCal_GetMonthDelta(hmc) (int)SNDMSG(hmc,MCM_GETMONTHDELTA,0,0) 4273 #define MCM_SETMONTHDELTA (MCM_FIRST+20) 4274 #define MonthCal_SetMonthDelta(hmc,n) (int)SNDMSG(hmc,MCM_SETMONTHDELTA,n,0) 4275 #define MCM_GETMAXTODAYWIDTH (MCM_FIRST+21) 4276 #define MonthCal_GetMaxTodayWidth(hmc) (DWORD)SNDMSG(hmc,MCM_GETMAXTODAYWIDTH,0,0) 4277 #define MCM_GETCURRENTVIEW (MCM_FIRST + 22) 4278 #define MonthCal_GetCurrentView(hmc) (DWORD)SNDMSG(hmc, MCM_GETCURRENTVIEW, 0, 0) 4279 #define MCM_GETCALENDARCOUNT (MCM_FIRST + 23) 4280 #define MonthCal_GetCalendarCount(hmc) (DWORD)SNDMSG(hmc, MCM_GETCALENDARCOUNT, 0, 0) 4281 #define MCM_SETUNICODEFORMAT CCM_SETUNICODEFORMAT 4282 #define MonthCal_SetUnicodeFormat(hwnd,fUnicode) (BOOL)SNDMSG((hwnd),MCM_SETUNICODEFORMAT,(WPARAM)(fUnicode),0) 4283 #define MCM_GETUNICODEFORMAT CCM_GETUNICODEFORMAT 4284 #define MonthCal_GetUnicodeFormat(hwnd) (BOOL)SNDMSG((hwnd),MCM_GETUNICODEFORMAT,0,0) 4285 #define MCM_SIZERECTTOMIN (MCM_FIRST + 29) 4286 #define MonthCal_SizeRectToMin(hmc, prc) SNDMSG(hmc, MCM_SIZERECTTOMIN, 0, (LPARAM)(prc)) 4287 #define MCM_SETCALENDARBORDER (MCM_FIRST + 30) 4288 #define MCM_GETCALENDARBORDER (MCM_FIRST + 31) 4289 4290 typedef struct tagNMSELCHANGE { 4291 NMHDR nmhdr; 4292 SYSTEMTIME stSelStart; 4293 SYSTEMTIME stSelEnd; 4294 } NMSELCHANGE,*LPNMSELCHANGE; 4295 4296 #define MCN_SELCHANGE (MCN_FIRST+1) 4297 4298 typedef struct tagNMDAYSTATE { 4299 NMHDR nmhdr; 4300 SYSTEMTIME stStart; 4301 int cDayState; 4302 4303 LPMONTHDAYSTATE prgDayState; 4304 } NMDAYSTATE,*LPNMDAYSTATE; 4305 4306 #define MCN_GETDAYSTATE (MCN_FIRST+3) 4307 4308 typedef NMSELCHANGE NMSELECT,*LPNMSELECT; 4309 4310 #define MCN_SELECT (MCN_FIRST+4) 4311 4312 #define MCS_DAYSTATE 0x0001 4313 #define MCS_MULTISELECT 0x0002 4314 #define MCS_WEEKNUMBERS 0x0004 4315 #define MCS_NOTODAYCIRCLE 0x0008 4316 #define MCS_NOTODAY 0x0010 4317 #define MCS_NOTRAILINGDATES 0x0040 4318 #define MCS_SHORTDAYSOFWEEK 0x0080 4319 4320 #define GMR_VISIBLE 0 4321 #define GMR_DAYSTATE 1 4322 4323 #endif /* !NOMONTHCAL */ 4324 4325 #ifndef NODATETIMEPICK 4326 4327 #define DATETIMEPICK_CLASSW L"SysDateTimePick32" 4328 #define DATETIMEPICK_CLASSA "SysDateTimePick32" 4329 4330 #define DATETIMEPICK_CLASS __MINGW_NAME_AW(DATETIMEPICK_CLASS) 4331 4332 #define DTM_FIRST 0x1000 4333 4334 #define DTM_GETSYSTEMTIME (DTM_FIRST+1) 4335 #define DateTime_GetSystemtime(hdp,pst) (DWORD)SNDMSG(hdp,DTM_GETSYSTEMTIME,0,(LPARAM)(pst)) 4336 #define DTM_SETSYSTEMTIME (DTM_FIRST+2) 4337 #define DateTime_SetSystemtime(hdp,gd,pst) (BOOL)SNDMSG(hdp,DTM_SETSYSTEMTIME,(WPARAM)(gd),(LPARAM)(pst)) 4338 #define DTM_GETRANGE (DTM_FIRST+3) 4339 #define DateTime_GetRange(hdp,rgst) (DWORD)SNDMSG(hdp,DTM_GETRANGE,0,(LPARAM)(rgst)) 4340 #define DTM_SETRANGE (DTM_FIRST+4) 4341 #define DateTime_SetRange(hdp,gd,rgst) (BOOL)SNDMSG(hdp,DTM_SETRANGE,(WPARAM)(gd),(LPARAM)(rgst)) 4342 #define DTM_SETFORMATA (DTM_FIRST+5) 4343 #define DTM_SETFORMATW (DTM_FIRST+50) 4344 4345 #define DTM_SETFORMAT __MINGW_NAME_AW(DTM_SETFORMAT) 4346 4347 #define DateTime_SetFormat(hdp,sz) (BOOL)SNDMSG(hdp,DTM_SETFORMAT,0,(LPARAM)(sz)) 4348 4349 #define DTM_SETMCCOLOR (DTM_FIRST+6) 4350 #define DateTime_SetMonthCalColor(hdp,iColor,clr) SNDMSG(hdp,DTM_SETMCCOLOR,iColor,clr) 4351 #define DTM_GETMCCOLOR (DTM_FIRST+7) 4352 #define DateTime_GetMonthCalColor(hdp,iColor) SNDMSG(hdp,DTM_GETMCCOLOR,iColor,0) 4353 #define DTM_GETMONTHCAL (DTM_FIRST+8) 4354 #define DateTime_GetMonthCal(hdp) (HWND)SNDMSG(hdp,DTM_GETMONTHCAL,0,0) 4355 #define DTM_SETMCFONT (DTM_FIRST+9) 4356 #define DateTime_SetMonthCalFont(hdp,hfont,fRedraw) SNDMSG(hdp,DTM_SETMCFONT,(WPARAM)(hfont),(LPARAM)(fRedraw)) 4357 #define DTM_GETMCFONT (DTM_FIRST+10) 4358 #define DateTime_GetMonthCalFont(hdp) SNDMSG(hdp,DTM_GETMCFONT,0,0) 4359 4360 #define DTM_GETIDEALSIZE (DTM_FIRST+15) 4361 4362 #define DTS_UPDOWN 0x1 4363 #define DTS_SHOWNONE 0x2 4364 #define DTS_SHORTDATEFORMAT 0x0 4365 #define DTS_LONGDATEFORMAT 0x4 4366 #define DTS_SHORTDATECENTURYFORMAT 0xc 4367 #define DTS_TIMEFORMAT 0x9 4368 #define DTS_APPCANPARSE 0x10 4369 #define DTS_RIGHTALIGN 0x20 4370 4371 #define DTN_DATETIMECHANGE (DTN_FIRST+1) 4372 typedef struct tagNMDATETIMECHANGE { 4373 NMHDR nmhdr; 4374 DWORD dwFlags; 4375 SYSTEMTIME st; 4376 } NMDATETIMECHANGE,*LPNMDATETIMECHANGE; 4377 4378 #define DTN_USERSTRINGA (DTN_FIRST+2) 4379 #define DTN_USERSTRINGW (DTN_FIRST+15) 4380 typedef struct tagNMDATETIMESTRINGA { 4381 NMHDR nmhdr; 4382 LPCSTR pszUserString; 4383 SYSTEMTIME st; 4384 DWORD dwFlags; 4385 } NMDATETIMESTRINGA,*LPNMDATETIMESTRINGA; 4386 4387 typedef struct tagNMDATETIMESTRINGW { 4388 NMHDR nmhdr; 4389 LPCWSTR pszUserString; 4390 SYSTEMTIME st; 4391 DWORD dwFlags; 4392 } NMDATETIMESTRINGW,*LPNMDATETIMESTRINGW; 4393 4394 #define DTN_USERSTRING __MINGW_NAME_AW(DTN_USERSTRING) 4395 #define NMDATETIMESTRING __MINGW_NAME_AW(NMDATETIMESTRING) 4396 #define LPNMDATETIMESTRING __MINGW_NAME_AW(LPNMDATETIMESTRING) 4397 4398 #define DTN_WMKEYDOWNA (DTN_FIRST+3) 4399 #define DTN_WMKEYDOWNW (DTN_FIRST+16) 4400 typedef struct tagNMDATETIMEWMKEYDOWNA { 4401 NMHDR nmhdr; 4402 int nVirtKey; 4403 LPCSTR pszFormat; 4404 SYSTEMTIME st; 4405 } NMDATETIMEWMKEYDOWNA,*LPNMDATETIMEWMKEYDOWNA; 4406 4407 typedef struct tagNMDATETIMEWMKEYDOWNW { 4408 NMHDR nmhdr; 4409 int nVirtKey; 4410 LPCWSTR pszFormat; 4411 SYSTEMTIME st; 4412 } NMDATETIMEWMKEYDOWNW,*LPNMDATETIMEWMKEYDOWNW; 4413 4414 #define DTN_WMKEYDOWN __MINGW_NAME_AW(DTN_WMKEYDOWN) 4415 #define NMDATETIMEWMKEYDOWN __MINGW_NAME_AW(NMDATETIMEWMKEYDOWN) 4416 #define LPNMDATETIMEWMKEYDOWN __MINGW_NAME_AW(LPNMDATETIMEWMKEYDOWN) 4417 4418 #define DTN_FORMATA (DTN_FIRST+4) 4419 #define DTN_FORMATW (DTN_FIRST+17) 4420 typedef struct tagNMDATETIMEFORMATA { 4421 NMHDR nmhdr; 4422 LPCSTR pszFormat; 4423 SYSTEMTIME st; 4424 LPCSTR pszDisplay; 4425 CHAR szDisplay[64]; 4426 } NMDATETIMEFORMATA,*LPNMDATETIMEFORMATA; 4427 4428 typedef struct tagNMDATETIMEFORMATW { 4429 NMHDR nmhdr; 4430 LPCWSTR pszFormat; 4431 SYSTEMTIME st; 4432 LPCWSTR pszDisplay; 4433 WCHAR szDisplay[64]; 4434 } NMDATETIMEFORMATW,*LPNMDATETIMEFORMATW; 4435 4436 #define DTN_FORMAT __MINGW_NAME_AW(DTN_FORMAT) 4437 #define NMDATETIMEFORMAT __MINGW_NAME_AW(NMDATETIMEFORMAT) 4438 #define LPNMDATETIMEFORMAT __MINGW_NAME_AW(LPNMDATETIMEFORMAT) 4439 4440 #define DTN_FORMATQUERYA (DTN_FIRST+5) 4441 #define DTN_FORMATQUERYW (DTN_FIRST+18) 4442 typedef struct tagNMDATETIMEFORMATQUERYA { 4443 NMHDR nmhdr; 4444 LPCSTR pszFormat; 4445 SIZE szMax; 4446 } NMDATETIMEFORMATQUERYA,*LPNMDATETIMEFORMATQUERYA; 4447 4448 typedef struct tagNMDATETIMEFORMATQUERYW { 4449 NMHDR nmhdr; 4450 LPCWSTR pszFormat; 4451 SIZE szMax; 4452 } NMDATETIMEFORMATQUERYW,*LPNMDATETIMEFORMATQUERYW; 4453 4454 #define DTN_FORMATQUERY __MINGW_NAME_AW(DTN_FORMATQUERY) 4455 #define NMDATETIMEFORMATQUERY __MINGW_NAME_AW(NMDATETIMEFORMATQUERY) 4456 #define LPNMDATETIMEFORMATQUERY __MINGW_NAME_AW(LPNMDATETIMEFORMATQUERY) 4457 4458 #define DTN_DROPDOWN (DTN_FIRST+6) 4459 #define DTN_CLOSEUP (DTN_FIRST+7) 4460 4461 #define GDTR_MIN 0x1 4462 #define GDTR_MAX 0x2 4463 4464 #define GDT_ERROR -1 4465 #define GDT_VALID 0 4466 #define GDT_NONE 1 4467 4468 #ifndef NOIPADDRESS 4469 4470 #define IPM_CLEARADDRESS (WM_USER+100) 4471 #define IPM_SETADDRESS (WM_USER+101) 4472 #define IPM_GETADDRESS (WM_USER+102) 4473 #define IPM_SETRANGE (WM_USER+103) 4474 #define IPM_SETFOCUS (WM_USER+104) 4475 #define IPM_ISBLANK (WM_USER+105) 4476 4477 #define WC_IPADDRESSW L"SysIPAddress32" 4478 #define WC_IPADDRESSA "SysIPAddress32" 4479 4480 #define WC_IPADDRESS __MINGW_NAME_AW(WC_IPADDRESS) 4481 4482 #define IPN_FIELDCHANGED (IPN_FIRST - 0) 4483 typedef struct tagNMIPADDRESS { 4484 NMHDR hdr; 4485 int iField; 4486 int iValue; 4487 } NMIPADDRESS,*LPNMIPADDRESS; 4488 4489 #define MAKEIPRANGE(low,high) ((LPARAM)(WORD)(((BYTE)(high) << 8)+(BYTE)(low))) 4490 4491 #define MAKEIPADDRESS(b1,b2,b3,b4) ((LPARAM)(((DWORD)(b1)<<24)+((DWORD)(b2)<<16)+((DWORD)(b3)<<8)+((DWORD)(b4)))) 4492 4493 #define FIRST_IPADDRESS(x) ((x>>24) & 0xff) 4494 #define SECOND_IPADDRESS(x) ((x>>16) & 0xff) 4495 #define THIRD_IPADDRESS(x) ((x>>8) & 0xff) 4496 #define FOURTH_IPADDRESS(x) (x & 0xff) 4497 4498 #endif /* !NOIPADDRESS */ 4499 4500 #ifndef NOPAGESCROLLER 4501 4502 #define WC_PAGESCROLLERW L"SysPager" 4503 #define WC_PAGESCROLLERA "SysPager" 4504 4505 #define WC_PAGESCROLLER __MINGW_NAME_AW(WC_PAGESCROLLER) 4506 4507 #define PGS_VERT 0x0 4508 #define PGS_HORZ 0x1 4509 #define PGS_AUTOSCROLL 0x2 4510 #define PGS_DRAGNDROP 0x4 4511 4512 #define PGF_INVISIBLE 0 4513 #define PGF_NORMAL 1 4514 #define PGF_GRAYED 2 4515 #define PGF_DEPRESSED 4 4516 #define PGF_HOT 8 4517 4518 #define PGB_TOPORLEFT 0 4519 #define PGB_BOTTOMORRIGHT 1 4520 4521 #define PGM_SETCHILD (PGM_FIRST+1) 4522 #define Pager_SetChild(hwnd,hwndChild) (void)SNDMSG((hwnd),PGM_SETCHILD,0,(LPARAM)(hwndChild)) 4523 4524 #define PGM_RECALCSIZE (PGM_FIRST+2) 4525 #define Pager_RecalcSize(hwnd) (void)SNDMSG((hwnd),PGM_RECALCSIZE,0,0) 4526 4527 #define PGM_FORWARDMOUSE (PGM_FIRST+3) 4528 #define Pager_ForwardMouse(hwnd,bForward) (void)SNDMSG((hwnd),PGM_FORWARDMOUSE,(WPARAM)(bForward),0) 4529 4530 #define PGM_SETBKCOLOR (PGM_FIRST+4) 4531 #define Pager_SetBkColor(hwnd,clr) (COLORREF)SNDMSG((hwnd),PGM_SETBKCOLOR,0,(LPARAM)(clr)) 4532 4533 #define PGM_GETBKCOLOR (PGM_FIRST+5) 4534 #define Pager_GetBkColor(hwnd) (COLORREF)SNDMSG((hwnd),PGM_GETBKCOLOR,0,0) 4535 4536 #define PGM_SETBORDER (PGM_FIRST+6) 4537 #define Pager_SetBorder(hwnd,iBorder) (int)SNDMSG((hwnd),PGM_SETBORDER,0,(LPARAM)(iBorder)) 4538 4539 #define PGM_GETBORDER (PGM_FIRST+7) 4540 #define Pager_GetBorder(hwnd) (int)SNDMSG((hwnd),PGM_GETBORDER,0,0) 4541 4542 #define PGM_SETPOS (PGM_FIRST+8) 4543 #define Pager_SetPos(hwnd,iPos) (int)SNDMSG((hwnd),PGM_SETPOS,0,(LPARAM)(iPos)) 4544 4545 #define PGM_GETPOS (PGM_FIRST+9) 4546 #define Pager_GetPos(hwnd) (int)SNDMSG((hwnd),PGM_GETPOS,0,0) 4547 4548 #define PGM_SETBUTTONSIZE (PGM_FIRST+10) 4549 #define Pager_SetButtonSize(hwnd,iSize) (int)SNDMSG((hwnd),PGM_SETBUTTONSIZE,0,(LPARAM)(iSize)) 4550 4551 #define PGM_GETBUTTONSIZE (PGM_FIRST+11) 4552 #define Pager_GetButtonSize(hwnd) (int)SNDMSG((hwnd),PGM_GETBUTTONSIZE,0,0) 4553 4554 #define PGM_GETBUTTONSTATE (PGM_FIRST+12) 4555 #define Pager_GetButtonState(hwnd,iButton) (DWORD)SNDMSG((hwnd),PGM_GETBUTTONSTATE,0,(LPARAM)(iButton)) 4556 4557 #define PGM_GETDROPTARGET CCM_GETDROPTARGET 4558 #define Pager_GetDropTarget(hwnd,ppdt) (void)SNDMSG((hwnd),PGM_GETDROPTARGET,0,(LPARAM)(ppdt)) 4559 4560 #define PGN_SCROLL (PGN_FIRST-1) 4561 4562 #define PGF_SCROLLUP 1 4563 #define PGF_SCROLLDOWN 2 4564 #define PGF_SCROLLLEFT 4 4565 #define PGF_SCROLLRIGHT 8 4566 4567 #define PGK_SHIFT 1 4568 #define PGK_CONTROL 2 4569 #define PGK_MENU 4 4570 4571 #include <pshpack1.h> 4572 4573 typedef struct { 4574 NMHDR hdr; 4575 WORD fwKeys; 4576 RECT rcParent; 4577 int iDir; 4578 int iXpos; 4579 int iYpos; 4580 int iScroll; 4581 }NMPGSCROLL,*LPNMPGSCROLL; 4582 4583 #include <poppack.h> 4584 4585 #define PGN_CALCSIZE (PGN_FIRST-2) 4586 4587 #define PGF_CALCWIDTH 1 4588 #define PGF_CALCHEIGHT 2 4589 4590 typedef struct { 4591 NMHDR hdr; 4592 DWORD dwFlag; 4593 int iWidth; 4594 int iHeight; 4595 }NMPGCALCSIZE,*LPNMPGCALCSIZE; 4596 4597 #define PGN_HOTITEMCHANGE (PGN_FIRST-3) 4598 4599 typedef struct tagNMPGHOTITEM 4600 { 4601 NMHDR hdr; 4602 int idOld; 4603 int idNew; 4604 DWORD dwFlags; 4605 } NMPGHOTITEM,*LPNMPGHOTITEM; 4606 4607 #endif /* !NOPAGESCROLLER */ 4608 4609 #ifndef NONATIVEFONTCTL 4610 4611 #define WC_NATIVEFONTCTLW L"NativeFontCtl" 4612 #define WC_NATIVEFONTCTLA "NativeFontCtl" 4613 4614 #define WC_NATIVEFONTCTL __MINGW_NAME_AW(WC_NATIVEFONTCTL) 4615 4616 #define NFS_EDIT 0x1 4617 #define NFS_STATIC 0x2 4618 #define NFS_LISTCOMBO 0x4 4619 #define NFS_BUTTON 0x8 4620 #define NFS_ALL 0x10 4621 #define NFS_USEFONTASSOC 0x20 4622 4623 #endif /* !NONATIVEFONTCTL */ 4624 4625 #ifndef NOBUTTON 4626 4627 #define WC_BUTTONA "Button" 4628 #define WC_BUTTONW L"Button" 4629 4630 #define WC_BUTTON __MINGW_NAME_AW(WC_BUTTON) 4631 4632 #define BUTTON_IMAGELIST_ALIGN_LEFT 0 4633 #define BUTTON_IMAGELIST_ALIGN_RIGHT 1 4634 #define BUTTON_IMAGELIST_ALIGN_TOP 2 4635 #define BUTTON_IMAGELIST_ALIGN_BOTTOM 3 4636 #define BUTTON_IMAGELIST_ALIGN_CENTER 4 4637 4638 typedef struct { 4639 HIMAGELIST himl; 4640 RECT margin; 4641 UINT uAlign; 4642 } BUTTON_IMAGELIST,*PBUTTON_IMAGELIST; 4643 4644 #define BCM_GETIDEALSIZE (BCM_FIRST+0x1) 4645 #define Button_GetIdealSize(hwnd,psize) (BOOL)SNDMSG((hwnd),BCM_GETIDEALSIZE,0,(LPARAM)(psize)) 4646 4647 #define BCM_SETIMAGELIST (BCM_FIRST+0x2) 4648 #define Button_SetImageList(hwnd,pbuttonImagelist) (BOOL)SNDMSG((hwnd),BCM_SETIMAGELIST,0,(LPARAM)(pbuttonImagelist)) 4649 4650 #define BCM_GETIMAGELIST (BCM_FIRST+0x3) 4651 #define Button_GetImageList(hwnd,pbuttonImagelist) (BOOL)SNDMSG((hwnd),BCM_GETIMAGELIST,0,(LPARAM)(pbuttonImagelist)) 4652 4653 #define BCM_SETTEXTMARGIN (BCM_FIRST+0x4) 4654 #define Button_SetTextMargin(hwnd,pmargin) (BOOL)SNDMSG((hwnd),BCM_SETTEXTMARGIN,0,(LPARAM)(pmargin)) 4655 #define BCM_GETTEXTMARGIN (BCM_FIRST+0x5) 4656 #define Button_GetTextMargin(hwnd,pmargin) (BOOL)SNDMSG((hwnd),BCM_GETTEXTMARGIN,0,(LPARAM)(pmargin)) 4657 4658 #define BCM_SETSHIELD (BCM_FIRST+0xC) 4659 #define Button_SetElevationRequiredState(hwnd,frequired) (BOOL)SNDMSG((hwnd),BCM_SETSHIELD,0,(LPARAM)(frequired)) 4660 4661 #define BCM_SETDROPDOWNSTATE (BCM_FIRST + 6) 4662 #define BCM_SETSPLITINFO (BCM_FIRST + 7) 4663 #define BCM_GETSPLITINFO (BCM_FIRST + 8) 4664 #define BCM_SETNOTE (BCM_FIRST + 9) 4665 #define BCM_GETNOTE (BCM_FIRST + 10) 4666 #define BCM_GETNOTELENGTH (BCM_FIRST + 11) 4667 4668 typedef struct tagNMBCHOTITEM { 4669 NMHDR hdr; 4670 DWORD dwFlags; 4671 } NMBCHOTITEM,*LPNMBCHOTITEM; 4672 4673 #define BST_HOT 0x200 4674 4675 #define BS_SPLITBUTTON 0x0000000C 4676 #define BS_DEFSPLITBUTTON 0x0000000D 4677 #define BS_COMMANDLINK 0x0000000E 4678 #define BS_DEFCOMMANDLINK 0x0000000F 4679 4680 #endif /* !NOBUTTON */ 4681 4682 #ifndef NOSTATIC 4683 4684 #define WC_STATICA "Static" 4685 #define WC_STATICW L"Static" 4686 4687 #define WC_STATIC __MINGW_NAME_AW(WC_STATIC) 4688 4689 #ifndef NOEDIT 4690 4691 #define WC_EDITA "Edit" 4692 #define WC_EDITW L"Edit" 4693 4694 #define WC_EDIT __MINGW_NAME_AW(WC_EDIT) 4695 4696 #define EM_SETCUEBANNER (ECM_FIRST+1) 4697 #define Edit_SetCueBannerText(hwnd,lpcwText) (BOOL)SNDMSG((hwnd),EM_SETCUEBANNER,0,(LPARAM)(lpcwText)) 4698 #define EM_GETCUEBANNER (ECM_FIRST+2) 4699 #define Edit_GetCueBannerText(hwnd,lpwText,cchText) (BOOL)SNDMSG((hwnd),EM_GETCUEBANNER,(WPARAM)(lpwText),(LPARAM)(cchText)) 4700 4701 typedef struct _tagEDITBALLOONTIP { 4702 DWORD cbStruct; 4703 LPCWSTR pszTitle; 4704 LPCWSTR pszText; 4705 INT ttiIcon; 4706 } EDITBALLOONTIP,*PEDITBALLOONTIP; 4707 #define EM_SHOWBALLOONTIP (ECM_FIRST+3) 4708 #define Edit_ShowBalloonTip(hwnd,peditballoontip) (BOOL)SNDMSG((hwnd),EM_SHOWBALLOONTIP,0,(LPARAM)(peditballoontip)) 4709 #define EM_HIDEBALLOONTIP (ECM_FIRST+4) 4710 #define Edit_HideBalloonTip(hwnd) (BOOL)SNDMSG((hwnd),EM_HIDEBALLOONTIP,0,0) 4711 4712 #endif /* !NOEDIT */ 4713 4714 #ifndef NOLISTBOX 4715 #define WC_LISTBOXA "ListBox" 4716 #define WC_LISTBOXW L"ListBox" 4717 #define WC_LISTBOX __MINGW_NAME_AW(WC_LISTBOX) 4718 #endif /* !NOLISTBOX */ 4719 4720 #ifndef NOCOMBOBOX 4721 #define WC_COMBOBOXA "ComboBox" 4722 #define WC_COMBOBOXW L"ComboBox" 4723 #define WC_COMBOBOX __MINGW_NAME_AW(WC_COMBOBOX) 4724 #endif /* !NOCOMBOBOX */ 4725 4726 #define CB_SETMINVISIBLE (CBM_FIRST+1) 4727 #define CB_GETMINVISIBLE (CBM_FIRST+2) 4728 4729 #define ComboBox_SetMinVisible(hwnd,iMinVisible) (BOOL)SNDMSG((hwnd),CB_SETMINVISIBLE,(WPARAM)iMinVisible,0) 4730 #define ComboBox_GetMinVisible(hwnd) (int)SNDMSG((hwnd),CB_GETMINVISIBLE,0,0) 4731 4732 #ifndef NOSCROLLBAR 4733 #define WC_SCROLLBARA "ScrollBar" 4734 #define WC_SCROLLBARW L"ScrollBar" 4735 #define WC_SCROLLBAR __MINGW_NAME_AW(WC_SCROLLBAR) 4736 #endif /* !NOSCROLLBAR */ 4737 4738 #define INVALID_LINK_INDEX (-1) 4739 #define MAX_LINKID_TEXT 48 4740 #define L_MAX_URL_LENGTH (2048+32+sizeof("://")) 4741 4742 #define WC_LINK L"SysLink" 4743 4744 #define LWS_TRANSPARENT 0x1 4745 #define LWS_IGNORERETURN 0x2 4746 4747 #define LIF_ITEMINDEX 0x1 4748 #define LIF_STATE 0x2 4749 #define LIF_ITEMID 0x4 4750 #define LIF_URL 0x8 4751 4752 #define LIS_FOCUSED 0x1 4753 #define LIS_ENABLED 0x2 4754 #define LIS_VISITED 0x4 4755 4756 typedef struct tagLITEM { 4757 UINT mask; 4758 int iLink; 4759 UINT state; 4760 UINT stateMask; 4761 WCHAR szID[MAX_LINKID_TEXT]; 4762 WCHAR szUrl[L_MAX_URL_LENGTH]; 4763 } LITEM,*PLITEM; 4764 4765 typedef struct tagLHITTESTINFO { 4766 POINT pt; 4767 LITEM item; 4768 } LHITTESTINFO,*PLHITTESTINFO; 4769 4770 typedef struct tagNMLINK { 4771 NMHDR hdr; 4772 LITEM item; 4773 } NMLINK,*PNMLINK; 4774 4775 #define LM_HITTEST (WM_USER+0x300) 4776 #define LM_GETIDEALHEIGHT (WM_USER+0x301) 4777 #define LM_GETIDEALSIZE (LM_GETIDEALHEIGHT) 4778 #define LM_SETITEM (WM_USER+0x302) 4779 #define LM_GETITEM (WM_USER+0x303) 4780 4781 #ifndef NOMUI 4782 void WINAPI InitMUILanguage(LANGID uiLang); 4783 LANGID WINAPI GetMUILanguage(void); 4784 #endif 4785 4786 #endif /* !NOSTATIC */ 4787 4788 #define DA_LAST (0x7fffffff) 4789 #define DPA_APPEND (0x7fffffff) 4790 #define DPA_ERR (-1) 4791 4792 #define DSA_APPEND (0x7fffffff) 4793 #define DSA_ERR (-1) 4794 4795 typedef struct _DSA *HDSA; 4796 4797 typedef int (CALLBACK *PFNDPAENUMCALLBACK)(void *p,void *pData); 4798 typedef int (CALLBACK *PFNDSAENUMCALLBACK)(void *p,void *pData); 4799 4800 WINCOMMCTRLAPI HDSA WINAPI DSA_Create(int cbItem,int cItemGrow); 4801 WINCOMMCTRLAPI BOOL WINAPI DSA_Destroy(_Inout_opt_ HDSA hdsa); 4802 4803 WINCOMMCTRLAPI 4804 void 4805 WINAPI 4806 DSA_DestroyCallback( 4807 _Inout_opt_ HDSA hdsa, 4808 _In_ PFNDSAENUMCALLBACK pfnCB, 4809 _In_opt_ void *pData); 4810 4811 WINCOMMCTRLAPI 4812 VOID 4813 WINAPI 4814 DSA_EnumCallback( 4815 _In_ HDSA hdsa, 4816 _In_ PFNDSAENUMCALLBACK enumProc, 4817 _In_opt_ LPVOID lParam); 4818 4819 WINCOMMCTRLAPI PVOID WINAPI DSA_GetItemPtr(_In_ HDSA hdsa, int i); 4820 4821 WINCOMMCTRLAPI BOOL WINAPI DSA_DeleteAllItems(_In_ HDSA hdsa); 4822 4823 WINCOMMCTRLAPI 4824 int 4825 WINAPI 4826 DSA_InsertItem( 4827 _Inout_ HDSA hdsa, 4828 _In_ int i, 4829 _In_ void *pitem); 4830 4831 #define DSA_GetItemCount(hdsa) (*(int *) (hdsa)) 4832 #define DSA_AppendItem(hdsa, pitem) DSA_InsertItem (hdsa, DA_LAST, pitem) 4833 4834 typedef struct _DPA *HDPA; 4835 4836 WINCOMMCTRLAPI HDPA WINAPI DPA_Create(int cItemGrow); 4837 WINCOMMCTRLAPI BOOL WINAPI DPA_Destroy(_Inout_opt_ HDPA hdpa); 4838 WINCOMMCTRLAPI PVOID WINAPI DPA_DeletePtr(_Inout_ HDPA hdpa, _In_ int i); 4839 WINCOMMCTRLAPI BOOL WINAPI DPA_DeleteAllPtrs(_Inout_ HDPA hdpa); 4840 4841 WINCOMMCTRLAPI 4842 void 4843 WINAPI 4844 DPA_EnumCallback( 4845 _In_opt_ HDPA hdpa, 4846 _In_opt_ PFNDPAENUMCALLBACK pfnCB, 4847 _In_opt_ void *pData); 4848 4849 WINCOMMCTRLAPI 4850 void 4851 WINAPI 4852 DPA_DestroyCallback( 4853 _Inout_opt_ HDPA hdpa, 4854 _In_ PFNDPAENUMCALLBACK pfnCB, 4855 _In_opt_ void *pData); 4856 4857 typedef int (CALLBACK *PFNDPACOMPARE)(void *p1,void *p2,LPARAM lParam); 4858 4859 WINCOMMCTRLAPI 4860 BOOL 4861 WINAPI 4862 DPA_Sort( 4863 _Inout_ HDPA hdpa, 4864 _In_ PFNDPACOMPARE pfnCompare, 4865 _In_ LPARAM lParam); 4866 4867 #define DPAS_SORTED 0x1 4868 #define DPAS_INSERTBEFORE 0x2 4869 #define DPAS_INSERTAFTER 0x4 4870 4871 WINCOMMCTRLAPI 4872 int 4873 WINAPI 4874 DPA_Search( 4875 _In_ HDPA hdpa, 4876 _In_opt_ void *pFind, 4877 _In_ int iStart, 4878 _In_ PFNDPACOMPARE pfnCompare, 4879 _In_ LPARAM lParam, 4880 _In_ UINT options); 4881 4882 WINCOMMCTRLAPI 4883 BOOL 4884 WINAPI Str_SetPtrW( 4885 _Inout_ LPWSTR *ppsz, 4886 _In_opt_ LPCWSTR psz); 4887 4888 typedef struct _DPASTREAMINFO { 4889 int iPos; 4890 void *pvItem; 4891 } DPASTREAMINFO; 4892 4893 struct IStream; 4894 4895 typedef HRESULT 4896 (CALLBACK *PFNDPASTREAM)( 4897 _In_ DPASTREAMINFO*, 4898 _In_ struct IStream*, 4899 _In_opt_ void*); 4900 4901 typedef void* 4902 (CALLBACK *PFNDPAMERGE)( 4903 _In_ UINT, 4904 _In_ void*, 4905 _In_ void*, 4906 _In_ LPARAM); 4907 4908 typedef const void* 4909 (CALLBACK *PFNDPAMERGECONST)( 4910 _In_ UINT, 4911 _In_ const void*, 4912 _In_ const void*, 4913 _In_ LPARAM); 4914 4915 WINCOMMCTRLAPI 4916 HRESULT 4917 WINAPI 4918 DPA_LoadStream( 4919 _Outptr_ HDPA * phdpa, 4920 _In_ PFNDPASTREAM pfn, 4921 _In_ struct IStream * pstream, 4922 _In_opt_ void *pvInstData); 4923 4924 WINCOMMCTRLAPI 4925 HRESULT 4926 WINAPI 4927 DPA_SaveStream( 4928 _In_ HDPA hdpa, 4929 _In_ PFNDPASTREAM pfn, 4930 _In_ struct IStream * pstream, 4931 _In_opt_ void *pvInstData); 4932 4933 WINCOMMCTRLAPI BOOL WINAPI DPA_Grow(_Inout_ HDPA pdpa, _In_ int cp); 4934 4935 WINCOMMCTRLAPI 4936 int 4937 WINAPI 4938 DPA_InsertPtr( 4939 _Inout_ HDPA hdpa, 4940 _In_ int i, 4941 _In_opt_ void *p); 4942 4943 WINCOMMCTRLAPI PVOID WINAPI DPA_GetPtr(_In_ HDPA hdpa, _In_ INT_PTR i); 4944 4945 WINCOMMCTRLAPI 4946 BOOL 4947 WINAPI 4948 DPA_SetPtr( 4949 _Inout_ HDPA hdpa, 4950 _In_ int i, 4951 _In_opt_ void *p); 4952 4953 WINCOMMCTRLAPI 4954 int 4955 WINAPI 4956 DPA_GetPtrIndex( 4957 _In_ HDPA hdpa, 4958 _In_opt_ const void *p); 4959 4960 #define DPA_GetPtrCount(hdpa) (*(int *)(hdpa)) 4961 #define DPA_SetPtrCount(hdpa, cItems) (*(int *)(hdpa) = (cItems)) 4962 #define DPA_GetPtrPtr(hdpa) (*((void * **)((BYTE *)(hdpa) + sizeof(void *)))) 4963 #define DPA_AppendPtr(hdpa, pitem) DPA_InsertPtr(hdpa, DA_LAST, pitem) 4964 #define DPA_FastDeleteLastPtr(hdpa) (--*(int *)(hdpa)) 4965 #define DPA_FastGetPtr(hdpa, i) (DPA_GetPtrPtr(hdpa)[i]) 4966 4967 #define DPAM_SORTED 1 4968 #define DPAM_NORMAL 2 4969 #define DPAM_UNION 4 4970 #define DPAM_INTERSECT 8 4971 4972 #define DPAMM_MERGE 1 4973 #define DPAMM_DELETE 2 4974 #define DPAMM_INSERT 3 4975 4976 #ifndef NOTRACKMOUSEEVENT 4977 4978 #ifndef WM_MOUSEHOVER 4979 #define WM_MOUSEHOVER 0x2a1 4980 #define WM_MOUSELEAVE 0x2a3 4981 #endif 4982 4983 #ifndef TME_HOVER 4984 4985 #define TME_HOVER 0x1 4986 #define TME_LEAVE 0x2 4987 #define TME_NONCLIENT 0x10 4988 #define TME_QUERY 0x40000000 4989 #define TME_CANCEL 0x80000000 4990 4991 #define HOVER_DEFAULT 0xffffffff 4992 4993 typedef struct tagTRACKMOUSEEVENT { 4994 DWORD cbSize; 4995 DWORD dwFlags; 4996 HWND hwndTrack; 4997 DWORD dwHoverTime; 4998 } TRACKMOUSEEVENT,*LPTRACKMOUSEEVENT; 4999 5000 #endif /* !TME_HOVER */ 5001 5002 WINCOMMCTRLAPI 5003 BOOL 5004 WINAPI 5005 _TrackMouseEvent( 5006 _Inout_ LPTRACKMOUSEEVENT lpEventTrack); 5007 5008 #endif /* !NOTRACKMOUSEEVENT */ 5009 5010 #ifndef NOFLATSBAPIS 5011 5012 #define WSB_PROP_CYVSCROLL 0x1L 5013 #define WSB_PROP_CXHSCROLL 0x2L 5014 #define WSB_PROP_CYHSCROLL 0x4L 5015 #define WSB_PROP_CXVSCROLL 0x8L 5016 #define WSB_PROP_CXHTHUMB 0x10L 5017 #define WSB_PROP_CYVTHUMB 0x20L 5018 #define WSB_PROP_VBKGCOLOR 0x40L 5019 #define WSB_PROP_HBKGCOLOR 0x80L 5020 #define WSB_PROP_VSTYLE 0x100L 5021 #define WSB_PROP_HSTYLE 0x200L 5022 #define WSB_PROP_WINSTYLE 0x400L 5023 #define WSB_PROP_PALETTE 0x800L 5024 #define WSB_PROP_MASK 0xfffL 5025 5026 #define FSB_FLAT_MODE 2 5027 #define FSB_ENCARTA_MODE 1 5028 #define FSB_REGULAR_MODE 0 5029 5030 WINCOMMCTRLAPI BOOL WINAPI FlatSB_EnableScrollBar(HWND,int,UINT); 5031 WINCOMMCTRLAPI BOOL WINAPI FlatSB_ShowScrollBar(HWND,int code,BOOL); 5032 WINCOMMCTRLAPI BOOL WINAPI FlatSB_GetScrollRange(HWND,int code,LPINT,LPINT); 5033 WINCOMMCTRLAPI BOOL WINAPI FlatSB_GetScrollInfo(HWND,int code,LPSCROLLINFO); 5034 WINCOMMCTRLAPI int WINAPI FlatSB_GetScrollPos(HWND,int code); 5035 WINCOMMCTRLAPI BOOL WINAPI FlatSB_GetScrollProp(HWND,int propIndex,LPINT); 5036 #ifdef _WIN64 5037 WINCOMMCTRLAPI BOOL WINAPI FlatSB_GetScrollPropPtr(HWND,int propIndex,PINT_PTR); 5038 #else 5039 #define FlatSB_GetScrollPropPtr FlatSB_GetScrollProp 5040 #endif 5041 5042 WINCOMMCTRLAPI int WINAPI FlatSB_SetScrollPos(HWND,int code,int pos,BOOL fRedraw); 5043 WINCOMMCTRLAPI int WINAPI FlatSB_SetScrollInfo(HWND,int code,LPSCROLLINFO,BOOL fRedraw); 5044 WINCOMMCTRLAPI int WINAPI FlatSB_SetScrollRange(HWND,int code,int min,int max,BOOL fRedraw); 5045 WINCOMMCTRLAPI BOOL WINAPI FlatSB_SetScrollProp(HWND,UINT index,INT_PTR newValue,BOOL); 5046 #define FlatSB_SetScrollPropPtr FlatSB_SetScrollProp 5047 WINCOMMCTRLAPI BOOL WINAPI InitializeFlatSB(HWND); 5048 WINCOMMCTRLAPI HRESULT WINAPI UninitializeFlatSB(HWND); 5049 5050 #endif /* !NOFLATSBAPIS */ 5051 5052 #endif /* !NODATETIMEPICK */ 5053 5054 typedef LRESULT (CALLBACK *SUBCLASSPROC)(HWND hWnd,UINT uMsg,WPARAM wParam,LPARAM lParam,UINT_PTR uIdSubclass,DWORD_PTR dwRefData); 5055 5056 _Success_(return != 0) 5057 BOOL 5058 WINAPI 5059 SetWindowSubclass( 5060 _In_ HWND hWnd, 5061 _In_ SUBCLASSPROC pfnSubclass, 5062 _In_ UINT_PTR uIdSubclass, 5063 _In_ DWORD_PTR dwRefData); 5064 5065 _Success_(return != 0) 5066 BOOL 5067 WINAPI 5068 GetWindowSubclass( 5069 _In_ HWND hWnd, 5070 _In_ SUBCLASSPROC pfnSubclass, 5071 _In_ UINT_PTR uIdSubclass, 5072 _Out_opt_ DWORD_PTR *pdwRefData); 5073 5074 _Success_(return != 0) 5075 BOOL 5076 WINAPI 5077 RemoveWindowSubclass( 5078 _In_ HWND hWnd, 5079 _In_ SUBCLASSPROC pfnSubclass, 5080 _In_ UINT_PTR uIdSubclass); 5081 5082 LRESULT WINAPI DefSubclassProc(HWND hWnd,UINT uMsg,WPARAM wParam,LPARAM lParam); 5083 5084 int 5085 WINAPI 5086 DrawShadowText( 5087 _In_ HDC hdc, 5088 _In_reads_(cch) LPCWSTR pszText, 5089 _In_ UINT cch, 5090 _In_ RECT *prc, 5091 _In_ DWORD dwFlags, 5092 _In_ COLORREF crText, 5093 _In_ COLORREF crShadow, 5094 _In_ int ixOffset, 5095 _In_ int iyOffset); 5096 5097 #ifndef NOTASKDIALOG 5098 5099 #include <pshpack1.h> 5100 5101 enum _TASKDIALOG_FLAGS 5102 { 5103 TDF_ENABLE_HYPERLINKS = 0x0001, 5104 TDF_USE_HICON_MAIN = 0x0002, 5105 TDF_USE_HICON_FOOTER = 0x0004, 5106 TDF_ALLOW_DIALOG_CANCELLATION = 0x0008, 5107 TDF_USE_COMMAND_LINKS = 0x0010, 5108 TDF_USE_COMMAND_LINKS_NO_ICON = 0x0020, 5109 TDF_EXPAND_FOOTER_AREA = 0x0040, 5110 TDF_EXPANDED_BY_DEFAULT = 0x0080, 5111 TDF_VERIFICATION_FLAG_CHECKED = 0x0100, 5112 TDF_SHOW_PROGRESS_BAR = 0x0200, 5113 TDF_SHOW_MARQUEE_PROGRESS_BAR = 0x0400, 5114 TDF_CALLBACK_TIMER = 0x0800, 5115 TDF_POSITION_RELATIVE_TO_WINDOW = 0x1000, 5116 TDF_RTL_LAYOUT = 0x2000, 5117 TDF_NO_DEFAULT_RADIO_BUTTON = 0x4000, 5118 TDF_CAN_BE_MINIMIZED = 0x8000, 5119 TDF_NO_SET_FOREGROUND = 0x10000, 5120 TDF_SIZE_TO_CONTENT = 0x01000000 5121 }; 5122 typedef int TASKDIALOG_FLAGS; 5123 5124 typedef enum _TASKDIALOG_MESSAGES 5125 { 5126 TDM_NAVIGATE_PAGE = WM_USER + 101, 5127 TDM_CLICK_BUTTON = WM_USER + 102, 5128 TDM_SET_MARQUEE_PROGRESS_BAR = WM_USER + 103, 5129 TDM_SET_PROGRESS_BAR_STATE = WM_USER + 104, 5130 TDM_SET_PROGRESS_BAR_RANGE = WM_USER + 105, 5131 TDM_SET_PROGRESS_BAR_POS = WM_USER + 106, 5132 TDM_SET_PROGRESS_BAR_MARQUEE = WM_USER + 107, 5133 TDM_SET_ELEMENT_TEXT = WM_USER + 108, 5134 TDM_CLICK_RADIO_BUTTON = WM_USER + 110, 5135 TDM_ENABLE_BUTTON = WM_USER + 111, 5136 TDM_ENABLE_RADIO_BUTTON = WM_USER + 112, 5137 TDM_CLICK_VERIFICATION = WM_USER + 113, 5138 TDM_UPDATE_ELEMENT_TEXT = WM_USER + 114, 5139 TDM_SET_BUTTON_ELEVATION_REQUIRED_STATE = WM_USER + 115, 5140 TDM_UPDATE_ICON = WM_USER + 116, 5141 } TASKDIALOG_MESSAGES; 5142 5143 typedef enum _TASKDIALOG_NOTIFICATIONS 5144 { 5145 TDN_CREATED, 5146 TDN_NAVIGATED, 5147 TDN_BUTTON_CLICKED, 5148 TDN_HYPERLINK_CLICKED, 5149 TDN_TIMER, 5150 TDN_DESTROYED, 5151 TDN_RADIO_BUTTON_CLICKED, 5152 TDN_DIALOG_CONSTRUCTED, 5153 TDN_VERIFICATION_CLICKED, 5154 TDN_HELP, 5155 TDN_EXPANDO_BUTTON_CLICKED, 5156 } TASKDIALOG_NOTIFICATIONS; 5157 5158 typedef enum _TASKDIALOG_ELEMENTS 5159 { 5160 TDE_CONTENT, 5161 TDE_EXPANDED_INFORMATION, 5162 TDE_FOOTER, 5163 TDE_MAIN_INSTRUCTION, 5164 } TASKDIALOG_ELEMENTS; 5165 5166 typedef enum _TASKDIALOG_ICON_ELEMENTS 5167 { 5168 TDIE_ICON_MAIN, 5169 TDIE_ICON_FOOTER, 5170 } TASKDIALOG_ICON_ELEMENTS; 5171 5172 #define TD_WARNING_ICON MAKEINTRESOURCEW(-1) 5173 #define TD_ERROR_ICON MAKEINTRESOURCEW(-2) 5174 #define TD_INFORMATION_ICON MAKEINTRESOURCEW(-3) 5175 #define TD_SHIELD_ICON MAKEINTRESOURCEW(-4) 5176 5177 enum _TASKDIALOG_COMMON_BUTTON_FLAGS 5178 { 5179 TDCBF_OK_BUTTON = 0x0001, 5180 TDCBF_YES_BUTTON = 0x0002, 5181 TDCBF_NO_BUTTON = 0x0004, 5182 TDCBF_CANCEL_BUTTON = 0x0008, 5183 TDCBF_RETRY_BUTTON = 0x0010, 5184 TDCBF_CLOSE_BUTTON = 0x0020 5185 }; 5186 typedef int TASKDIALOG_COMMON_BUTTON_FLAGS; 5187 5188 typedef struct _TASKDIALOG_BUTTON 5189 { 5190 int nButtonID; 5191 PCWSTR pszButtonText; 5192 } TASKDIALOG_BUTTON; 5193 5194 typedef HRESULT 5195 (CALLBACK *PFTASKDIALOGCALLBACK)( 5196 _In_ HWND, 5197 _In_ UINT, 5198 _In_ WPARAM, 5199 _In_ LPARAM, 5200 _In_ LONG_PTR); 5201 5202 typedef struct _TASKDIALOGCONFIG 5203 { 5204 UINT cbSize; 5205 HWND hwndParent; 5206 HINSTANCE hInstance; 5207 TASKDIALOG_FLAGS dwFlags; 5208 TASKDIALOG_COMMON_BUTTON_FLAGS dwCommonButtons; 5209 PCWSTR pszWindowTitle; 5210 union 5211 { 5212 HICON hMainIcon; 5213 PCWSTR pszMainIcon; 5214 } DUMMYUNIONNAME; 5215 PCWSTR pszMainInstruction; 5216 PCWSTR pszContent; 5217 UINT cButtons; 5218 const TASKDIALOG_BUTTON *pButtons; 5219 int nDefaultButton; 5220 UINT cRadioButtons; 5221 const TASKDIALOG_BUTTON *pRadioButtons; 5222 int nDefaultRadioButton; 5223 PCWSTR pszVerificationText; 5224 PCWSTR pszExpandedInformation; 5225 PCWSTR pszExpandedControlText; 5226 PCWSTR pszCollapsedControlText; 5227 union 5228 { 5229 HICON hFooterIcon; 5230 PCWSTR pszFooterIcon; 5231 } DUMMYUNIONNAME2; 5232 PCWSTR pszFooter; 5233 PFTASKDIALOGCALLBACK pfCallback; 5234 LONG_PTR lpCallbackData; 5235 UINT cxWidth; 5236 } TASKDIALOGCONFIG; 5237 5238 HRESULT 5239 WINAPI 5240 TaskDialogIndirect( 5241 _In_ const TASKDIALOGCONFIG *, 5242 _Out_opt_ int *, 5243 _Out_opt_ int *, 5244 _Out_opt_ BOOL *); 5245 5246 #include <poppack.h> 5247 5248 #endif /* !NOTASKDIALOG */ 5249 5250 #if (NTDDI_VERSION >= NTDDI_VISTA) 5251 enum _LI_METRIC 5252 { 5253 LIM_SMALL, 5254 LIM_LARGE, 5255 }; 5256 #endif 5257 5258 #ifdef __cplusplus 5259 } 5260 #endif 5261 5262 #endif /* !NOUSER */ 5263 5264 #endif /* _INC_COMMCTRL */ 5265