WinMessages.nsh 27 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706
  1. /*
  2. _____________________________________________________________________________
  3. List of common Windows Messages
  4. _____________________________________________________________________________
  5. 2005 Shengalts Aleksander aka Instructor (Shengalts@mail.ru)
  6. Usage example:
  7. ---------------------------------------------------
  8. Name "Output"
  9. OutFile "Output.exe"
  10. !include "WinMessages.nsh"
  11. Section
  12. FindWindow $0 '#32770' '' $HWNDPARENT
  13. GetDlgItem $1 $0 1027
  14. SendMessage $1 ${WM_SETTEXT} 0 'STR:MyText'
  15. SectionEnd
  16. ---------------------------------------------------
  17. Prefix Message category
  18. -------------------------
  19. SW ShowWindow Commands
  20. CCM Generic Common Control
  21. BM Button control
  22. CB Combo box control
  23. EM Edit control
  24. LB List box control
  25. WM General window
  26. ABM Application desktop toolbar
  27. DBT Device
  28. DM Default push button control
  29. HDM Header control
  30. LVM List view control
  31. SB Status bar window
  32. SBM Scroll bar control
  33. STM Static control
  34. TCM Tab control
  35. PBM Progress bar
  36. -----------------------------------
  37. NOT included messages (WM_USER + X)
  38. -----------------------------------
  39. CBEM Extended combo box control
  40. CDM Common dialog box
  41. DL Drag list box
  42. DTM Date and time picker control
  43. HKM Hot key control
  44. IPM IP address control
  45. MCM Month calendar control
  46. PGM Pager control
  47. PSM Property sheet
  48. RB Rebar control
  49. TB Toolbar
  50. TBM Trackbar
  51. TTM Tooltip control
  52. TVM Tree-view control
  53. UDM Up-down control
  54. -----------------------------------
  55. */
  56. !ifndef WINMESSAGES_INCLUDED
  57. !define WINMESSAGES_INCLUDED
  58. !verbose push
  59. !verbose 3
  60. !define _NSIS_DEFAW '!insertmacro _NSIS_DEFAW '
  61. !macro _NSIS_DEFAW d
  62. !ifdef NSIS_UNICODE
  63. !define ${d} "${${d}W}"
  64. !else
  65. !define ${d} "${${d}A}"
  66. !endif
  67. !macroend
  68. !define HWND_BROADCAST 0xFFFF
  69. #ShowWindow Commands#
  70. !define SW_HIDE 0
  71. !define SW_SHOWNORMAL 1
  72. !define SW_NORMAL 1
  73. !define SW_SHOWMINIMIZED 2
  74. !define SW_SHOWMAXIMIZED 3
  75. !define SW_MAXIMIZE 3
  76. !define SW_SHOWNOACTIVATE 4
  77. !define SW_SHOW 5
  78. !define SW_MINIMIZE 6
  79. !define SW_SHOWMINNOACTIVE 7
  80. !define SW_SHOWNA 8
  81. !define SW_RESTORE 9
  82. !define SW_SHOWDEFAULT 10
  83. !define SW_FORCEMINIMIZE 11
  84. !define SW_MAX 11
  85. #Generic Common Control Messages#
  86. !define CCM_FIRST 0x2000
  87. !define /math CCM_SETBKCOLOR ${CCM_FIRST} + 0x1 ; IE4
  88. !define /math CCM_SETUNICODEFORMAT ${CCM_FIRST} + 0x5
  89. !define /math CCM_GETUNICODEFORMAT ${CCM_FIRST} + 0x6
  90. !define /math CCM_SETVERSION ${CCM_FIRST} + 0x7 ; IE5
  91. !define /math CCM_GETVERSION ${CCM_FIRST} + 0x8
  92. !define /math CCM_SETWINDOWTHEME ${CCM_FIRST} + 0xB ; WinXP
  93. !define /math CCM_DPISCALE ${CCM_FIRST} + 0xC
  94. !define CCS_TOP 1
  95. !define CCS_BOTTOM 3
  96. !define CCS_NODIVIDER 64
  97. !define CCS_LEFT 129
  98. !define CCS_RIGHT 131
  99. !define I_IMAGENONE -2
  100. #Button Control Messages#
  101. !define BM_CLICK 0x00F5
  102. !define BM_GETCHECK 0x00F0
  103. !define BM_GETIMAGE 0x00F6
  104. !define BM_GETSTATE 0x00F2
  105. !define BM_SETCHECK 0x00F1
  106. !define BM_SETIMAGE 0x00F7
  107. !define BM_SETSTATE 0x00F3
  108. !define BM_SETSTYLE 0x00F4
  109. !define BCM_SETSHIELD 0x160C ; WinVista + ComCtl32 v6
  110. !define BST_UNCHECKED 0
  111. !define BST_CHECKED 1
  112. !define BST_INDETERMINATE 2
  113. !define BST_PUSHED 4
  114. !define BST_FOCUS 8
  115. #Combo Box Messages#
  116. !define CB_ADDSTRING 0x0143
  117. !define CB_DELETESTRING 0x0144
  118. !define CB_DIR 0x0145
  119. !define CB_FINDSTRING 0x014C
  120. !define CB_FINDSTRINGEXACT 0x0158
  121. !define CB_GETCOUNT 0x0146
  122. !define CB_GETCURSEL 0x0147
  123. !define CB_GETDROPPEDCONTROLRECT 0x0152
  124. !define CB_GETDROPPEDSTATE 0x0157
  125. !define CB_GETDROPPEDWIDTH 0x015f
  126. !define CB_GETEDITSEL 0x0140
  127. !define CB_GETEXTENDEDUI 0x0156
  128. !define CB_GETHORIZONTALEXTENT 0x015d
  129. !define CB_GETITEMDATA 0x0150
  130. !define CB_GETITEMHEIGHT 0x0154
  131. !define CB_GETLBTEXT 0x0148
  132. !define CB_GETLBTEXTLEN 0x0149
  133. !define CB_GETLOCALE 0x015A
  134. !define CB_GETTOPINDEX 0x015b
  135. !define CB_INITSTORAGE 0x0161
  136. !define CB_INSERTSTRING 0x014A
  137. !define CB_LIMITTEXT 0x0141
  138. !define CB_MSGMAX 0x015B # 0x0162 0x0163
  139. !define CB_MULTIPLEADDSTRING 0x0163
  140. !define CB_RESETCONTENT 0x014B
  141. !define CB_SELECTSTRING 0x014D
  142. !define CB_SETCURSEL 0x014E
  143. !define CB_SETDROPPEDWIDTH 0x0160
  144. !define CB_SETEDITSEL 0x0142
  145. !define CB_SETEXTENDEDUI 0x0155
  146. !define CB_SETHORIZONTALEXTENT 0x015e
  147. !define CB_SETITEMDATA 0x0151
  148. !define CB_SETITEMHEIGHT 0x0153
  149. !define CB_SETLOCALE 0x0159
  150. !define CB_SETTOPINDEX 0x015c
  151. !define CB_SHOWDROPDOWN 0x014F
  152. !define CB_ERR -1
  153. #Edit Control Messages#
  154. !define EM_CANUNDO 0x00C6
  155. !define EM_CHARFROMPOS 0x00D7
  156. !define EM_EMPTYUNDOBUFFER 0x00CD
  157. !define EM_EXLIMITTEXT 0x0435
  158. !define EM_FMTLINES 0x00C8
  159. !define EM_GETFIRSTVISIBLELINE 0x00CE
  160. !define EM_GETHANDLE 0x00BD
  161. !define EM_GETIMESTATUS 0x00D9
  162. !define EM_GETLIMITTEXT 0x00D5
  163. !define EM_GETLINE 0x00C4
  164. !define EM_GETLINECOUNT 0x00BA
  165. !define EM_GETMARGINS 0x00D4
  166. !define EM_GETMODIFY 0x00B8
  167. !define EM_GETPASSWORDCHAR 0x00D2
  168. !define EM_GETRECT 0x00B2
  169. !define EM_GETSEL 0x00B0
  170. !define EM_GETTHUMB 0x00BE
  171. !define EM_GETWORDBREAKPROC 0x00D1
  172. !define EM_LIMITTEXT 0x00C5
  173. !define EM_LINEFROMCHAR 0x00C9
  174. !define EM_LINEINDEX 0x00BB
  175. !define EM_LINELENGTH 0x00C1
  176. !define EM_LINESCROLL 0x00B6
  177. !define EM_POSFROMCHAR 0x00D6
  178. !define EM_REPLACESEL 0x00C2
  179. !define EM_SCROLL 0x00B5
  180. !define EM_SCROLLCARET 0x00B7
  181. !define EM_SETHANDLE 0x00BC
  182. !define EM_SETIMESTATUS 0x00D8
  183. !define EM_SETLIMITTEXT 0x00C5 # Same as EM_LIMITTEXT
  184. !define EM_SETMARGINS 0x00D3
  185. !define EM_SETMODIFY 0x00B9
  186. !define EM_SETPASSWORDCHAR 0x00CC
  187. !define EM_SETREADONLY 0x00CF
  188. !define EM_SETRECT 0x00B3
  189. !define EM_SETRECTNP 0x00B4
  190. !define EM_SETSEL 0x00B1
  191. !define EM_SETTABSTOPS 0x00CB
  192. !define EM_SETWORDBREAKPROC 0x00D0
  193. !define EM_UNDO 0x00C7
  194. #Listbox Messages#
  195. !define LB_ADDFILE 0x0196
  196. !define LB_ADDSTRING 0x0180
  197. !define LB_DELETESTRING 0x0182
  198. !define LB_DIR 0x018D
  199. !define LB_FINDSTRING 0x018F
  200. !define LB_FINDSTRINGEXACT 0x01A2
  201. !define LB_GETANCHORINDEX 0x019D
  202. !define LB_GETCARETINDEX 0x019F
  203. !define LB_GETCOUNT 0x018B
  204. !define LB_GETCURSEL 0x0188
  205. !define LB_GETHORIZONTALEXTENT 0x0193
  206. !define LB_GETITEMDATA 0x0199
  207. !define LB_GETITEMHEIGHT 0x01A1
  208. !define LB_GETITEMRECT 0x0198
  209. !define LB_GETLOCALE 0x01A6
  210. !define LB_GETSEL 0x0187
  211. !define LB_GETSELCOUNT 0x0190
  212. !define LB_GETSELITEMS 0x0191
  213. !define LB_GETTEXT 0x0189
  214. !define LB_GETTEXTLEN 0x018A
  215. !define LB_GETTOPINDEX 0x018E
  216. !define LB_INITSTORAGE 0x01A8
  217. !define LB_INSERTSTRING 0x0181
  218. !define LB_ITEMFROMPOINT 0x01A9
  219. !define LB_MSGMAX 0x01A8 # 0x01B0 0x01B1
  220. !define LB_MULTIPLEADDSTRING 0x01B1
  221. !define LB_RESETCONTENT 0x0184
  222. !define LB_SELECTSTRING 0x018C
  223. !define LB_SELITEMRANGE 0x019B
  224. !define LB_SELITEMRANGEEX 0x0183
  225. !define LB_SETANCHORINDEX 0x019C
  226. !define LB_SETCARETINDEX 0x019E
  227. !define LB_SETCOLUMNWIDTH 0x0195
  228. !define LB_SETCOUNT 0x01A7
  229. !define LB_SETCURSEL 0x0186
  230. !define LB_SETHORIZONTALEXTENT 0x0194
  231. !define LB_SETITEMDATA 0x019A
  232. !define LB_SETITEMHEIGHT 0x01A0
  233. !define LB_SETLOCALE 0x01A5
  234. !define LB_SETSEL 0x0185
  235. !define LB_SETTABSTOPS 0x0192
  236. !define LB_SETTOPINDEX 0x0197
  237. !define LB_ERR -1
  238. #Window Messages#
  239. !define WM_ACTIVATE 0x0006
  240. !define WM_ACTIVATEAPP 0x001C
  241. !define WM_AFXFIRST 0x0360
  242. !define WM_AFXLAST 0x037F
  243. !define WM_APP 0x8000
  244. !define WM_APPCOMMAND 0x0319
  245. !define WM_ASKCBFORMATNAME 0x030C
  246. !define WM_CANCELJOURNAL 0x004B
  247. !define WM_CANCELMODE 0x001F
  248. !define WM_CAPTURECHANGED 0x0215
  249. !define WM_CHANGECBCHAIN 0x030D
  250. !define WM_CHANGEUISTATE 0x0127
  251. !define WM_CHAR 0x0102
  252. !define WM_CHARTOITEM 0x002F
  253. !define WM_CHILDACTIVATE 0x0022
  254. !define WM_CLEAR 0x0303
  255. !define WM_CLOSE 0x0010
  256. !define WM_COMMAND 0x0111
  257. !define WM_COMMNOTIFY 0x0044 # no longer suported
  258. !define WM_COMPACTING 0x0041
  259. !define WM_COMPAREITEM 0x0039
  260. !define WM_CONTEXTMENU 0x007B
  261. !define WM_CONVERTREQUESTEX 0x108
  262. !define WM_COPY 0x0301
  263. !define WM_COPYDATA 0x004A
  264. !define WM_CREATE 0x0001
  265. !define WM_CTLCOLOR 0x0019
  266. !define WM_CTLCOLORBTN 0x0135
  267. !define WM_CTLCOLORDLG 0x0136
  268. !define WM_CTLCOLOREDIT 0x0133
  269. !define WM_CTLCOLORLISTBOX 0x0134
  270. !define WM_CTLCOLORMSGBOX 0x0132
  271. !define WM_CTLCOLORSCROLLBAR 0x0137
  272. !define WM_CTLCOLORSTATIC 0x0138
  273. !define WM_CUT 0x0300
  274. !define WM_DDE_FIRST 0x3E0
  275. !define WM_DEADCHAR 0x0103
  276. !define WM_DELETEITEM 0x002D
  277. !define WM_DESTROY 0x0002
  278. !define WM_DESTROYCLIPBOARD 0x0307
  279. !define WM_DEVICECHANGE 0x0219
  280. !define WM_DEVMODECHANGE 0x001B
  281. !define WM_DISPLAYCHANGE 0x007E
  282. !define WM_DRAWCLIPBOARD 0x0308
  283. !define WM_DRAWITEM 0x002B
  284. !define WM_DROPFILES 0x0233
  285. !define WM_ENABLE 0x000A
  286. !define WM_ENDSESSION 0x0016
  287. !define WM_ENTERIDLE 0x0121
  288. !define WM_ENTERMENULOOP 0x0211
  289. !define WM_ENTERSIZEMOVE 0x0231
  290. !define WM_ERASEBKGND 0x0014
  291. !define WM_EXITMENULOOP 0x0212
  292. !define WM_EXITSIZEMOVE 0x0232
  293. !define WM_FONTCHANGE 0x001D
  294. !define WM_GETDLGCODE 0x0087
  295. !define WM_GETFONT 0x0031
  296. !define WM_GETHOTKEY 0x0033
  297. !define WM_GETICON 0x007F
  298. !define WM_GETMINMAXINFO 0x0024
  299. !define WM_GETOBJECT 0x003D
  300. !define WM_GETTEXT 0x000D
  301. !define WM_GETTEXTLENGTH 0x000E
  302. !define WM_HANDHELDFIRST 0x0358
  303. !define WM_HANDHELDLAST 0x035F
  304. !define WM_HELP 0x0053
  305. !define WM_HOTKEY 0x0312
  306. !define WM_HSCROLL 0x0114
  307. !define WM_HSCROLLCLIPBOARD 0x030E
  308. !define WM_ICONERASEBKGND 0x0027
  309. !define WM_IME_CHAR 0x0286
  310. !define WM_IME_COMPOSITION 0x010F
  311. !define WM_IME_COMPOSITIONFULL 0x0284
  312. !define WM_IME_CONTROL 0x0283
  313. !define WM_IME_ENDCOMPOSITION 0x010E
  314. !define WM_IME_KEYDOWN 0x0290
  315. !define WM_IME_KEYLAST 0x010F
  316. !define WM_IME_KEYUP 0x0291
  317. !define WM_IME_NOTIFY 0x0282
  318. !define WM_IME_REQUEST 0x0288
  319. !define WM_IME_SELECT 0x0285
  320. !define WM_IME_SETCONTEXT 0x0281
  321. !define WM_IME_STARTCOMPOSITION 0x010D
  322. !define WM_INITDIALOG 0x0110
  323. !define WM_INITMENU 0x0116
  324. !define WM_INITMENUPOPUP 0x0117
  325. !define WM_INPUT 0x00FF
  326. !define WM_INPUTLANGCHANGE 0x0051
  327. !define WM_INPUTLANGCHANGEREQUEST 0x0050
  328. !define WM_KEYDOWN 0x0100
  329. !define WM_KEYFIRST 0x0100
  330. !define WM_KEYLAST 0x0108
  331. !define WM_KEYUP 0x0101
  332. !define WM_KILLFOCUS 0x0008
  333. !define WM_LBUTTONDBLCLK 0x0203
  334. !define WM_LBUTTONDOWN 0x0201
  335. !define WM_LBUTTONUP 0x0202
  336. !define WM_MBUTTONDBLCLK 0x0209
  337. !define WM_MBUTTONDOWN 0x0207
  338. !define WM_MBUTTONUP 0x0208
  339. !define WM_MDIACTIVATE 0x0222
  340. !define WM_MDICASCADE 0x0227
  341. !define WM_MDICREATE 0x0220
  342. !define WM_MDIDESTROY 0x0221
  343. !define WM_MDIGETACTIVE 0x0229
  344. !define WM_MDIICONARRANGE 0x0228
  345. !define WM_MDIMAXIMIZE 0x0225
  346. !define WM_MDINEXT 0x0224
  347. !define WM_MDIREFRESHMENU 0x0234
  348. !define WM_MDIRESTORE 0x0223
  349. !define WM_MDISETMENU 0x0230
  350. !define WM_MDITILE 0x0226
  351. !define WM_MEASUREITEM 0x002C
  352. !define WM_MENUCHAR 0x0120
  353. !define WM_MENUCOMMAND 0x0126
  354. !define WM_MENUDRAG 0x0123
  355. !define WM_MENUGETOBJECT 0x0124
  356. !define WM_MENURBUTTONUP 0x0122
  357. !define WM_MENUSELECT 0x011F
  358. !define WM_MOUSEACTIVATE 0x0021
  359. !define WM_MOUSEFIRST 0x0200
  360. !define WM_MOUSEHOVER 0x02A1
  361. !define WM_MOUSELAST 0x0209 # 0x020A 0x020D
  362. !define WM_MOUSELEAVE 0x02A3
  363. !define WM_MOUSEMOVE 0x0200
  364. !define WM_MOUSEWHEEL 0x020A
  365. !define WM_MOVE 0x0003
  366. !define WM_MOVING 0x0216
  367. !define WM_NCACTIVATE 0x0086
  368. !define WM_NCCALCSIZE 0x0083
  369. !define WM_NCCREATE 0x0081
  370. !define WM_NCDESTROY 0x0082
  371. !define WM_NCHITTEST 0x0084
  372. !define WM_NCLBUTTONDBLCLK 0x00A3
  373. !define WM_NCLBUTTONDOWN 0x00A1
  374. !define WM_NCLBUTTONUP 0x00A2
  375. !define WM_NCMBUTTONDBLCLK 0x00A9
  376. !define WM_NCMBUTTONDOWN 0x00A7
  377. !define WM_NCMBUTTONUP 0x00A8
  378. !define WM_NCMOUSEHOVER 0x02A0
  379. !define WM_NCMOUSELEAVE 0x02A2
  380. !define WM_NCMOUSEMOVE 0x00A0
  381. !define WM_NCPAINT 0x0085
  382. !define WM_NCRBUTTONDBLCLK 0x00A6
  383. !define WM_NCRBUTTONDOWN 0x00A4
  384. !define WM_NCRBUTTONUP 0x00A5
  385. !define WM_NCXBUTTONDBLCLK 0x00AD
  386. !define WM_NCXBUTTONDOWN 0x00AB
  387. !define WM_NCXBUTTONUP 0x00AC
  388. !define WM_NEXTDLGCTL 0x0028
  389. !define WM_NEXTMENU 0x0213
  390. !define WM_NOTIFY 0x004E
  391. !define WM_NOTIFYFORMAT 0x0055
  392. !define WM_NULL 0x0000
  393. !define WM_PAINT 0x000F
  394. !define WM_PAINTCLIPBOARD 0x0309
  395. !define WM_PAINTICON 0x0026
  396. !define WM_PALETTECHANGED 0x0311
  397. !define WM_PALETTEISCHANGING 0x0310
  398. !define WM_PARENTNOTIFY 0x0210
  399. !define WM_PASTE 0x0302
  400. !define WM_PENWINFIRST 0x0380
  401. !define WM_PENWINLAST 0x038F
  402. !define WM_POWER 0x0048
  403. !define WM_POWERBROADCAST 0x0218
  404. !define WM_PRINT 0x0317
  405. !define WM_PRINTCLIENT 0x0318
  406. !define WM_QUERYDRAGICON 0x0037
  407. !define WM_QUERYENDSESSION 0x0011
  408. !define WM_QUERYNEWPALETTE 0x030F
  409. !define WM_QUERYOPEN 0x0013
  410. !define WM_QUERYUISTATE 0x0129
  411. !define WM_QUEUESYNC 0x0023
  412. !define WM_QUIT 0x0012
  413. !define WM_RBUTTONDBLCLK 0x0206
  414. !define WM_RBUTTONDOWN 0x0204
  415. !define WM_RBUTTONUP 0x0205
  416. !define WM_RASDIALEVENT 0xCCCD
  417. !define WM_RENDERALLFORMATS 0x0306
  418. !define WM_RENDERFORMAT 0x0305
  419. !define WM_SETCURSOR 0x0020
  420. !define WM_SETFOCUS 0x0007
  421. !define WM_SETFONT 0x0030
  422. !define WM_SETHOTKEY 0x0032
  423. !define WM_SETICON 0x0080
  424. !define WM_SETREDRAW 0x000B
  425. !define WM_SETTEXT 0x000C
  426. !define WM_SETTINGCHANGE 0x001A # Same as WM_WININICHANGE
  427. !define WM_SHOWWINDOW 0x0018
  428. !define WM_SIZE 0x0005
  429. !define WM_SIZECLIPBOARD 0x030B
  430. !define WM_SIZING 0x0214
  431. !define WM_SPOOLERSTATUS 0x002A
  432. !define WM_STYLECHANGED 0x007D
  433. !define WM_STYLECHANGING 0x007C
  434. !define WM_SYNCPAINT 0x0088
  435. !define WM_SYSCHAR 0x0106
  436. !define WM_SYSCOLORCHANGE 0x0015
  437. !define WM_SYSCOMMAND 0x0112
  438. !define WM_SYSDEADCHAR 0x0107
  439. !define WM_SYSKEYDOWN 0x0104
  440. !define WM_SYSKEYUP 0x0105
  441. !define WM_TABLET_FIRST 0x02C0
  442. !define WM_TABLET_LAST 0x02DF
  443. !define WM_THEMECHANGED 0x031A
  444. !define WM_TCARD 0x0052
  445. !define WM_TIMECHANGE 0x001E
  446. !define WM_TIMER 0x0113
  447. !define WM_UNDO 0x0304
  448. !define WM_UNICHAR 0x0109
  449. !define WM_UNINITMENUPOPUP 0x0125
  450. !define WM_UPDATEUISTATE 0x0128
  451. !define WM_USER 0x400
  452. !define WM_USERCHANGED 0x0054
  453. !define WM_VKEYTOITEM 0x002E
  454. !define WM_VSCROLL 0x0115
  455. !define WM_VSCROLLCLIPBOARD 0x030A
  456. !define WM_WINDOWPOSCHANGED 0x0047
  457. !define WM_WINDOWPOSCHANGING 0x0046
  458. !define WM_WININICHANGE 0x001A
  459. !define WM_WTSSESSION_CHANGE 0x02B1
  460. !define WM_XBUTTONDBLCLK 0x020D
  461. !define WM_XBUTTONDOWN 0x020B
  462. !define WM_XBUTTONUP 0x020C
  463. #Application desktop toolbar#
  464. !define ABM_ACTIVATE 0x00000006 # lParam == TRUE/FALSE means activate/deactivate
  465. !define ABM_GETAUTOHIDEBAR 0x00000007
  466. !define ABM_GETSTATE 0x00000004
  467. !define ABM_GETTASKBARPOS 0x00000005
  468. !define ABM_NEW 0x00000000
  469. !define ABM_QUERYPOS 0x00000002
  470. !define ABM_REMOVE 0x00000001
  471. !define ABM_SETAUTOHIDEBAR 0x00000008 # This can fail, you MUST check the result
  472. !define ABM_SETPOS 0x00000003
  473. !define ABM_WINDOWPOSCHANGED 0x0000009
  474. #Device#
  475. !define DBT_APPYBEGIN 0x0000
  476. !define DBT_APPYEND 0x0001
  477. !define DBT_CONFIGCHANGECANCELED 0x0019
  478. !define DBT_CONFIGCHANGED 0x0018
  479. !define DBT_CONFIGMGAPI32 0x0022
  480. !define DBT_CONFIGMGPRIVATE 0x7FFF
  481. !define DBT_CUSTOMEVENT 0x8006 # User-defined event
  482. !define DBT_DEVICEARRIVAL 0x8000 # System detected a new device
  483. !define DBT_DEVICEQUERYREMOVE 0x8001 # Wants to remove, may fail
  484. !define DBT_DEVICEQUERYREMOVEFAILED 0x8002 # Removal aborted
  485. !define DBT_DEVICEREMOVECOMPLETE 0x8004 # Device is gone
  486. !define DBT_DEVICEREMOVEPENDING 0x8003 # About to remove, still avail.
  487. !define DBT_DEVICETYPESPECIFIC 0x8005 # Type specific event
  488. !define DBT_DEVNODES_CHANGED 0x0007
  489. !define DBT_DEVTYP_DEVICEINTERFACE 0x00000005 # Device interface class
  490. !define DBT_DEVTYP_DEVNODE 0x00000001 # Devnode number
  491. !define DBT_DEVTYP_HANDLE 0x00000006 # File system handle
  492. !define DBT_DEVTYP_NET 0x00000004 # Network resource
  493. !define DBT_DEVTYP_OEM 0x00000000 # Oem-defined device type
  494. !define DBT_DEVTYP_PORT 0x00000003 # Serial, parallel
  495. !define DBT_DEVTYP_VOLUME 0x00000002 # Logical volume
  496. !define DBT_LOW_DISK_SPACE 0x0048
  497. !define DBT_MONITORCHANGE 0x001B
  498. !define DBT_NO_DISK_SPACE 0x0047
  499. !define DBT_QUERYCHANGECONFIG 0x0017
  500. !define DBT_SHELLLOGGEDON 0x0020
  501. !define DBT_USERDEFINED 0xFFFF
  502. !define DBT_VOLLOCKLOCKFAILED 0x8043
  503. !define DBT_VOLLOCKLOCKRELEASED 0x8045
  504. !define DBT_VOLLOCKLOCKTAKEN 0x8042
  505. !define DBT_VOLLOCKQUERYLOCK 0x8041
  506. !define DBT_VOLLOCKQUERYUNLOCK 0x8044
  507. !define DBT_VOLLOCKUNLOCKFAILED 0x8046
  508. !define DBT_VPOWERDAPI 0x8100 # VPOWERD API for Win95
  509. !define DBT_VXDINITCOMPLETE 0x0023
  510. #Default push button control#
  511. !define DM_BITSPERPEL 0x00040000
  512. !define DM_COLLATE 0x00008000
  513. !define DM_COLOR 0x00000800
  514. !define DM_COPIES 0x00000100
  515. !define DM_DEFAULTSOURCE 0x00000200
  516. !define DM_DISPLAYFLAGS 0x00200000
  517. !define DM_DISPLAYFREQUENCY 0x00400000
  518. !define DM_DITHERTYPE 0x04000000
  519. !define DM_DUPLEX 0x00001000
  520. !define DM_FORMNAME 0x00010000
  521. !define DM_GRAYSCALE 0x00000001 # This flag is no longer valid
  522. !define DM_ICMINTENT 0x01000000
  523. !define DM_ICMMETHOD 0x00800000
  524. !define DM_INTERLACED 0x00000002 # This flag is no longer valid
  525. !define DM_LOGPIXELS 0x00020000
  526. !define DM_MEDIATYPE 0x02000000
  527. !define DM_NUP 0x00000040
  528. !define DM_ORIENTATION 0x00000001
  529. !define DM_PANNINGHEIGHT 0x10000000
  530. !define DM_PANNINGWIDTH 0x08000000
  531. !define DM_PAPERLENGTH 0x00000004
  532. !define DM_PAPERSIZE 0x00000002
  533. !define DM_PAPERWIDTH 0x00000008
  534. !define DM_PELSHEIGHT 0x00100000
  535. !define DM_PELSWIDTH 0x00080000
  536. !define DM_POSITION 0x00000020
  537. !define DM_PRINTQUALITY 0x00000400
  538. !define DM_SCALE 0x00000010
  539. !define DM_SPECVERSION 0x0320 # 0x0400 0x0401
  540. !define DM_TTOPTION 0x00004000
  541. !define DM_YRESOLUTION 0x00002000
  542. #Header control#
  543. !define HDM_FIRST 0x1200
  544. #List view control#
  545. !define LVS_SINGLESEL 4
  546. !define LVS_SHOWSELALWAYS 8
  547. !define LVS_SORTASCENDING 0x10
  548. !define LVS_SORTDESCENDING 0x20
  549. !define LVS_SHAREIMAGELISTS 0x40
  550. !define LVS_EDITLABELS 0x200
  551. !define LVS_NOSCROLL 0x2000
  552. !define LVS_NOCOLUMNHEADER 0x4000
  553. !define LVS_NOSORTHEADER 0x8000
  554. !define LVS_ICON 0
  555. !define LVS_REPORT 1
  556. !define LVS_SMALLICON 2
  557. !define LVS_LIST 3
  558. !define LVS_EX_CHECKBOXES 4
  559. !define LVS_EX_FULLROWSELECT 0x20
  560. !define LVS_EX_INFOTIP 0x400
  561. !define LVS_EX_LABELTIP 0x4000
  562. !define LVS_EX_DOUBLEBUFFER 0x10000
  563. !define LVIF_TEXT 1
  564. !define LVIF_IMAGE 2
  565. !define LVIF_PARAM 4
  566. !define LVIF_STATE 8
  567. !define LVIS_STATEIMAGEMASK 0xF000
  568. !define LVCF_FMT 1
  569. !define LVCF_WIDTH 2
  570. !define LVCF_TEXT 4
  571. !define LVCF_SUBITEM 8
  572. !define SYSSTRUCT_LVITEM_V1 (i,i,i,i,&i${NSIS_PTR_SIZE},t,i,i,p)
  573. !define SYSSTRUCT_LVITEM_V2 (i,i,i,i,&i${NSIS_PTR_SIZE},t,i,i,p,i) ; IE3
  574. !define SYSSTRUCT_LVITEM_V3 (i,i,i,i,&i${NSIS_PTR_SIZE},t,i,i,p,i,i,i,i) ; WinXP + ComCtl32 v6
  575. !define SYSSTRUCT_LVITEM_V4 (i,i,i,i,&i${NSIS_PTR_SIZE},t,i,i,p,i,i,i,i,i,i) ; WinVista + ComCtl32 v6
  576. !define LVSCW_AUTOSIZE -1
  577. !define LVSCW_AUTOSIZE_USEHEADER -2
  578. !define LVM_FIRST 0x00001000
  579. !define /math LVM_GETIMAGELIST ${LVM_FIRST} + 2
  580. !define /math LVM_SETIMAGELIST ${LVM_FIRST} + 3
  581. !define /math LVM_GETITEMCOUNT ${LVM_FIRST} + 4
  582. !define /math LVM_GETITEMA ${LVM_FIRST} + 5
  583. !define /math LVM_SETITEMA ${LVM_FIRST} + 6
  584. !define /math LVM_INSERTITEMA ${LVM_FIRST} + 7
  585. !define /math LVM_DELETEITEM ${LVM_FIRST} + 8
  586. !define /math LVM_DELETEALLITEMS ${LVM_FIRST} + 9
  587. !define /math LVM_INSERTCOLUMNA ${LVM_FIRST} + 27
  588. !define /math LVM_SETCOLUMNWIDTH ${LVM_FIRST} + 30
  589. !define /math LVM_SETITEMSTATE ${LVM_FIRST} + 43
  590. !define /math LVM_GETITEMSTATE ${LVM_FIRST} + 44
  591. !define /math LVM_SETITEMTEXTA ${LVM_FIRST} + 46
  592. !define /math LVM_SETITEMCOUNT ${LVM_FIRST} + 47
  593. !define /math LVM_SORTITEMS ${LVM_FIRST} + 48
  594. !define /math LVM_SETEXTENDEDLISTVIEWSTYLE ${LVM_FIRST} + 54
  595. !define /math LVM_GETEXTENDEDLISTVIEWSTYLE ${LVM_FIRST} + 55
  596. !define /math LVM_GETITEMW ${LVM_FIRST} + 75
  597. !define /math LVM_SETITEMW ${LVM_FIRST} + 76
  598. !define /math LVM_INSERTITEMW ${LVM_FIRST} + 77
  599. !define /math LVM_INSERTCOLUMNW ${LVM_FIRST} + 97
  600. !define /math LVM_SETITEMTEXTW ${LVM_FIRST} + 116
  601. !define /math LVM_SETSELECTEDCOLUMN ${LVM_FIRST} + 140
  602. ${_NSIS_DEFAW} LVM_GETITEM
  603. ${_NSIS_DEFAW} LVM_SETITEM
  604. ${_NSIS_DEFAW} LVM_INSERTITEM
  605. ${_NSIS_DEFAW} LVM_INSERTCOLUMN
  606. ${_NSIS_DEFAW} LVM_SETITEMTEXT
  607. #Status bar window#
  608. !define SB_CONST_ALPHA 0x00000001
  609. !define SB_GRAD_RECT 0x00000010
  610. !define SB_GRAD_TRI 0x00000020
  611. !define SB_NONE 0x00000000
  612. !define SB_PIXEL_ALPHA 0x00000002
  613. !define SB_PREMULT_ALPHA 0x00000004
  614. !define SB_SIMPLEID 0x00ff
  615. #Scroll bar control#
  616. !define SBM_ENABLE_ARROWS 0x00E4 # Not in win3.1
  617. !define SBM_GETPOS 0x00E1 # Not in win3.1
  618. !define SBM_GETRANGE 0x00E3 # Not in win3.1
  619. !define SBM_GETSCROLLINFO 0x00EA
  620. !define SBM_SETPOS 0x00E0 # Not in win3.1
  621. !define SBM_SETRANGE 0x00E2 # Not in win3.1
  622. !define SBM_SETRANGEREDRAW 0x00E6 # Not in win3.1
  623. !define SBM_SETSCROLLINFO 0x00E9
  624. #Static control#
  625. !define STM_GETICON 0x0171
  626. !define STM_GETIMAGE 0x0173
  627. !define STM_MSGMAX 0x0174
  628. !define STM_ONLY_THIS_INTERFACE 0x00000001
  629. !define STM_ONLY_THIS_NAME 0x00000008
  630. !define STM_ONLY_THIS_PROTOCOL 0x00000002
  631. !define STM_ONLY_THIS_TYPE 0x00000004
  632. !define STM_SETICON 0x0170
  633. !define STM_SETIMAGE 0x0172
  634. #Tab control#
  635. !define TCS_SCROLLOPPOSITE 0x0001
  636. !define TCIF_TEXT 1
  637. !define TCIF_PARAM 8
  638. !define SYSSTRUCT_TCITEM (i,i,&i${NSIS_PTR_SIZE},t,i,i,p)
  639. !define TCM_FIRST 0x1300
  640. !define /math TCM_INSERTITEMA ${TCM_FIRST} + 7
  641. !define /math TCM_GETCURSEL ${TCM_FIRST} + 11
  642. !define /math TCM_ADJUSTRECT ${TCM_FIRST} + 40
  643. !define /math TCM_INSERTITEMW ${TCM_FIRST} + 62
  644. !define TCN_SELCHANGE -551
  645. !define TCN_SELCHANGING -552
  646. ${_NSIS_DEFAW} TCM_INSERTITEM
  647. #Progress bar control#
  648. !define PBM_SETRANGE 0x401
  649. !define PBM_SETPOS 0x402
  650. !define PBM_DELTAPOS 0x403
  651. !define PBM_SETSTEP 0x404
  652. !define PBM_STEPIT 0x405
  653. !define PBM_SETRANGE32 0x406 ; IE3 + ComCtl32 v4.70
  654. !define PBM_GETRANGE 0x407
  655. !define PBM_GETPOS 0x408
  656. !define PBM_SETBARCOLOR 0x409 ; IE4 + ComCtl32 v4.71
  657. !define PBM_SETBKCOLOR ${CCM_SETBKCOLOR}
  658. !define PBM_SETMARQUEE 0x40A ; WinXP + ComCtl32 v6
  659. !define PBM_GETSTEP 0x40D ; WinVista
  660. !define PBM_GETBKCOLOR 0x40E
  661. !define PBM_GETBARCOLOR 0x40F
  662. !define PBM_SETSTATE 0x410
  663. !define PBM_GETSTATE 0x411
  664. !define PBST_NORMAL 1
  665. !define PBST_ERROR 2
  666. !define PBST_PAUSED 3
  667. !verbose pop
  668. !endif