Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1600 lines
47 KiB

  1. /*++ BUILD Version: 0000 Increment this if a change has global effects
  2. Copyright (c) Microsoft Corporation. All rights reserved.
  3. Module Name:
  4. winuser.rh
  5. Abstract:
  6. This module defines the 32-Bit Windows resource codes from winuser.h.
  7. Revision History:
  8. --*/
  9. #define RT_MANIFEST 24
  10. #define CREATEPROCESS_MANIFEST_RESOURCE_ID 1
  11. #define ISOLATIONAWARE_MANIFEST_RESOURCE_ID 2
  12. #define ISOLATIONAWARE_NOSTATICIMPORT_MANIFEST_RESOURCE_ID 3
  13. #define MINIMUM_RESERVED_MANIFEST_RESOURCE_ID 1 /* inclusive */
  14. #define MAXIMUM_RESERVED_MANIFEST_RESOURCE_ID 16 /* inclusive */
  15. /*
  16. * ShowWindow() Commands
  17. */
  18. #define SW_HIDE 0
  19. #define SW_SHOWNORMAL 1
  20. #define SW_NORMAL 1
  21. #define SW_SHOWMINIMIZED 2
  22. #define SW_SHOWMAXIMIZED 3
  23. #define SW_MAXIMIZE 3
  24. #define SW_SHOWNOACTIVATE 4
  25. #define SW_SHOW 5
  26. #define SW_MINIMIZE 6
  27. #define SW_SHOWMINNOACTIVE 7
  28. #define SW_SHOWNA 8
  29. #define SW_RESTORE 9
  30. #define SW_SHOWDEFAULT 10
  31. #define SW_FORCEMINIMIZE 11
  32. #define SW_MAX 11
  33. /*
  34. * Old ShowWindow() Commands
  35. */
  36. #define HIDE_WINDOW 0
  37. #define SHOW_OPENWINDOW 1
  38. #define SHOW_ICONWINDOW 2
  39. #define SHOW_FULLSCREEN 3
  40. #define SHOW_OPENNOACTIVATE 4
  41. /*
  42. * Identifiers for the WM_SHOWWINDOW message
  43. */
  44. #define SW_PARENTCLOSING 1
  45. #define SW_OTHERZOOM 2
  46. #define SW_PARENTOPENING 3
  47. #define SW_OTHERUNZOOM 4
  48. /*
  49. * Virtual Keys, Standard Set
  50. */
  51. #define VK_LBUTTON 0x01
  52. #define VK_RBUTTON 0x02
  53. #define VK_CANCEL 0x03
  54. #define VK_MBUTTON 0x04 /* NOT contiguous with L & RBUTTON */
  55. #if(_WIN32_WINNT >= 0x0500)
  56. #define VK_XBUTTON1 0x05 /* NOT contiguous with L & RBUTTON */
  57. #define VK_XBUTTON2 0x06 /* NOT contiguous with L & RBUTTON */
  58. #endif /* _WIN32_WINNT >= 0x0500 */
  59. /*
  60. * 0x07 : unassigned
  61. */
  62. #define VK_BACK 0x08
  63. #define VK_TAB 0x09
  64. /*
  65. * 0x0A - 0x0B : reserved
  66. */
  67. #define VK_CLEAR 0x0C
  68. #define VK_RETURN 0x0D
  69. #define VK_SHIFT 0x10
  70. #define VK_CONTROL 0x11
  71. #define VK_MENU 0x12
  72. #define VK_PAUSE 0x13
  73. #define VK_CAPITAL 0x14
  74. #define VK_KANA 0x15
  75. #define VK_HANGEUL 0x15 /* old name - should be here for compatibility */
  76. #define VK_HANGUL 0x15
  77. #define VK_JUNJA 0x17
  78. #define VK_FINAL 0x18
  79. #define VK_HANJA 0x19
  80. #define VK_KANJI 0x19
  81. #define VK_ESCAPE 0x1B
  82. #define VK_CONVERT 0x1C
  83. #define VK_NONCONVERT 0x1D
  84. #define VK_ACCEPT 0x1E
  85. #define VK_MODECHANGE 0x1F
  86. #define VK_SPACE 0x20
  87. #define VK_PRIOR 0x21
  88. #define VK_NEXT 0x22
  89. #define VK_END 0x23
  90. #define VK_HOME 0x24
  91. #define VK_LEFT 0x25
  92. #define VK_UP 0x26
  93. #define VK_RIGHT 0x27
  94. #define VK_DOWN 0x28
  95. #define VK_SELECT 0x29
  96. #define VK_PRINT 0x2A
  97. #define VK_EXECUTE 0x2B
  98. #define VK_SNAPSHOT 0x2C
  99. #define VK_INSERT 0x2D
  100. #define VK_DELETE 0x2E
  101. #define VK_HELP 0x2F
  102. /*
  103. * VK_0 - VK_9 are the same as ASCII '0' - '9' (0x30 - 0x39)
  104. * 0x40 : unassigned
  105. * VK_A - VK_Z are the same as ASCII 'A' - 'Z' (0x41 - 0x5A)
  106. */
  107. #define VK_LWIN 0x5B
  108. #define VK_RWIN 0x5C
  109. #define VK_APPS 0x5D
  110. /*
  111. * 0x5E : reserved
  112. */
  113. #define VK_SLEEP 0x5F
  114. #define VK_NUMPAD0 0x60
  115. #define VK_NUMPAD1 0x61
  116. #define VK_NUMPAD2 0x62
  117. #define VK_NUMPAD3 0x63
  118. #define VK_NUMPAD4 0x64
  119. #define VK_NUMPAD5 0x65
  120. #define VK_NUMPAD6 0x66
  121. #define VK_NUMPAD7 0x67
  122. #define VK_NUMPAD8 0x68
  123. #define VK_NUMPAD9 0x69
  124. #define VK_MULTIPLY 0x6A
  125. #define VK_ADD 0x6B
  126. #define VK_SEPARATOR 0x6C
  127. #define VK_SUBTRACT 0x6D
  128. #define VK_DECIMAL 0x6E
  129. #define VK_DIVIDE 0x6F
  130. #define VK_F1 0x70
  131. #define VK_F2 0x71
  132. #define VK_F3 0x72
  133. #define VK_F4 0x73
  134. #define VK_F5 0x74
  135. #define VK_F6 0x75
  136. #define VK_F7 0x76
  137. #define VK_F8 0x77
  138. #define VK_F9 0x78
  139. #define VK_F10 0x79
  140. #define VK_F11 0x7A
  141. #define VK_F12 0x7B
  142. #define VK_F13 0x7C
  143. #define VK_F14 0x7D
  144. #define VK_F15 0x7E
  145. #define VK_F16 0x7F
  146. #define VK_F17 0x80
  147. #define VK_F18 0x81
  148. #define VK_F19 0x82
  149. #define VK_F20 0x83
  150. #define VK_F21 0x84
  151. #define VK_F22 0x85
  152. #define VK_F23 0x86
  153. #define VK_F24 0x87
  154. /*
  155. * 0x88 - 0x8F : unassigned
  156. */
  157. #define VK_NUMLOCK 0x90
  158. #define VK_SCROLL 0x91
  159. /*
  160. * NEC PC-9800 kbd definitions
  161. */
  162. #define VK_OEM_NEC_EQUAL 0x92 // '=' key on numpad
  163. /*
  164. * Fujitsu/OASYS kbd definitions
  165. */
  166. #define VK_OEM_FJ_JISHO 0x92 // 'Dictionary' key
  167. #define VK_OEM_FJ_MASSHOU 0x93 // 'Unregister word' key
  168. #define VK_OEM_FJ_TOUROKU 0x94 // 'Register word' key
  169. #define VK_OEM_FJ_LOYA 0x95 // 'Left OYAYUBI' key
  170. #define VK_OEM_FJ_ROYA 0x96 // 'Right OYAYUBI' key
  171. /*
  172. * 0x97 - 0x9F : unassigned
  173. */
  174. /*
  175. * VK_L* & VK_R* - left and right Alt, Ctrl and Shift virtual keys.
  176. * Used only as parameters to GetAsyncKeyState() and GetKeyState().
  177. * No other API or message will distinguish left and right keys in this way.
  178. */
  179. #define VK_LSHIFT 0xA0
  180. #define VK_RSHIFT 0xA1
  181. #define VK_LCONTROL 0xA2
  182. #define VK_RCONTROL 0xA3
  183. #define VK_LMENU 0xA4
  184. #define VK_RMENU 0xA5
  185. #if(_WIN32_WINNT >= 0x0500)
  186. #define VK_BROWSER_BACK 0xA6
  187. #define VK_BROWSER_FORWARD 0xA7
  188. #define VK_BROWSER_REFRESH 0xA8
  189. #define VK_BROWSER_STOP 0xA9
  190. #define VK_BROWSER_SEARCH 0xAA
  191. #define VK_BROWSER_FAVORITES 0xAB
  192. #define VK_BROWSER_HOME 0xAC
  193. #define VK_VOLUME_MUTE 0xAD
  194. #define VK_VOLUME_DOWN 0xAE
  195. #define VK_VOLUME_UP 0xAF
  196. #define VK_MEDIA_NEXT_TRACK 0xB0
  197. #define VK_MEDIA_PREV_TRACK 0xB1
  198. #define VK_MEDIA_STOP 0xB2
  199. #define VK_MEDIA_PLAY_PAUSE 0xB3
  200. #define VK_LAUNCH_MAIL 0xB4
  201. #define VK_LAUNCH_MEDIA_SELECT 0xB5
  202. #define VK_LAUNCH_APP1 0xB6
  203. #define VK_LAUNCH_APP2 0xB7
  204. #endif /* _WIN32_WINNT >= 0x0500 */
  205. /*
  206. * 0xB8 - 0xB9 : reserved
  207. */
  208. #define VK_OEM_1 0xBA // ';:' for US
  209. #define VK_OEM_PLUS 0xBB // '+' any country
  210. #define VK_OEM_COMMA 0xBC // ',' any country
  211. #define VK_OEM_MINUS 0xBD // '-' any country
  212. #define VK_OEM_PERIOD 0xBE // '.' any country
  213. #define VK_OEM_2 0xBF // '/?' for US
  214. #define VK_OEM_3 0xC0 // '`~' for US
  215. /*
  216. * 0xC1 - 0xD7 : reserved
  217. */
  218. /*
  219. * 0xD8 - 0xDA : unassigned
  220. */
  221. #define VK_OEM_4 0xDB // '[{' for US
  222. #define VK_OEM_5 0xDC // '\|' for US
  223. #define VK_OEM_6 0xDD // ']}' for US
  224. #define VK_OEM_7 0xDE // ''"' for US
  225. #define VK_OEM_8 0xDF
  226. /*
  227. * 0xE0 : reserved
  228. */
  229. /*
  230. * Various extended or enhanced keyboards
  231. */
  232. #define VK_OEM_AX 0xE1 // 'AX' key on Japanese AX kbd
  233. #define VK_OEM_102 0xE2 // "<>" or "\|" on RT 102-key kbd.
  234. #define VK_ICO_HELP 0xE3 // Help key on ICO
  235. #define VK_ICO_00 0xE4 // 00 key on ICO
  236. #if(WINVER >= 0x0400)
  237. #define VK_PROCESSKEY 0xE5
  238. #endif /* WINVER >= 0x0400 */
  239. #define VK_ICO_CLEAR 0xE6
  240. #if(_WIN32_WINNT >= 0x0500)
  241. #define VK_PACKET 0xE7
  242. #endif /* _WIN32_WINNT >= 0x0500 */
  243. /*
  244. * 0xE8 : unassigned
  245. */
  246. /*
  247. * Nokia/Ericsson definitions
  248. */
  249. #define VK_OEM_RESET 0xE9
  250. #define VK_OEM_JUMP 0xEA
  251. #define VK_OEM_PA1 0xEB
  252. #define VK_OEM_PA2 0xEC
  253. #define VK_OEM_PA3 0xED
  254. #define VK_OEM_WSCTRL 0xEE
  255. #define VK_OEM_CUSEL 0xEF
  256. #define VK_OEM_ATTN 0xF0
  257. #define VK_OEM_FINISH 0xF1
  258. #define VK_OEM_COPY 0xF2
  259. #define VK_OEM_AUTO 0xF3
  260. #define VK_OEM_ENLW 0xF4
  261. #define VK_OEM_BACKTAB 0xF5
  262. #define VK_ATTN 0xF6
  263. #define VK_CRSEL 0xF7
  264. #define VK_EXSEL 0xF8
  265. #define VK_EREOF 0xF9
  266. #define VK_PLAY 0xFA
  267. #define VK_ZOOM 0xFB
  268. #define VK_NONAME 0xFC
  269. #define VK_PA1 0xFD
  270. #define VK_OEM_CLEAR 0xFE
  271. /*
  272. * 0xFF : reserved
  273. */
  274. /*
  275. * Window Messages
  276. */
  277. #define WM_NULL 0x0000
  278. #define WM_CREATE 0x0001
  279. #define WM_DESTROY 0x0002
  280. #define WM_MOVE 0x0003
  281. #define WM_SIZE 0x0005
  282. #define WM_ACTIVATE 0x0006
  283. /*
  284. * WM_ACTIVATE state values
  285. */
  286. #define WA_INACTIVE 0
  287. #define WA_ACTIVE 1
  288. #define WA_CLICKACTIVE 2
  289. #define WM_SETFOCUS 0x0007
  290. #define WM_KILLFOCUS 0x0008
  291. #define WM_ENABLE 0x000A
  292. #define WM_SETREDRAW 0x000B
  293. #define WM_SETTEXT 0x000C
  294. #define WM_GETTEXT 0x000D
  295. #define WM_GETTEXTLENGTH 0x000E
  296. #define WM_PAINT 0x000F
  297. #define WM_CLOSE 0x0010
  298. #ifndef _WIN32_WCE
  299. #define WM_QUERYENDSESSION 0x0011
  300. #define WM_QUERYOPEN 0x0013
  301. #define WM_ENDSESSION 0x0016
  302. #endif
  303. #define WM_QUIT 0x0012
  304. #define WM_ERASEBKGND 0x0014
  305. #define WM_SYSCOLORCHANGE 0x0015
  306. #define WM_SHOWWINDOW 0x0018
  307. #define WM_WININICHANGE 0x001A
  308. #if(WINVER >= 0x0400)
  309. #define WM_SETTINGCHANGE WM_WININICHANGE
  310. #endif /* WINVER >= 0x0400 */
  311. #define WM_DEVMODECHANGE 0x001B
  312. #define WM_ACTIVATEAPP 0x001C
  313. #define WM_FONTCHANGE 0x001D
  314. #define WM_TIMECHANGE 0x001E
  315. #define WM_CANCELMODE 0x001F
  316. #define WM_SETCURSOR 0x0020
  317. #define WM_MOUSEACTIVATE 0x0021
  318. #define WM_CHILDACTIVATE 0x0022
  319. #define WM_QUEUESYNC 0x0023
  320. #define WM_GETMINMAXINFO 0x0024
  321. #define WM_PAINTICON 0x0026
  322. #define WM_ICONERASEBKGND 0x0027
  323. #define WM_NEXTDLGCTL 0x0028
  324. #define WM_SPOOLERSTATUS 0x002A
  325. #define WM_DRAWITEM 0x002B
  326. #define WM_MEASUREITEM 0x002C
  327. #define WM_DELETEITEM 0x002D
  328. #define WM_VKEYTOITEM 0x002E
  329. #define WM_CHARTOITEM 0x002F
  330. #define WM_SETFONT 0x0030
  331. #define WM_GETFONT 0x0031
  332. #define WM_SETHOTKEY 0x0032
  333. #define WM_GETHOTKEY 0x0033
  334. #define WM_QUERYDRAGICON 0x0037
  335. #define WM_COMPAREITEM 0x0039
  336. #if(WINVER >= 0x0500)
  337. #ifndef _WIN32_WCE
  338. #define WM_GETOBJECT 0x003D
  339. #endif
  340. #endif /* WINVER >= 0x0500 */
  341. #define WM_COMPACTING 0x0041
  342. #define WM_COMMNOTIFY 0x0044 /* no longer suported */
  343. #define WM_WINDOWPOSCHANGING 0x0046
  344. #define WM_WINDOWPOSCHANGED 0x0047
  345. #define WM_POWER 0x0048
  346. /*
  347. * wParam for WM_POWER window message and DRV_POWER driver notification
  348. */
  349. #define PWR_OK 1
  350. #define PWR_FAIL (-1)
  351. #define PWR_SUSPENDREQUEST 1
  352. #define PWR_SUSPENDRESUME 2
  353. #define PWR_CRITICALRESUME 3
  354. #define WM_COPYDATA 0x004A
  355. #define WM_CANCELJOURNAL 0x004B
  356. #if(WINVER >= 0x0400)
  357. #define WM_NOTIFY 0x004E
  358. #define WM_INPUTLANGCHANGEREQUEST 0x0050
  359. #define WM_INPUTLANGCHANGE 0x0051
  360. #define WM_TCARD 0x0052
  361. #define WM_HELP 0x0053
  362. #define WM_USERCHANGED 0x0054
  363. #define WM_NOTIFYFORMAT 0x0055
  364. #define NFR_ANSI 1
  365. #define NFR_UNICODE 2
  366. #define NF_QUERY 3
  367. #define NF_REQUERY 4
  368. #define WM_CONTEXTMENU 0x007B
  369. #define WM_STYLECHANGING 0x007C
  370. #define WM_STYLECHANGED 0x007D
  371. #define WM_DISPLAYCHANGE 0x007E
  372. #define WM_GETICON 0x007F
  373. #define WM_SETICON 0x0080
  374. #endif /* WINVER >= 0x0400 */
  375. #define WM_NCCREATE 0x0081
  376. #define WM_NCDESTROY 0x0082
  377. #define WM_NCCALCSIZE 0x0083
  378. #define WM_NCHITTEST 0x0084
  379. #define WM_NCPAINT 0x0085
  380. #define WM_NCACTIVATE 0x0086
  381. #define WM_GETDLGCODE 0x0087
  382. #ifndef _WIN32_WCE
  383. #define WM_SYNCPAINT 0x0088
  384. #endif
  385. #define WM_NCMOUSEMOVE 0x00A0
  386. #define WM_NCLBUTTONDOWN 0x00A1
  387. #define WM_NCLBUTTONUP 0x00A2
  388. #define WM_NCLBUTTONDBLCLK 0x00A3
  389. #define WM_NCRBUTTONDOWN 0x00A4
  390. #define WM_NCRBUTTONUP 0x00A5
  391. #define WM_NCRBUTTONDBLCLK 0x00A6
  392. #define WM_NCMBUTTONDOWN 0x00A7
  393. #define WM_NCMBUTTONUP 0x00A8
  394. #define WM_NCMBUTTONDBLCLK 0x00A9
  395. #if(_WIN32_WINNT >= 0x0500)
  396. #define WM_NCXBUTTONDOWN 0x00AB
  397. #define WM_NCXBUTTONUP 0x00AC
  398. #define WM_NCXBUTTONDBLCLK 0x00AD
  399. #endif /* _WIN32_WINNT >= 0x0500 */
  400. #if(_WIN32_WINNT >= 0x0501)
  401. #define WM_INPUT 0x00FF
  402. #endif /* _WIN32_WINNT >= 0x0501 */
  403. #define WM_KEYFIRST 0x0100
  404. #define WM_KEYDOWN 0x0100
  405. #define WM_KEYUP 0x0101
  406. #define WM_CHAR 0x0102
  407. #define WM_DEADCHAR 0x0103
  408. #define WM_SYSKEYDOWN 0x0104
  409. #define WM_SYSKEYUP 0x0105
  410. #define WM_SYSCHAR 0x0106
  411. #define WM_SYSDEADCHAR 0x0107
  412. #if(_WIN32_WINNT >= 0x0501)
  413. #define WM_UNICHAR 0x0109
  414. #define WM_KEYLAST 0x0109
  415. #define UNICODE_NOCHAR 0xFFFF
  416. #else
  417. #define WM_KEYLAST 0x0108
  418. #endif /* _WIN32_WINNT >= 0x0501 */
  419. #if(WINVER >= 0x0400)
  420. #define WM_IME_STARTCOMPOSITION 0x010D
  421. #define WM_IME_ENDCOMPOSITION 0x010E
  422. #define WM_IME_COMPOSITION 0x010F
  423. #define WM_IME_KEYLAST 0x010F
  424. #endif /* WINVER >= 0x0400 */
  425. #define WM_INITDIALOG 0x0110
  426. #define WM_COMMAND 0x0111
  427. #define WM_SYSCOMMAND 0x0112
  428. #define WM_TIMER 0x0113
  429. #define WM_HSCROLL 0x0114
  430. #define WM_VSCROLL 0x0115
  431. #define WM_INITMENU 0x0116
  432. #define WM_INITMENUPOPUP 0x0117
  433. #define WM_MENUSELECT 0x011F
  434. #define WM_MENUCHAR 0x0120
  435. #define WM_ENTERIDLE 0x0121
  436. #if(WINVER >= 0x0500)
  437. #ifndef _WIN32_WCE
  438. #define WM_MENURBUTTONUP 0x0122
  439. #define WM_MENUDRAG 0x0123
  440. #define WM_MENUGETOBJECT 0x0124
  441. #define WM_UNINITMENUPOPUP 0x0125
  442. #define WM_MENUCOMMAND 0x0126
  443. #ifndef _WIN32_WCE
  444. #if(_WIN32_WINNT >= 0x0500)
  445. #define WM_CHANGEUISTATE 0x0127
  446. #define WM_UPDATEUISTATE 0x0128
  447. #define WM_QUERYUISTATE 0x0129
  448. /*
  449. * LOWORD(wParam) values in WM_*UISTATE*
  450. */
  451. #define UIS_SET 1
  452. #define UIS_CLEAR 2
  453. #define UIS_INITIALIZE 3
  454. /*
  455. * HIWORD(wParam) values in WM_*UISTATE*
  456. */
  457. #define UISF_HIDEFOCUS 0x1
  458. #define UISF_HIDEACCEL 0x2
  459. #if(_WIN32_WINNT >= 0x0501)
  460. #define UISF_ACTIVE 0x4
  461. #endif /* _WIN32_WINNT >= 0x0501 */
  462. #endif /* _WIN32_WINNT >= 0x0500 */
  463. #endif
  464. #endif
  465. #endif /* WINVER >= 0x0500 */
  466. #define WM_CTLCOLORMSGBOX 0x0132
  467. #define WM_CTLCOLOREDIT 0x0133
  468. #define WM_CTLCOLORLISTBOX 0x0134
  469. #define WM_CTLCOLORBTN 0x0135
  470. #define WM_CTLCOLORDLG 0x0136
  471. #define WM_CTLCOLORSCROLLBAR 0x0137
  472. #define WM_CTLCOLORSTATIC 0x0138
  473. #define MN_GETHMENU 0x01E1
  474. #define WM_MOUSEFIRST 0x0200
  475. #define WM_MOUSEMOVE 0x0200
  476. #define WM_LBUTTONDOWN 0x0201
  477. #define WM_LBUTTONUP 0x0202
  478. #define WM_LBUTTONDBLCLK 0x0203
  479. #define WM_RBUTTONDOWN 0x0204
  480. #define WM_RBUTTONUP 0x0205
  481. #define WM_RBUTTONDBLCLK 0x0206
  482. #define WM_MBUTTONDOWN 0x0207
  483. #define WM_MBUTTONUP 0x0208
  484. #define WM_MBUTTONDBLCLK 0x0209
  485. #if (_WIN32_WINNT >= 0x0400) || (_WIN32_WINDOWS > 0x0400)
  486. #define WM_MOUSEWHEEL 0x020A
  487. #endif
  488. #if (_WIN32_WINNT >= 0x0500)
  489. #define WM_XBUTTONDOWN 0x020B
  490. #define WM_XBUTTONUP 0x020C
  491. #define WM_XBUTTONDBLCLK 0x020D
  492. #endif
  493. #if (_WIN32_WINNT >= 0x0500)
  494. #define WM_MOUSELAST 0x020D
  495. #elif (_WIN32_WINNT >= 0x0400) || (_WIN32_WINDOWS > 0x0400)
  496. #define WM_MOUSELAST 0x020A
  497. #else
  498. #define WM_MOUSELAST 0x0209
  499. #endif /* (_WIN32_WINNT >= 0x0500) */
  500. #if(_WIN32_WINNT >= 0x0400)
  501. /* Value for rolling one detent */
  502. #define WHEEL_DELTA 120
  503. #define GET_WHEEL_DELTA_WPARAM(wParam) ((short)HIWORD(wParam))
  504. /* Setting to scroll one page for SPI_GET/SETWHEELSCROLLLINES */
  505. #define WHEEL_PAGESCROLL (UINT_MAX)
  506. #endif /* _WIN32_WINNT >= 0x0400 */
  507. #if(_WIN32_WINNT >= 0x0500)
  508. #define GET_KEYSTATE_WPARAM(wParam) (LOWORD(wParam))
  509. #define GET_NCHITTEST_WPARAM(wParam) ((short)LOWORD(wParam))
  510. #define GET_XBUTTON_WPARAM(wParam) (HIWORD(wParam))
  511. /* XButton values are WORD flags */
  512. #define XBUTTON1 0x0001
  513. #define XBUTTON2 0x0002
  514. /* Were there to be an XBUTTON3, its value would be 0x0004 */
  515. #endif /* _WIN32_WINNT >= 0x0500 */
  516. #define WM_PARENTNOTIFY 0x0210
  517. #define WM_ENTERMENULOOP 0x0211
  518. #define WM_EXITMENULOOP 0x0212
  519. #if(WINVER >= 0x0400)
  520. #define WM_NEXTMENU 0x0213
  521. #define WM_SIZING 0x0214
  522. #define WM_CAPTURECHANGED 0x0215
  523. #define WM_MOVING 0x0216
  524. #define WM_POWERBROADCAST 0x0218
  525. #endif /* WINVER >= 0x0400 */
  526. #if(WINVER >= 0x0400)
  527. #define WM_DEVICECHANGE 0x0219
  528. #endif /* WINVER >= 0x0400 */
  529. #define WM_MDICREATE 0x0220
  530. #define WM_MDIDESTROY 0x0221
  531. #define WM_MDIACTIVATE 0x0222
  532. #define WM_MDIRESTORE 0x0223
  533. #define WM_MDINEXT 0x0224
  534. #define WM_MDIMAXIMIZE 0x0225
  535. #define WM_MDITILE 0x0226
  536. #define WM_MDICASCADE 0x0227
  537. #define WM_MDIICONARRANGE 0x0228
  538. #define WM_MDIGETACTIVE 0x0229
  539. #define WM_MDISETMENU 0x0230
  540. #define WM_ENTERSIZEMOVE 0x0231
  541. #define WM_EXITSIZEMOVE 0x0232
  542. #define WM_DROPFILES 0x0233
  543. #define WM_MDIREFRESHMENU 0x0234
  544. #if(WINVER >= 0x0400)
  545. #define WM_IME_SETCONTEXT 0x0281
  546. #define WM_IME_NOTIFY 0x0282
  547. #define WM_IME_CONTROL 0x0283
  548. #define WM_IME_COMPOSITIONFULL 0x0284
  549. #define WM_IME_SELECT 0x0285
  550. #define WM_IME_CHAR 0x0286
  551. #endif /* WINVER >= 0x0400 */
  552. #if(WINVER >= 0x0500)
  553. #define WM_IME_REQUEST 0x0288
  554. #endif /* WINVER >= 0x0500 */
  555. #if(WINVER >= 0x0400)
  556. #define WM_IME_KEYDOWN 0x0290
  557. #define WM_IME_KEYUP 0x0291
  558. #endif /* WINVER >= 0x0400 */
  559. #if((_WIN32_WINNT >= 0x0400) || (WINVER >= 0x0500))
  560. #define WM_MOUSEHOVER 0x02A1
  561. #define WM_MOUSELEAVE 0x02A3
  562. #endif
  563. #if(WINVER >= 0x0500)
  564. #define WM_NCMOUSEHOVER 0x02A0
  565. #define WM_NCMOUSELEAVE 0x02A2
  566. #endif /* WINVER >= 0x0500 */
  567. #if(_WIN32_WINNT >= 0x0501)
  568. #define WM_WTSSESSION_CHANGE 0x02B1
  569. #define WM_TABLET_FIRST 0x02c0
  570. #define WM_TABLET_LAST 0x02df
  571. #endif /* _WIN32_WINNT >= 0x0501 */
  572. #define WM_CUT 0x0300
  573. #define WM_COPY 0x0301
  574. #define WM_PASTE 0x0302
  575. #define WM_CLEAR 0x0303
  576. #define WM_UNDO 0x0304
  577. #define WM_RENDERFORMAT 0x0305
  578. #define WM_RENDERALLFORMATS 0x0306
  579. #define WM_DESTROYCLIPBOARD 0x0307
  580. #define WM_DRAWCLIPBOARD 0x0308
  581. #define WM_PAINTCLIPBOARD 0x0309
  582. #define WM_VSCROLLCLIPBOARD 0x030A
  583. #define WM_SIZECLIPBOARD 0x030B
  584. #define WM_ASKCBFORMATNAME 0x030C
  585. #define WM_CHANGECBCHAIN 0x030D
  586. #define WM_HSCROLLCLIPBOARD 0x030E
  587. #define WM_QUERYNEWPALETTE 0x030F
  588. #define WM_PALETTEISCHANGING 0x0310
  589. #define WM_PALETTECHANGED 0x0311
  590. #define WM_HOTKEY 0x0312
  591. #if(WINVER >= 0x0400)
  592. #define WM_PRINT 0x0317
  593. #define WM_PRINTCLIENT 0x0318
  594. #endif /* WINVER >= 0x0400 */
  595. #if(_WIN32_WINNT >= 0x0500)
  596. #define WM_APPCOMMAND 0x0319
  597. #endif /* _WIN32_WINNT >= 0x0500 */
  598. #if(_WIN32_WINNT >= 0x0501)
  599. #define WM_THEMECHANGED 0x031A
  600. #endif /* _WIN32_WINNT >= 0x0501 */
  601. #if(WINVER >= 0x0400)
  602. #define WM_HANDHELDFIRST 0x0358
  603. #define WM_HANDHELDLAST 0x035F
  604. #define WM_AFXFIRST 0x0360
  605. #define WM_AFXLAST 0x037F
  606. #endif /* WINVER >= 0x0400 */
  607. #define WM_PENWINFIRST 0x0380
  608. #define WM_PENWINLAST 0x038F
  609. #if(WINVER >= 0x0400)
  610. #define WM_APP 0x8000
  611. #endif /* WINVER >= 0x0400 */
  612. /*
  613. * NOTE: All Message Numbers below 0x0400 are RESERVED.
  614. *
  615. * Private Window Messages Start Here:
  616. */
  617. #define WM_USER 0x0400
  618. #if(WINVER >= 0x0400)
  619. /* wParam for WM_SIZING message */
  620. #define WMSZ_LEFT 1
  621. #define WMSZ_RIGHT 2
  622. #define WMSZ_TOP 3
  623. #define WMSZ_TOPLEFT 4
  624. #define WMSZ_TOPRIGHT 5
  625. #define WMSZ_BOTTOM 6
  626. #define WMSZ_BOTTOMLEFT 7
  627. #define WMSZ_BOTTOMRIGHT 8
  628. #endif /* WINVER >= 0x0400 */
  629. #ifndef NONCMESSAGES
  630. /*
  631. * WM_NCHITTEST and MOUSEHOOKSTRUCT Mouse Position Codes
  632. */
  633. #define HTERROR (-2)
  634. #define HTTRANSPARENT (-1)
  635. #define HTNOWHERE 0
  636. #define HTCLIENT 1
  637. #define HTCAPTION 2
  638. #define HTSYSMENU 3
  639. #define HTGROWBOX 4
  640. #define HTSIZE HTGROWBOX
  641. #define HTMENU 5
  642. #define HTHSCROLL 6
  643. #define HTVSCROLL 7
  644. #define HTMINBUTTON 8
  645. #define HTMAXBUTTON 9
  646. #define HTLEFT 10
  647. #define HTRIGHT 11
  648. #define HTTOP 12
  649. #define HTTOPLEFT 13
  650. #define HTTOPRIGHT 14
  651. #define HTBOTTOM 15
  652. #define HTBOTTOMLEFT 16
  653. #define HTBOTTOMRIGHT 17
  654. #define HTBORDER 18
  655. #define HTREDUCE HTMINBUTTON
  656. #define HTZOOM HTMAXBUTTON
  657. #define HTSIZEFIRST HTLEFT
  658. #define HTSIZELAST HTBOTTOMRIGHT
  659. #if(WINVER >= 0x0400)
  660. #define HTOBJECT 19
  661. #define HTCLOSE 20
  662. #define HTHELP 21
  663. #endif /* WINVER >= 0x0400 */
  664. /*
  665. * SendMessageTimeout values
  666. */
  667. #define SMTO_NORMAL 0x0000
  668. #define SMTO_BLOCK 0x0001
  669. #define SMTO_ABORTIFHUNG 0x0002
  670. #if(WINVER >= 0x0500)
  671. #define SMTO_NOTIMEOUTIFNOTHUNG 0x0008
  672. #endif /* WINVER >= 0x0500 */
  673. #endif /* !NONCMESSAGES */
  674. /*
  675. * WM_MOUSEACTIVATE Return Codes
  676. */
  677. #define MA_ACTIVATE 1
  678. #define MA_ACTIVATEANDEAT 2
  679. #define MA_NOACTIVATE 3
  680. #define MA_NOACTIVATEANDEAT 4
  681. /*
  682. * WM_SETICON / WM_GETICON Type Codes
  683. */
  684. #define ICON_SMALL 0
  685. #define ICON_BIG 1
  686. #if(_WIN32_WINNT >= 0x0501)
  687. #define ICON_SMALL2 2
  688. #endif /* _WIN32_WINNT >= 0x0501 */
  689. /*
  690. * WM_SIZE message wParam values
  691. */
  692. #define SIZE_RESTORED 0
  693. #define SIZE_MINIMIZED 1
  694. #define SIZE_MAXIMIZED 2
  695. #define SIZE_MAXSHOW 3
  696. #define SIZE_MAXHIDE 4
  697. /*
  698. * Obsolete constant names
  699. */
  700. #define SIZENORMAL SIZE_RESTORED
  701. #define SIZEICONIC SIZE_MINIMIZED
  702. #define SIZEFULLSCREEN SIZE_MAXIMIZED
  703. #define SIZEZOOMSHOW SIZE_MAXSHOW
  704. #define SIZEZOOMHIDE SIZE_MAXHIDE
  705. /*
  706. * WM_NCCALCSIZE "window valid rect" return values
  707. */
  708. #define WVR_ALIGNTOP 0x0010
  709. #define WVR_ALIGNLEFT 0x0020
  710. #define WVR_ALIGNBOTTOM 0x0040
  711. #define WVR_ALIGNRIGHT 0x0080
  712. #define WVR_HREDRAW 0x0100
  713. #define WVR_VREDRAW 0x0200
  714. #define WVR_REDRAW (WVR_HREDRAW | \
  715. WVR_VREDRAW)
  716. #define WVR_VALIDRECTS 0x0400
  717. #ifndef NOKEYSTATES
  718. /*
  719. * Key State Masks for Mouse Messages
  720. */
  721. #define MK_LBUTTON 0x0001
  722. #define MK_RBUTTON 0x0002
  723. #define MK_SHIFT 0x0004
  724. #define MK_CONTROL 0x0008
  725. #define MK_MBUTTON 0x0010
  726. #if(_WIN32_WINNT >= 0x0500)
  727. #define MK_XBUTTON1 0x0020
  728. #define MK_XBUTTON2 0x0040
  729. #endif /* _WIN32_WINNT >= 0x0500 */
  730. #endif /* !NOKEYSTATES */
  731. #if(_WIN32_WINNT >= 0x0400)
  732. #ifndef NOTRACKMOUSEEVENT
  733. #define TME_HOVER 0x00000001
  734. #define TME_LEAVE 0x00000002
  735. #if(WINVER >= 0x0500)
  736. #define TME_NONCLIENT 0x00000010
  737. #endif /* WINVER >= 0x0500 */
  738. #define TME_QUERY 0x40000000
  739. #define TME_CANCEL 0x80000000
  740. #define HOVER_DEFAULT 0xFFFFFFFF
  741. #endif /* _WIN32_WINNT >= 0x0400 */
  742. #if(_WIN32_WINNT >= 0x0400)
  743. #endif /* !NOTRACKMOUSEEVENT */
  744. #endif /* _WIN32_WINNT >= 0x0400 */
  745. /*
  746. * Window Styles
  747. */
  748. #define WS_OVERLAPPED 0x00000000L
  749. #define WS_POPUP 0x80000000L
  750. #define WS_CHILD 0x40000000L
  751. #define WS_MINIMIZE 0x20000000L
  752. #define WS_VISIBLE 0x10000000L
  753. #define WS_DISABLED 0x08000000L
  754. #define WS_CLIPSIBLINGS 0x04000000L
  755. #define WS_CLIPCHILDREN 0x02000000L
  756. #define WS_MAXIMIZE 0x01000000L
  757. #define WS_CAPTION 0x00C00000L /* WS_BORDER | WS_DLGFRAME */
  758. #define WS_BORDER 0x00800000L
  759. #define WS_DLGFRAME 0x00400000L
  760. #define WS_VSCROLL 0x00200000L
  761. #define WS_HSCROLL 0x00100000L
  762. #define WS_SYSMENU 0x00080000L
  763. #define WS_THICKFRAME 0x00040000L
  764. #define WS_GROUP 0x00020000L
  765. #define WS_TABSTOP 0x00010000L
  766. #define WS_MINIMIZEBOX 0x00020000L
  767. #define WS_MAXIMIZEBOX 0x00010000L
  768. #define WS_TILED WS_OVERLAPPED
  769. #define WS_ICONIC WS_MINIMIZE
  770. #define WS_SIZEBOX WS_THICKFRAME
  771. #define WS_TILEDWINDOW WS_OVERLAPPEDWINDOW
  772. /*
  773. * Common Window Styles
  774. */
  775. #define WS_OVERLAPPEDWINDOW (WS_OVERLAPPED | \
  776. WS_CAPTION | \
  777. WS_SYSMENU | \
  778. WS_THICKFRAME | \
  779. WS_MINIMIZEBOX | \
  780. WS_MAXIMIZEBOX)
  781. #define WS_POPUPWINDOW (WS_POPUP | \
  782. WS_BORDER | \
  783. WS_SYSMENU)
  784. #define WS_CHILDWINDOW (WS_CHILD)
  785. /*
  786. * Extended Window Styles
  787. */
  788. #define WS_EX_DLGMODALFRAME 0x00000001L
  789. #define WS_EX_NOPARENTNOTIFY 0x00000004L
  790. #define WS_EX_TOPMOST 0x00000008L
  791. #define WS_EX_ACCEPTFILES 0x00000010L
  792. #define WS_EX_TRANSPARENT 0x00000020L
  793. #if(WINVER >= 0x0400)
  794. #define WS_EX_MDICHILD 0x00000040L
  795. #define WS_EX_TOOLWINDOW 0x00000080L
  796. #define WS_EX_WINDOWEDGE 0x00000100L
  797. #define WS_EX_CLIENTEDGE 0x00000200L
  798. #define WS_EX_CONTEXTHELP 0x00000400L
  799. #endif /* WINVER >= 0x0400 */
  800. #if(WINVER >= 0x0400)
  801. #define WS_EX_RIGHT 0x00001000L
  802. #define WS_EX_LEFT 0x00000000L
  803. #define WS_EX_RTLREADING 0x00002000L
  804. #define WS_EX_LTRREADING 0x00000000L
  805. #define WS_EX_LEFTSCROLLBAR 0x00004000L
  806. #define WS_EX_RIGHTSCROLLBAR 0x00000000L
  807. #define WS_EX_CONTROLPARENT 0x00010000L
  808. #define WS_EX_STATICEDGE 0x00020000L
  809. #define WS_EX_APPWINDOW 0x00040000L
  810. #define WS_EX_OVERLAPPEDWINDOW (WS_EX_WINDOWEDGE | WS_EX_CLIENTEDGE)
  811. #define WS_EX_PALETTEWINDOW (WS_EX_WINDOWEDGE | WS_EX_TOOLWINDOW | WS_EX_TOPMOST)
  812. #endif /* WINVER >= 0x0400 */
  813. #if(_WIN32_WINNT >= 0x0500)
  814. #define WS_EX_LAYERED 0x00080000
  815. #endif /* _WIN32_WINNT >= 0x0500 */
  816. #if(WINVER >= 0x0500)
  817. #define WS_EX_NOINHERITLAYOUT 0x00100000L // Disable inheritence of mirroring by children
  818. #define WS_EX_LAYOUTRTL 0x00400000L // Right to left mirroring
  819. #endif /* WINVER >= 0x0500 */
  820. #if(_WIN32_WINNT >= 0x0501)
  821. #define WS_EX_COMPOSITED 0x02000000L
  822. #endif /* _WIN32_WINNT >= 0x0501 */
  823. #if(_WIN32_WINNT >= 0x0500)
  824. #define WS_EX_NOACTIVATE 0x08000000L
  825. #endif /* _WIN32_WINNT >= 0x0500 */
  826. /*
  827. * Class styles
  828. */
  829. #define CS_VREDRAW 0x0001
  830. #define CS_HREDRAW 0x0002
  831. #define CS_DBLCLKS 0x0008
  832. #define CS_OWNDC 0x0020
  833. #define CS_CLASSDC 0x0040
  834. #define CS_PARENTDC 0x0080
  835. #define CS_NOCLOSE 0x0200
  836. #define CS_SAVEBITS 0x0800
  837. #define CS_BYTEALIGNCLIENT 0x1000
  838. #define CS_BYTEALIGNWINDOW 0x2000
  839. #define CS_GLOBALCLASS 0x4000
  840. #define CS_IME 0x00010000
  841. #if(_WIN32_WINNT >= 0x0501)
  842. #define CS_DROPSHADOW 0x00020000
  843. #endif /* _WIN32_WINNT >= 0x0501 */
  844. /*
  845. * Predefined Clipboard Formats
  846. */
  847. #define CF_TEXT 1
  848. #define CF_BITMAP 2
  849. #define CF_METAFILEPICT 3
  850. #define CF_SYLK 4
  851. #define CF_DIF 5
  852. #define CF_TIFF 6
  853. #define CF_OEMTEXT 7
  854. #define CF_DIB 8
  855. #define CF_PALETTE 9
  856. #define CF_PENDATA 10
  857. #define CF_RIFF 11
  858. #define CF_WAVE 12
  859. #define CF_UNICODETEXT 13
  860. #define CF_ENHMETAFILE 14
  861. #if(WINVER >= 0x0400)
  862. #define CF_HDROP 15
  863. #define CF_LOCALE 16
  864. #endif /* WINVER >= 0x0400 */
  865. #if(WINVER >= 0x0500)
  866. #define CF_DIBV5 17
  867. #endif /* WINVER >= 0x0500 */
  868. #if(WINVER >= 0x0500)
  869. #define CF_MAX 18
  870. #elif(WINVER >= 0x0400)
  871. #define CF_MAX 17
  872. #else
  873. #define CF_MAX 15
  874. #endif
  875. #define CF_OWNERDISPLAY 0x0080
  876. #define CF_DSPTEXT 0x0081
  877. #define CF_DSPBITMAP 0x0082
  878. #define CF_DSPMETAFILEPICT 0x0083
  879. #define CF_DSPENHMETAFILE 0x008E
  880. /*
  881. * "Private" formats don't get GlobalFree()'d
  882. */
  883. #define CF_PRIVATEFIRST 0x0200
  884. #define CF_PRIVATELAST 0x02FF
  885. /*
  886. * "GDIOBJ" formats do get DeleteObject()'d
  887. */
  888. #define CF_GDIOBJFIRST 0x0300
  889. #define CF_GDIOBJLAST 0x03FF
  890. /* ;win40 -- A lot of MF_* flags have been renamed as MFT_* and MFS_* flags */
  891. /*
  892. * Menu flags for Add/Check/EnableMenuItem()
  893. */
  894. #define MF_INSERT 0x00000000L
  895. #define MF_CHANGE 0x00000080L
  896. #define MF_APPEND 0x00000100L
  897. #define MF_DELETE 0x00000200L
  898. #define MF_REMOVE 0x00001000L
  899. #define MF_BYCOMMAND 0x00000000L
  900. #define MF_BYPOSITION 0x00000400L
  901. #define MF_SEPARATOR 0x00000800L
  902. #define MF_ENABLED 0x00000000L
  903. #define MF_GRAYED 0x00000001L
  904. #define MF_DISABLED 0x00000002L
  905. #define MF_UNCHECKED 0x00000000L
  906. #define MF_CHECKED 0x00000008L
  907. #define MF_USECHECKBITMAPS 0x00000200L
  908. #define MF_STRING 0x00000000L
  909. #define MF_BITMAP 0x00000004L
  910. #define MF_OWNERDRAW 0x00000100L
  911. #define MF_POPUP 0x00000010L
  912. #define MF_MENUBARBREAK 0x00000020L
  913. #define MF_MENUBREAK 0x00000040L
  914. #define MF_UNHILITE 0x00000000L
  915. #define MF_HILITE 0x00000080L
  916. #if(WINVER >= 0x0400)
  917. #define MF_DEFAULT 0x00001000L
  918. #endif /* WINVER >= 0x0400 */
  919. #define MF_SYSMENU 0x00002000L
  920. #define MF_HELP 0x00004000L
  921. #if(WINVER >= 0x0400)
  922. #define MF_RIGHTJUSTIFY 0x00004000L
  923. #endif /* WINVER >= 0x0400 */
  924. #define MF_MOUSESELECT 0x00008000L
  925. #if(WINVER >= 0x0400)
  926. #define MF_END 0x00000080L /* Obsolete -- only used by old RES files */
  927. #endif /* WINVER >= 0x0400 */
  928. #if(WINVER >= 0x0400)
  929. #define MFT_STRING MF_STRING
  930. #define MFT_BITMAP MF_BITMAP
  931. #define MFT_MENUBARBREAK MF_MENUBARBREAK
  932. #define MFT_MENUBREAK MF_MENUBREAK
  933. #define MFT_OWNERDRAW MF_OWNERDRAW
  934. #define MFT_RADIOCHECK 0x00000200L
  935. #define MFT_SEPARATOR MF_SEPARATOR
  936. #define MFT_RIGHTORDER 0x00002000L
  937. #define MFT_RIGHTJUSTIFY MF_RIGHTJUSTIFY
  938. /* Menu flags for Add/Check/EnableMenuItem() */
  939. #define MFS_GRAYED 0x00000003L
  940. #define MFS_DISABLED MFS_GRAYED
  941. #define MFS_CHECKED MF_CHECKED
  942. #define MFS_HILITE MF_HILITE
  943. #define MFS_ENABLED MF_ENABLED
  944. #define MFS_UNCHECKED MF_UNCHECKED
  945. #define MFS_UNHILITE MF_UNHILITE
  946. #define MFS_DEFAULT MF_DEFAULT
  947. #endif /* WINVER >= 0x0400 */
  948. #define MF_END 0x00000080L
  949. /*
  950. * System Menu Command Values
  951. */
  952. #define SC_SIZE 0xF000
  953. #define SC_MOVE 0xF010
  954. #define SC_MINIMIZE 0xF020
  955. #define SC_MAXIMIZE 0xF030
  956. #define SC_NEXTWINDOW 0xF040
  957. #define SC_PREVWINDOW 0xF050
  958. #define SC_CLOSE 0xF060
  959. #define SC_VSCROLL 0xF070
  960. #define SC_HSCROLL 0xF080
  961. #define SC_MOUSEMENU 0xF090
  962. #define SC_KEYMENU 0xF100
  963. #define SC_ARRANGE 0xF110
  964. #define SC_RESTORE 0xF120
  965. #define SC_TASKLIST 0xF130
  966. #define SC_SCREENSAVE 0xF140
  967. #define SC_HOTKEY 0xF150
  968. #if(WINVER >= 0x0400)
  969. #define SC_DEFAULT 0xF160
  970. #define SC_MONITORPOWER 0xF170
  971. #define SC_CONTEXTHELP 0xF180
  972. #define SC_SEPARATOR 0xF00F
  973. #endif /* WINVER >= 0x0400 */
  974. /*
  975. * Obsolete names
  976. */
  977. #define SC_ICON SC_MINIMIZE
  978. #define SC_ZOOM SC_MAXIMIZE
  979. /*
  980. * OEM Resource Ordinal Numbers
  981. */
  982. #define OBM_CLOSE 32754
  983. #define OBM_UPARROW 32753
  984. #define OBM_DNARROW 32752
  985. #define OBM_RGARROW 32751
  986. #define OBM_LFARROW 32750
  987. #define OBM_REDUCE 32749
  988. #define OBM_ZOOM 32748
  989. #define OBM_RESTORE 32747
  990. #define OBM_REDUCED 32746
  991. #define OBM_ZOOMD 32745
  992. #define OBM_RESTORED 32744
  993. #define OBM_UPARROWD 32743
  994. #define OBM_DNARROWD 32742
  995. #define OBM_RGARROWD 32741
  996. #define OBM_LFARROWD 32740
  997. #define OBM_MNARROW 32739
  998. #define OBM_COMBO 32738
  999. #define OBM_UPARROWI 32737
  1000. #define OBM_DNARROWI 32736
  1001. #define OBM_RGARROWI 32735
  1002. #define OBM_LFARROWI 32734
  1003. #define OBM_OLD_CLOSE 32767
  1004. #define OBM_SIZE 32766
  1005. #define OBM_OLD_UPARROW 32765
  1006. #define OBM_OLD_DNARROW 32764
  1007. #define OBM_OLD_RGARROW 32763
  1008. #define OBM_OLD_LFARROW 32762
  1009. #define OBM_BTSIZE 32761
  1010. #define OBM_CHECK 32760
  1011. #define OBM_CHECKBOXES 32759
  1012. #define OBM_BTNCORNERS 32758
  1013. #define OBM_OLD_REDUCE 32757
  1014. #define OBM_OLD_ZOOM 32756
  1015. #define OBM_OLD_RESTORE 32755
  1016. #define OCR_NORMAL 32512
  1017. #define OCR_IBEAM 32513
  1018. #define OCR_WAIT 32514
  1019. #define OCR_CROSS 32515
  1020. #define OCR_UP 32516
  1021. #define OCR_SIZE 32640 /* OBSOLETE: use OCR_SIZEALL */
  1022. #define OCR_ICON 32641 /* OBSOLETE: use OCR_NORMAL */
  1023. #define OCR_SIZENWSE 32642
  1024. #define OCR_SIZENESW 32643
  1025. #define OCR_SIZEWE 32644
  1026. #define OCR_SIZENS 32645
  1027. #define OCR_SIZEALL 32646
  1028. #define OCR_ICOCUR 32647 /* OBSOLETE: use OIC_WINLOGO */
  1029. #define OCR_NO 32648
  1030. #if(WINVER >= 0x0500)
  1031. #define OCR_HAND 32649
  1032. #endif /* WINVER >= 0x0500 */
  1033. #if(WINVER >= 0x0400)
  1034. #define OCR_APPSTARTING 32650
  1035. #endif /* WINVER >= 0x0400 */
  1036. #define OIC_SAMPLE 32512
  1037. #define OIC_HAND 32513
  1038. #define OIC_QUES 32514
  1039. #define OIC_BANG 32515
  1040. #define OIC_NOTE 32516
  1041. #if(WINVER >= 0x0400)
  1042. #define OIC_WINLOGO 32517
  1043. #define OIC_WARNING OIC_BANG
  1044. #define OIC_ERROR OIC_HAND
  1045. #define OIC_INFORMATION OIC_NOTE
  1046. #endif /* WINVER >= 0x0400 */
  1047. /*
  1048. * Standard Icon IDs
  1049. */
  1050. #ifdef RC_INVOKED
  1051. #define IDI_APPLICATION 32512
  1052. #define IDI_HAND 32513
  1053. #define IDI_QUESTION 32514
  1054. #define IDI_EXCLAMATION 32515
  1055. #define IDI_ASTERISK 32516
  1056. #if(WINVER >= 0x0400)
  1057. #define IDI_WINLOGO 32517
  1058. #endif /* WINVER >= 0x0400 */
  1059. #else
  1060. #define IDI_APPLICATION MAKEINTRESOURCE(32512)
  1061. #define IDI_HAND MAKEINTRESOURCE(32513)
  1062. #define IDI_QUESTION MAKEINTRESOURCE(32514)
  1063. #define IDI_EXCLAMATION MAKEINTRESOURCE(32515)
  1064. #define IDI_ASTERISK MAKEINTRESOURCE(32516)
  1065. #if(WINVER >= 0x0400)
  1066. #define IDI_WINLOGO MAKEINTRESOURCE(32517)
  1067. #endif /* WINVER >= 0x0400 */
  1068. #endif /* RC_INVOKED */
  1069. #if(WINVER >= 0x0400)
  1070. #define IDI_WARNING IDI_EXCLAMATION
  1071. #define IDI_ERROR IDI_HAND
  1072. #define IDI_INFORMATION IDI_ASTERISK
  1073. #endif /* WINVER >= 0x0400 */
  1074. /*
  1075. * Dialog Box Command IDs
  1076. */
  1077. #define IDOK 1
  1078. #define IDCANCEL 2
  1079. #define IDABORT 3
  1080. #define IDRETRY 4
  1081. #define IDIGNORE 5
  1082. #define IDYES 6
  1083. #define IDNO 7
  1084. #if(WINVER >= 0x0400)
  1085. #define IDCLOSE 8
  1086. #define IDHELP 9
  1087. #endif /* WINVER >= 0x0400 */
  1088. #if(WINVER >= 0x0500)
  1089. #define IDTRYAGAIN 10
  1090. #define IDCONTINUE 11
  1091. #endif /* WINVER >= 0x0500 */
  1092. #if(WINVER >= 0x0501)
  1093. #ifndef IDTIMEOUT
  1094. #define IDTIMEOUT 32000
  1095. #endif
  1096. #endif /* WINVER >= 0x0501 */
  1097. /*
  1098. * Edit Control Styles
  1099. */
  1100. #define ES_LEFT 0x0000L
  1101. #define ES_CENTER 0x0001L
  1102. #define ES_RIGHT 0x0002L
  1103. #define ES_MULTILINE 0x0004L
  1104. #define ES_UPPERCASE 0x0008L
  1105. #define ES_LOWERCASE 0x0010L
  1106. #define ES_PASSWORD 0x0020L
  1107. #define ES_AUTOVSCROLL 0x0040L
  1108. #define ES_AUTOHSCROLL 0x0080L
  1109. #define ES_NOHIDESEL 0x0100L
  1110. #define ES_OEMCONVERT 0x0400L
  1111. #define ES_READONLY 0x0800L
  1112. #define ES_WANTRETURN 0x1000L
  1113. #if(WINVER >= 0x0400)
  1114. #define ES_NUMBER 0x2000L
  1115. #endif /* WINVER >= 0x0400 */
  1116. /*
  1117. * Edit Control Messages
  1118. */
  1119. #define EM_GETSEL 0x00B0
  1120. #define EM_SETSEL 0x00B1
  1121. #define EM_GETRECT 0x00B2
  1122. #define EM_SETRECT 0x00B3
  1123. #define EM_SETRECTNP 0x00B4
  1124. #define EM_SCROLL 0x00B5
  1125. #define EM_LINESCROLL 0x00B6
  1126. #define EM_SCROLLCARET 0x00B7
  1127. #define EM_GETMODIFY 0x00B8
  1128. #define EM_SETMODIFY 0x00B9
  1129. #define EM_GETLINECOUNT 0x00BA
  1130. #define EM_LINEINDEX 0x00BB
  1131. #define EM_SETHANDLE 0x00BC
  1132. #define EM_GETHANDLE 0x00BD
  1133. #define EM_GETTHUMB 0x00BE
  1134. #define EM_LINELENGTH 0x00C1
  1135. #define EM_REPLACESEL 0x00C2
  1136. #define EM_GETLINE 0x00C4
  1137. #define EM_LIMITTEXT 0x00C5
  1138. #define EM_CANUNDO 0x00C6
  1139. #define EM_UNDO 0x00C7
  1140. #define EM_FMTLINES 0x00C8
  1141. #define EM_LINEFROMCHAR 0x00C9
  1142. #define EM_SETTABSTOPS 0x00CB
  1143. #define EM_SETPASSWORDCHAR 0x00CC
  1144. #define EM_EMPTYUNDOBUFFER 0x00CD
  1145. #define EM_GETFIRSTVISIBLELINE 0x00CE
  1146. #define EM_SETREADONLY 0x00CF
  1147. #define EM_SETWORDBREAKPROC 0x00D0
  1148. #define EM_GETWORDBREAKPROC 0x00D1
  1149. #define EM_GETPASSWORDCHAR 0x00D2
  1150. #if(WINVER >= 0x0400)
  1151. #define EM_SETMARGINS 0x00D3
  1152. #define EM_GETMARGINS 0x00D4
  1153. #define EM_SETLIMITTEXT EM_LIMITTEXT /* ;win40 Name change */
  1154. #define EM_GETLIMITTEXT 0x00D5
  1155. #define EM_POSFROMCHAR 0x00D6
  1156. #define EM_CHARFROMPOS 0x00D7
  1157. #endif /* WINVER >= 0x0400 */
  1158. #if(WINVER >= 0x0500)
  1159. #define EM_SETIMESTATUS 0x00D8
  1160. #define EM_GETIMESTATUS 0x00D9
  1161. #endif /* WINVER >= 0x0500 */
  1162. /*
  1163. * Button Control Styles
  1164. */
  1165. #define BS_PUSHBUTTON 0x00000000L
  1166. #define BS_DEFPUSHBUTTON 0x00000001L
  1167. #define BS_CHECKBOX 0x00000002L
  1168. #define BS_AUTOCHECKBOX 0x00000003L
  1169. #define BS_RADIOBUTTON 0x00000004L
  1170. #define BS_3STATE 0x00000005L
  1171. #define BS_AUTO3STATE 0x00000006L
  1172. #define BS_GROUPBOX 0x00000007L
  1173. #define BS_USERBUTTON 0x00000008L
  1174. #define BS_AUTORADIOBUTTON 0x00000009L
  1175. #define BS_PUSHBOX 0x0000000AL
  1176. #define BS_OWNERDRAW 0x0000000BL
  1177. #define BS_TYPEMASK 0x0000000FL
  1178. #define BS_LEFTTEXT 0x00000020L
  1179. #if(WINVER >= 0x0400)
  1180. #define BS_TEXT 0x00000000L
  1181. #define BS_ICON 0x00000040L
  1182. #define BS_BITMAP 0x00000080L
  1183. #define BS_LEFT 0x00000100L
  1184. #define BS_RIGHT 0x00000200L
  1185. #define BS_CENTER 0x00000300L
  1186. #define BS_TOP 0x00000400L
  1187. #define BS_BOTTOM 0x00000800L
  1188. #define BS_VCENTER 0x00000C00L
  1189. #define BS_PUSHLIKE 0x00001000L
  1190. #define BS_MULTILINE 0x00002000L
  1191. #define BS_NOTIFY 0x00004000L
  1192. #define BS_FLAT 0x00008000L
  1193. #define BS_RIGHTBUTTON BS_LEFTTEXT
  1194. #endif /* WINVER >= 0x0400 */
  1195. /*
  1196. * User Button Notification Codes
  1197. */
  1198. #define BN_CLICKED 0
  1199. #define BN_PAINT 1
  1200. #define BN_HILITE 2
  1201. #define BN_UNHILITE 3
  1202. #define BN_DISABLE 4
  1203. #define BN_DOUBLECLICKED 5
  1204. #if(WINVER >= 0x0400)
  1205. #define BN_PUSHED BN_HILITE
  1206. #define BN_UNPUSHED BN_UNHILITE
  1207. #define BN_DBLCLK BN_DOUBLECLICKED
  1208. #define BN_SETFOCUS 6
  1209. #define BN_KILLFOCUS 7
  1210. #endif /* WINVER >= 0x0400 */
  1211. /*
  1212. * Button Control Messages
  1213. */
  1214. #define BM_GETCHECK 0x00F0
  1215. #define BM_SETCHECK 0x00F1
  1216. #define BM_GETSTATE 0x00F2
  1217. #define BM_SETSTATE 0x00F3
  1218. #define BM_SETSTYLE 0x00F4
  1219. #if(WINVER >= 0x0400)
  1220. #define BM_CLICK 0x00F5
  1221. #define BM_GETIMAGE 0x00F6
  1222. #define BM_SETIMAGE 0x00F7
  1223. #define BST_UNCHECKED 0x0000
  1224. #define BST_CHECKED 0x0001
  1225. #define BST_INDETERMINATE 0x0002
  1226. #define BST_PUSHED 0x0004
  1227. #define BST_FOCUS 0x0008
  1228. #endif /* WINVER >= 0x0400 */
  1229. /*
  1230. * Static Control Constants
  1231. */
  1232. #define SS_LEFT 0x00000000L
  1233. #define SS_CENTER 0x00000001L
  1234. #define SS_RIGHT 0x00000002L
  1235. #define SS_ICON 0x00000003L
  1236. #define SS_BLACKRECT 0x00000004L
  1237. #define SS_GRAYRECT 0x00000005L
  1238. #define SS_WHITERECT 0x00000006L
  1239. #define SS_BLACKFRAME 0x00000007L
  1240. #define SS_GRAYFRAME 0x00000008L
  1241. #define SS_WHITEFRAME 0x00000009L
  1242. #define SS_USERITEM 0x0000000AL
  1243. #define SS_SIMPLE 0x0000000BL
  1244. #define SS_LEFTNOWORDWRAP 0x0000000CL
  1245. #if(WINVER >= 0x0400)
  1246. #define SS_OWNERDRAW 0x0000000DL
  1247. #define SS_BITMAP 0x0000000EL
  1248. #define SS_ENHMETAFILE 0x0000000FL
  1249. #define SS_ETCHEDHORZ 0x00000010L
  1250. #define SS_ETCHEDVERT 0x00000011L
  1251. #define SS_ETCHEDFRAME 0x00000012L
  1252. #define SS_TYPEMASK 0x0000001FL
  1253. #endif /* WINVER >= 0x0400 */
  1254. #if(WINVER >= 0x0501)
  1255. #define SS_REALSIZECONTROL 0x00000040L
  1256. #endif /* WINVER >= 0x0501 */
  1257. #define SS_NOPREFIX 0x00000080L /* Don't do "&" character translation */
  1258. #if(WINVER >= 0x0400)
  1259. #define SS_NOTIFY 0x00000100L
  1260. #define SS_CENTERIMAGE 0x00000200L
  1261. #define SS_RIGHTJUST 0x00000400L
  1262. #define SS_REALSIZEIMAGE 0x00000800L
  1263. #define SS_SUNKEN 0x00001000L
  1264. #define SS_EDITCONTROL 0x00002000L
  1265. #define SS_ENDELLIPSIS 0x00004000L
  1266. #define SS_PATHELLIPSIS 0x00008000L
  1267. #define SS_WORDELLIPSIS 0x0000C000L
  1268. #define SS_ELLIPSISMASK 0x0000C000L
  1269. #endif /* WINVER >= 0x0400 */
  1270. /*
  1271. * Dialog Styles
  1272. */
  1273. #define DS_ABSALIGN 0x01L
  1274. #define DS_SYSMODAL 0x02L
  1275. #define DS_LOCALEDIT 0x20L /* Edit items get Local storage. */
  1276. #define DS_SETFONT 0x40L /* User specified font for Dlg controls */
  1277. #define DS_MODALFRAME 0x80L /* Can be combined with WS_CAPTION */
  1278. #define DS_NOIDLEMSG 0x100L /* WM_ENTERIDLE message will not be sent */
  1279. #define DS_SETFOREGROUND 0x200L /* not in win3.1 */
  1280. #if(WINVER >= 0x0400)
  1281. #define DS_3DLOOK 0x0004L
  1282. #define DS_FIXEDSYS 0x0008L
  1283. #define DS_NOFAILCREATE 0x0010L
  1284. #define DS_CONTROL 0x0400L
  1285. #define DS_CENTER 0x0800L
  1286. #define DS_CENTERMOUSE 0x1000L
  1287. #define DS_CONTEXTHELP 0x2000L
  1288. #define DS_SHELLFONT (DS_SETFONT | DS_FIXEDSYS)
  1289. #endif /* WINVER >= 0x0400 */
  1290. /*
  1291. * Listbox Styles
  1292. */
  1293. #define LBS_NOTIFY 0x0001L
  1294. #define LBS_SORT 0x0002L
  1295. #define LBS_NOREDRAW 0x0004L
  1296. #define LBS_MULTIPLESEL 0x0008L
  1297. #define LBS_OWNERDRAWFIXED 0x0010L
  1298. #define LBS_OWNERDRAWVARIABLE 0x0020L
  1299. #define LBS_HASSTRINGS 0x0040L
  1300. #define LBS_USETABSTOPS 0x0080L
  1301. #define LBS_NOINTEGRALHEIGHT 0x0100L
  1302. #define LBS_MULTICOLUMN 0x0200L
  1303. #define LBS_WANTKEYBOARDINPUT 0x0400L
  1304. #define LBS_EXTENDEDSEL 0x0800L
  1305. #define LBS_DISABLENOSCROLL 0x1000L
  1306. #define LBS_NODATA 0x2000L
  1307. #if(WINVER >= 0x0400)
  1308. #define LBS_NOSEL 0x4000L
  1309. #endif /* WINVER >= 0x0400 */
  1310. #define LBS_COMBOBOX 0x8000L // Listbox is part of a Combobox - read-only
  1311. #define LBS_STANDARD (LBS_NOTIFY | LBS_SORT | WS_VSCROLL | WS_BORDER)
  1312. /*
  1313. * Combo Box styles
  1314. */
  1315. #define CBS_SIMPLE 0x0001L
  1316. #define CBS_DROPDOWN 0x0002L
  1317. #define CBS_DROPDOWNLIST 0x0003L
  1318. #define CBS_OWNERDRAWFIXED 0x0010L
  1319. #define CBS_OWNERDRAWVARIABLE 0x0020L
  1320. #define CBS_AUTOHSCROLL 0x0040L
  1321. #define CBS_OEMCONVERT 0x0080L
  1322. #define CBS_SORT 0x0100L
  1323. #define CBS_HASSTRINGS 0x0200L
  1324. #define CBS_NOINTEGRALHEIGHT 0x0400L
  1325. #define CBS_DISABLENOSCROLL 0x0800L
  1326. #if(WINVER >= 0x0400)
  1327. #define CBS_UPPERCASE 0x2000L
  1328. #define CBS_LOWERCASE 0x4000L
  1329. #endif /* WINVER >= 0x0400 */
  1330. /*
  1331. * Scroll Bar Styles
  1332. */
  1333. #define SBS_HORZ 0x0000L
  1334. #define SBS_VERT 0x0001L
  1335. #define SBS_TOPALIGN 0x0002L
  1336. #define SBS_LEFTALIGN 0x0002L
  1337. #define SBS_BOTTOMALIGN 0x0004L
  1338. #define SBS_RIGHTALIGN 0x0004L
  1339. #define SBS_SIZEBOXTOPLEFTALIGN 0x0002L
  1340. #define SBS_SIZEBOXBOTTOMRIGHTALIGN 0x0004L
  1341. #define SBS_SIZEBOX 0x0008L
  1342. #if(WINVER >= 0x0400)
  1343. #define SBS_SIZEGRIP 0x0010L
  1344. #endif /* WINVER >= 0x0400 */
  1345. /*
  1346. * Commands to pass to WinHelp()
  1347. */
  1348. #define HELP_CONTEXT 0x0001L /* Display topic in ulTopic */
  1349. #define HELP_QUIT 0x0002L /* Terminate help */
  1350. #define HELP_INDEX 0x0003L /* Display index */
  1351. #define HELP_CONTENTS 0x0003L
  1352. #define HELP_HELPONHELP 0x0004L /* Display help on using help */
  1353. #define HELP_SETINDEX 0x0005L /* Set current Index for multi index help */
  1354. #define HELP_SETCONTENTS 0x0005L
  1355. #define HELP_CONTEXTPOPUP 0x0008L
  1356. #define HELP_FORCEFILE 0x0009L
  1357. #define HELP_KEY 0x0101L /* Display topic for keyword in offabData */
  1358. #define HELP_COMMAND 0x0102L
  1359. #define HELP_PARTIALKEY 0x0105L
  1360. #define HELP_MULTIKEY 0x0201L
  1361. #define HELP_SETWINPOS 0x0203L
  1362. #if(WINVER >= 0x0400)
  1363. #define HELP_CONTEXTMENU 0x000a
  1364. #define HELP_FINDER 0x000b
  1365. #define HELP_WM_HELP 0x000c
  1366. #define HELP_SETPOPUP_POS 0x000d
  1367. #define HELP_TCARD 0x8000
  1368. #define HELP_TCARD_DATA 0x0010
  1369. #define HELP_TCARD_OTHER_CALLER 0x0011
  1370. // These are in winhelp.h in Win95.
  1371. #define IDH_NO_HELP 28440
  1372. #define IDH_MISSING_CONTEXT 28441 // Control doesn't have matching help context
  1373. #define IDH_GENERIC_HELP_BUTTON 28442 // Property sheet help button
  1374. #define IDH_OK 28443
  1375. #define IDH_CANCEL 28444
  1376. #define IDH_HELP 28445
  1377. #endif /* WINVER >= 0x0400 */