winuser.inc
dp4_micrommander/project/include/x64/winuser.inc
;--------------------------------T--------------T-----------------------------------T----------------------------------

	IFDEF	UNICODE

CallWindowProc	equ	CallWindowProcW
CreateDialog	equ	CreateDialogW
CreateDialogParam	equ	CreateDialogParamW
CreateWindowEx	equ	CreateWindowExW
DefWindowProc	equ	DefWindowProcW
DialogBoxParam	equ	DialogBoxParamW
DispatchMessage	equ	DispatchMessageW
GetClassLongPtr	equ	GetClassLongPtrW
GetDlgItemText	equ	GetDlgItemTextW
GetKeyNameText	equ	GetKeyNameTextW
GetMenuItemInfo	equ	GetMenuItemInfoW
GetWindowLongPtr	equ	GetWindowLongPtrW
GetMessage	equ	GetMessageW
LoadBitmap	equ	LoadBitmapW
LoadCursor	equ	LoadCursorW	
LoadIcon	equ	LoadIconW
LoadMenu	equ	LoadMenuW
LoadString	equ	LoadStringW
MessageBox	equ	MessageBoxW
PeekMessage	equ	PeekMessageW
PostMessage	equ	PostMessageW
RegisterClassEx	equ	RegisterClassExW
SetClassLongPtr	equ	SetClassLongPtrW
SendDlgItemMessage	equ	SendDlgItemMessageW
SendMessage	equ	SendMessageW
SetDlgItemText	equ	SetDlgItemTextW
SetMenuItemInfo	equ	SetMenuItemInfoW
SetWindowLongPtr	equ	SetWindowLongPtrW
SetWindowText	equ	SetWindowTextW
VkKeyScan		equ	VkKeyScanW
VkKeyScanEx		equ	VkKeyScanExW
wsprintf	equ	wsprintfW
wvsprintf	equ	wvsprintfW

MENUITEMINFO	equ	MENUITEMINFOW
WNDCLASSEX	equ	WNDCLASSEXW

	ELSE

CallWindowProc	equ	CallWindowProcA
CreateDialog	equ	CreateDialogA
CreateDialogParam	equ	CreateDialogParamA
CreateWindowEx	equ	CreateWindowExA
DefWindowProc	equ	DefWindowProcA
DialogBoxParam	equ	DialogBoxParamA
DispatchMessage	equ	DispatchMessageA
GetClassLongPtr	equ	GetClassLongPtrA
GetDlgItemText	equ	GetDlgItemTextA
GetKeyNameText	equ	GetKeyNameTextA
GetMenuItemInfo	equ	GetMenuItemInfoA
GetWindowLongPtr	equ	GetWindowLongPtrA
GetMessage	equ	GetMessageA
LoadBitmap	equ	LoadBitmapA
LoadCursor	equ	LoadCursorA
LoadIcon	equ	LoadIconA
LoadMenu	equ	LoadMenuA
LoadString	equ	LoadStringA
MessageBox	equ	MessageBoxA
PeekMessage	equ	PeekMessageA
PostMessage	equ	PostMessageA
RegisterClassEx	equ	RegisterClassExA
SetClassLongPtr	equ	SetClassLongPtrA
SendDlgItemMessage	equ	SendDlgItemMessageA
SendMessage	equ	SendMessageA
SetDlgItemText	equ	SetDlgItemTextA
SetMenuItemInfo	equ	SetMenuItemInfoA
SetWindowLongPtr	equ	SetWindowLongPtrA
SetWindowText	equ	SetWindowTextA
VkKeyScan		equ	VkKeyScanA
VkKeyScanEx		equ	VkKeyScanExA
wsprintf	equ	wsprintfA
wvsprintf	equ	wvsprintfA

MENUITEMINFO	equ	MENUITEMINFOA
WNDCLASSEX	equ	WNDCLASSEXA

	ENDIF

BeginPaint	proto	:QWORD, :QWORD
CallWindowProcA	proto	:QWORD, :QWORD, :DWORD, :QWORD, :QWORD
CallWindowProcW	proto	:QWORD, :QWORD, :DWORD, :QWORD, :QWORD
ClientToScreen	proto	:QWORD, :QWORD
CreateDialogParamA	proto	:QWORD, :QWORD, :QWORD, :QWORD, :QWORD
CreateDialogParamW	proto	:QWORD, :QWORD, :QWORD, :QWORD, :QWORD
CreateWindowExA	proto	:DWORD, :QWORD, :QWORD, :DWORD, :DWORD, :DWORD, :DWORD, :DWORD, :QWORD, :QWORD, :QWORD, :QWORD
CreateWindowExW	proto	:DWORD, :QWORD, :QWORD, :DWORD, :DWORD, :DWORD, :DWORD, :DWORD, :QWORD, :QWORD, :QWORD, :QWORD
DefWindowProcA	proto	:QWORD, :DWORD, :QWORD, :QWORD
DefWindowProcW	proto	:QWORD, :DWORD, :QWORD, :QWORD
DeleteObject	proto	:QWORD
DestroyIcon	proto	:QWORD
DestroyMenu	proto	:QWORD
DestroyWindow	proto	:QWORD
DialogBoxParamA	proto	:QWORD, :QWORD, :QWORD, :QWORD, :QWORD
DialogBoxParamW	proto	:QWORD, :QWORD, :QWORD, :QWORD, :QWORD
DispatchMessageA	proto	:QWORD
DispatchMessageW	proto	:QWORD
DrawFrameControl	proto	:QWORD, :QWORD, :DWORD, :DWORD
EnableWindow	proto	:QWORD, :DWORD
EndDialog	proto	:QWORD, :QWORD
EndPaint	proto	:QWORD, :QWORD
GetActiveWindow	proto
GetAsyncKeyState	proto	:DWORD
GetClassLongPtrA	proto	:QWORD, :DWORD
GetClassLongPtrW	proto	:QWORD, :DWORD
GetClientRect	proto	:QWORD, :QWORD
GetDlgCtrlID	proto	:QWORD
GetDlgItem	proto	:QWORD, :DWORD
GetDlgItemTextA	proto	:QWORD, :DWORD, :QWORD, :DWORD
GetDlgItemTextW	proto	:QWORD, :DWORD, :QWORD, :DWORD
GetKeyNameTextA	proto	:QWORD, :QWORD, :DWORD
GetKeyNameTextW	proto	:QWORD, :QWORD, :DWORD
GetMenuItemInfoA	proto	:QWORD, :DWORD, :DWORD, :QWORD
GetMenuItemInfoW	proto	:QWORD, :DWORD, :DWORD, :QWORD
GetMessagePos	proto
GetParent	proto	:QWORD
GetSubMenu	proto	:QWORD, :DWORD
GetSystemMetrics	proto	:DWORD
GetWindow	proto	:QWORD, :DWORD
GetWindowLongPtrA	proto	:QWORD, :DWORD
GetWindowLongPtrW	proto	:QWORD, :DWORD
GetWindowPlacement	proto	:QWORD, :QWORD
GetMessageA	proto	:QWORD, :QWORD, :DWORD, :DWORD
GetMessageW	proto	:QWORD, :QWORD, :DWORD, :DWORD
GetUpdateRect	proto	:QWORD, :QWORD, :DWORD
GetWindowRect	proto	:QWORD, :QWORD
InvalidateRect	proto	:QWORD, :QWORD, :DWORD
KillTimer	proto	:QWORD, :DWORD
LoadBitmapA	proto	:QWORD, :QWORD
LoadBitmapW	proto	:QWORD, :QWORD
LoadCursorA	proto	:QWORD, :QWORD
LoadCursorW	proto	:QWORD, :QWORD
LoadIconA	proto	:QWORD, :QWORD
LoadIconW	proto	:QWORD, :QWORD
LoadMenuA	proto	:QWORD, :QWORD
LoadMenuW	proto	:QWORD, :QWORD
LoadStringA	proto	:QWORD, :DWORD, :QWORD, :DWORD
LoadStringW	proto	:QWORD, :DWORD, :QWORD, :DWORD
MessageBoxA	proto	:QWORD, :QWORD, :QWORD, :DWORD
MessageBoxW	proto	:QWORD, :QWORD, :QWORD, :DWORD
MsgWaitForMultipleObjects	proto	:DWORD, :QWORD, :DWORD, :DWORD, :DWORD
MoveWindow	proto	:QWORD, :DWORD, :DWORD, :DWORD, :DWORD, :DWORD
PeekMessageA	proto	:QWORD, :QWORD, :DWORD, :DWORD, :DWORD
PeekMessageW	proto	:QWORD, :QWORD, :DWORD, :DWORD, :DWORD
PostMessageA	proto	:QWORD, :DWORD, :QWORD, :QWORD
PostMessageW	proto	:QWORD, :DWORD, :QWORD, :QWORD
PostQuitMessage	proto	:DWORD
PtInRect	proto	:QWORD, :DWORD, :DWORD
RegisterClassExA	proto	:QWORD
RegisterClassExW	proto	:QWORD
ScreenToClient	proto	:QWORD, :QWORD
SetClassLongPtrA	proto	:QWORD, :DWORD, :QWORD
SetClassLongPtrW	proto	:QWORD, :DWORD, :QWORD
SendDlgItemMessageA	proto	:QWORD, :DWORD, :DWORD, :QWORD, :QWORD
SendDlgItemMessageW	proto	:QWORD, :DWORD, :DWORD, :QWORD, :QWORD
SendMessageA	proto	:QWORD, :DWORD, :QWORD, :QWORD
SendMessageW	proto	:QWORD, :DWORD, :QWORD, :QWORD
SetDlgItemTextA	proto	:QWORD, :DWORD, :QWORD
SetDlgItemTextW	proto	:QWORD, :DWORD, :QWORD
SetFocus	proto	:QWORD
SetMenuItemInfoA	proto	:QWORD, :DWORD, :DWORD, :QWORD
SetMenuItemInfoW	proto	:QWORD, :DWORD, :DWORD, :QWORD
SetTimer	proto	:QWORD, :DWORD, :DWORD, :QWORD
SetWindowLongPtrA	proto	:QWORD, :DWORD, :QWORD
SetWindowLongPtrW	proto	:QWORD, :DWORD, :QWORD
SetWindowPlacement	proto	:QWORD, :QWORD
SetWindowTextA	proto	:QWORD, :QWORD
SetWindowTextW	proto	:QWORD, :QWORD
ShowWindow	proto	:QWORD, :DWORD
TrackPopupMenu	proto	:QWORD, :DWORD, :DWORD, :DWORD, :DWORD, :QWORD, :QWORD
TranslateMessage	proto	:QWORD
UpdateWindow	proto	:QWORD
wsprintfA	proto	:QWORD, :QWORD
ValidateRect	proto	:QWORD, :QWORD
VkKeyScan	proto	:WORD
VkKeyScanEx	proto	:WORD
wsprintfW	proto	:QWORD, :QWORD

CW_USEDEFAULT 	= 80000000h


; Window field offsets for GetWindowLong

GWL_WNDPROC	= -4
GWL_HINSTANCE	= -6
GWL_HWNDPARENT	= -8
GWL_STYLE	= -16
GWL_EXSTYLE	= -20
GWL_USERDATA	= -21
GWL_ID	= -12

; Class field offsets for GetClassLong

GCL_MENUNAME	= -8
GCL_HBRBACKGROUND	= -10
GCL_HCURSOR	= -12
GCL_HICON	= -14
GCL_HMODULE	= -16
GCL_CBWNDEXTRA	= -18
GCL_CBCLSEXTRA	= -20
GCL_WNDPROC	= -24
GCL_STYLE	= -26
GCW_ATOM	= -32
GCL_HICONSM	= -34

GCLP_MENUNAME 	= (-8)
GCLP_HBRBACKGROUND	= (-10)
GCLP_HCURSOR	= (-12)
GCLP_HICON	= (-14)
GCLP_HMODULE	= (-16)
GCLP_WNDPROC	= (-24)
GCLP_HICONSM	= (-34)

MSG	STRUC
 hwnd	dq	?
 message	dd	?
 	dd	?
 wParam	dq	?
 lParam	dq	?
 time	dd	?
 pt	dd	?, ?
 	dd	?
MSG	ENDS

WNDCLASSEXW	STRUC
 cbSize	dd	?
 style	dd	?
 lpfnWndProc	dq	?
 cbClsExtra	dd	?
 cbWndExtra	dd	?
 hInstance	dq	?
 hIcon	dq	?
 hCursor	dq	?
 hbrBackground	dq	?
 lpszMenuName	dq	?
 lpszClassName	dq	?
 hIconSm	dq	?
WNDCLASSEXW	ENDS

; Window Messages

WM_NULL 	= 0000h
WM_CREATE 	= 0001h
WM_DESTROY	= 0002h
WM_MOVE 	= 0003h
WM_SIZE 	= 0005h
WM_ACTIVATE 	= 0006h

; WM_ACTIVATE state values

WA_INACTIVE	= 0
WA_ACTIVE	= 1
WA_CLICKACTIVE	= 2

WM_SETFOCUS 	= 0007h
WM_KILLFOCUS	= 0008h
WM_ENABLE 	= 000Ah
WM_SETREDRAW	= 000Bh
WM_SETTEXT	= 000Ch
WM_GETTEXT	= 000Dh
WM_GETTEXTLENGTH	= 000Eh
WM_PAINT	= 000Fh
WM_CLOSE	= 0010h
WM_QUERYENDSESSION	= 0011h
WM_QUIT 	= 0012h
WM_QUERYOPEN	= 0013h
WM_ERASEBKGND 	= 0014h
WM_SYSCOLORCHANGE 	= 0015h
WM_ENDSESSION 	= 0016h
WM_SHOWWINDOW 	= 0018h
WM_WININICHANGE 	= 001Ah
WM_SETTINGCHANGE	= WM_WININICHANGE
WM_DEVMODECHANGE	= 001Bh
WM_ACTIVATEAPP	= 001Ch
WM_FONTCHANGE 	= 001Dh
WM_TIMECHANGE 	= 001Eh
WM_CANCELMODE 	= 001Fh
WM_SETCURSOR	= 0020h
WM_MOUSEACTIVATE	= 0021h
WM_CHILDACTIVATE	= 0022h
WM_QUEUESYNC	= 0023h
WM_GETMINMAXINFO	= 0024h
WM_PAINTICON	= 0026h
WM_ICONERASEBKGND 	= 0027h
WM_NEXTDLGCTL 	= 0028h
WM_SPOOLERSTATUS	= 002Ah
WM_DRAWITEM 	= 002Bh
WM_MEASUREITEM	= 002Ch
WM_DELETEITEM 	= 002Dh
WM_VKEYTOITEM 	= 002Eh
WM_CHARTOITEM 	= 002Fh
WM_SETFONT	= 0030h
WM_GETFONT	= 0031h
WM_SETHOTKEY	= 0032h
WM_GETHOTKEY	= 0033h
WM_QUERYDRAGICON	= 0037h
WM_COMPAREITEM	= 0039h
WM_COMPACTING 	= 0041h
WM_COMMNOTIFY 	= 0044h	; no longer suported
WM_WINDOWPOSCHANGING	= 0046h
WM_WINDOWPOSCHANGED 	= 0047h
WM_POWER	= 0048h
WM_COPYDATA 	= 004Ah
WM_CANCELJOURNAL	= 004Bh
WM_NOTIFY 	= 004Eh
WM_INPUTLANGCHANGEREQUEST 	= 0050h
WM_INPUTLANGCHANGE	= 0051h
WM_TCARD	= 0052h
WM_HELP 	= 0053h
WM_USERCHANGED	= 0054h
WM_NOTIFYFORMAT 	= 0055h
WM_CONTEXTMENU	= 007Bh
WM_STYLECHANGING	= 007Ch
WM_STYLECHANGED 	= 007Dh
WM_DISPLAYCHANGE	= 007Eh
WM_GETICON	= 007Fh
WM_SETICON	= 0080h
WM_NCCREATE 	= 0081h
WM_NCDESTROY	= 0082h
WM_NCCALCSIZE 	= 0083h
WM_NCHITTEST	= 0084h
WM_NCPAINT	= 0085h
WM_NCACTIVATE 	= 0086h
WM_GETDLGCODE 	= 0087h
WM_NCMOUSEMOVE	= 00A0h
WM_NCLBUTTONDOWN	= 00A1h
WM_NCLBUTTONUP	= 00A2h
WM_NCLBUTTONDBLCLK	= 00A3h
WM_NCRBUTTONDOWN	= 00A4h
WM_NCRBUTTONUP	= 00A5h
WM_NCRBUTTONDBLCLK	= 00A6h
WM_NCMBUTTONDOWN	= 00A7h
WM_NCMBUTTONUP	= 00A8h
WM_NCMBUTTONDBLCLK	= 00A9h
WM_KEYFIRST 	= 0100h
WM_KEYDOWN	= 0100h
WM_KEYUP	= 0101h
WM_CHAR 	= 0102h
WM_DEADCHAR 	= 0103h
WM_SYSKEYDOWN 	= 0104h
WM_SYSKEYUP 	= 0105h
WM_SYSCHAR	= 0106h
WM_SYSDEADCHAR	= 0107h
WM_KEYLAST	= 0108h
WM_IME_STARTCOMPOSITION 	= 010Dh
WM_IME_ENDCOMPOSITION 	= 010Eh
WM_IME_COMPOSITION	= 010Fh
WM_IME_KEYLAST	= 010Fh
WM_INITDIALOG 	= 0110h
WM_COMMAND	= 0111h
WM_SYSCOMMAND 	= 0112h
WM_TIMER	= 0113h
WM_HSCROLL	= 0114h
WM_VSCROLL	= 0115h
WM_INITMENU 	= 0116h
WM_INITMENUPOPUP	= 0117h
WM_MENUSELECT 	= 011Fh
WM_MENUCHAR 	= 0120h
WM_ENTERIDLE	= 0121h
WM_CTLCOLORMSGBOX 	= 0132h
WM_CTLCOLOREDIT 	= 0133h
WM_CTLCOLORLISTBOX	= 0134h
WM_CTLCOLORBTN	= 0135h
WM_CTLCOLORDLG	= 0136h
WM_CTLCOLORSCROLLBAR	= 0137h
WM_CTLCOLORSTATIC 	= 0138h
WM_MOUSEFIRST 	= 0200h
WM_MOUSEMOVE	= 0200h
WM_LBUTTONDOWN	= 0201h
WM_LBUTTONUP	= 0202h
WM_LBUTTONDBLCLK	= 0203h
WM_RBUTTONDOWN	= 0204h
WM_RBUTTONUP	= 0205h
WM_RBUTTONDBLCLK	= 0206h
WM_MBUTTONDOWN	= 0207h
WM_MBUTTONUP	= 0208h
WM_MBUTTONDBLCLK	= 0209h
WM_MOUSEWHEEL 	= 020Ah
WM_MOUSELAST	= 020Ah

WM_PARENTNOTIFY 	= 0210h
WM_ENTERMENULOOP	= 0211h
WM_EXITMENULOOP 	= 0212h
WM_NEXTMENU 	= 0213h
WM_SIZING 	= 0214h
WM_CAPTURECHANGED 	= 0215h
WM_MOVING 	= 0216h
WM_POWERBROADCAST 	= 0218h
WM_DEVICECHANGE 	= 0219h
WM_IME_SETCONTEXT 	= 0281h
WM_IME_NOTIFY 	= 0282h
WM_IME_CONTROL	= 0283h
WM_IME_COMPOSITIONFULL	= 0284h
WM_IME_SELECT 	= 0285h
WM_IME_CHAR 	= 0286h
WM_IME_KEYDOWN	= 0290h
WM_IME_KEYUP	= 0291h
WM_MDICREATE	= 0220h
WM_MDIDESTROY 	= 0221h
WM_MDIACTIVATE	= 0222h
WM_MDIRESTORE 	= 0223h
WM_MDINEXT	= 0224h
WM_MDIMAXIMIZE	= 0225h
WM_MDITILE	= 0226h
WM_MDICASCADE 	= 0227h
WM_MDIICONARRANGE 	= 0228h
WM_MDIGETACTIVE 	= 0229h
WM_MDISETMENU 	= 0230h
WM_ENTERSIZEMOVE	= 0231h
WM_EXITSIZEMOVE 	= 0232h
WM_DROPFILES	= 0233h
WM_MDIREFRESHMENU 	= 0234h
WM_MOUSEHOVER 	= 02A1h
WM_MOUSELEAVE 	= 02A3h
WM_CUT	= 0300h
WM_COPY 	= 0301h
WM_PASTE	= 0302h
WM_CLEAR	= 0303h
WM_UNDO 	= 0304h
WM_RENDERFORMAT 	= 0305h
WM_RENDERALLFORMATS 	= 0306h
WM_DESTROYCLIPBOARD 	= 0307h
WM_DRAWCLIPBOARD	= 0308h
WM_PAINTCLIPBOARD 	= 0309h
WM_VSCROLLCLIPBOARD 	= 030Ah
WM_SIZECLIPBOARD	= 030Bh
WM_ASKCBFORMATNAME	= 030Ch
WM_CHANGECBCHAIN	= 030Dh
WM_HSCROLLCLIPBOARD 	= 030Eh
WM_QUERYNEWPALETTE	= 030Fh
WM_PALETTEISCHANGING	= 0310h
WM_PALETTECHANGED 	= 0311h
WM_HOTKEY 	= 0312h
WM_PRINT	= 0317h
WM_PRINTCLIENT	= 0318h
WM_HANDHELDFIRST	= 0358h
WM_HANDHELDLAST 	= 035Fh
WM_AFXFIRST 	= 0360h
WM_AFXLAST	= 037Fh
WM_PENWINFIRST	= 0380h
WM_PENWINLAST 	= 038Fh
WM_APP	= 8000h

; NOTE: All Message Numbers below 0400 are RESERVED.

; Private Window Messages Start Here:

WM_USER 	= 0400h

WINDOWPLACEMENT	STRUC
 len	dd	?
 flags	dd	?
 showCmd	dd	?
 ptMinPosition	POINT	<?>
 ptMaxPosition	POINT	<?>
 rcNormalPosition	RECT	<?>
WINDOWPLACEMENT	ENDS

WPF_SETMINPOSITION	= 0001h
WPF_RESTORETOMAXIMIZED	= 0002h

; Standard Cursor IDs

IDC_ARROW	= 32512
IDC_IBEAM	= 32513
IDC_WAIT	= 32514
IDC_CROSS	= 32515
IDC_UPARROW	= 32516
IDC_SIZE	= 32640	; OBSOLETE: use IDC_SIZEALL ;
IDC_ICON	= 32641	; OBSOLETE: use IDC_ARROW ;
IDC_SIZENWSE	= 32642
IDC_SIZENESW	= 32643
IDC_SIZEWE	= 32644
IDC_SIZENS	= 32645
IDC_SIZEALL	= 32646
IDC_NO	= 32648	;not in win3.1 ;
IDC_HAND 	= 32649
IDC_APPSTARTING	= 32650	;not in win3.1 ;
IDC_HELP	= 32651

; Predefined Resource Types

RT_CURSOR	= 1
RT_BITMAP	= 2
RT_ICON	= 3
RT_MENU	= 4
RT_DIALOG	= 5
RT_STRING	= 6
RT_FONTDIR	= 7
RT_FONT	= 8
RT_ACCELERATOR	= 9
RT_RCDATA	= 10
RT_MESSAGETABLE	= 11

DIFFERENCE	= 11
RT_GROUP_CURSOR	= RT_CURSOR + DIFFERENCE
RT_GROUP_ICON	= RT_ICON + DIFFERENCE
RT_VERSION	= 16
RT_DLGINCLUDE	= 17
RT_PLUGPLAY	= 19
RT_VXD	= 20
RT_ANICURSOR	= 21
RT_ANIICON	= 22

; Class styles

CS_VREDRAW	= 0001h
CS_HREDRAW	= 0002h
CS_KEYCVTWINDOW 	= 0004h
CS_DBLCLKS	= 0008h
CS_OWNDC	= 0020h
CS_CLASSDC	= 0040h
CS_PARENTDC 	= 0080h
CS_NOKEYCVT 	= 0100h
CS_NOCLOSE	= 0200h
CS_SAVEBITS 	= 0800h
CS_BYTEALIGNCLIENT	= 1000h
CS_BYTEALIGNWINDOW	= 2000h
CS_GLOBALCLASS	= 4000h
CS_IME	= 00010000h

; Color Types

CTLCOLOR_MSGBOX	= 0
CTLCOLOR_EDIT	= 1
CTLCOLOR_LISTBOX	= 2
CTLCOLOR_BTN	= 3
CTLCOLOR_DLG	= 4
CTLCOLOR_SCROLLBAR	= 5
CTLCOLOR_STATIC	= 6
CTLCOLOR_MAX	= 7

COLOR_SCROLLBAR	= 0
COLOR_BACKGROUND	= 1
COLOR_ACTIVECAPTION	= 2
COLOR_INACTIVECAPTION	= 3
COLOR_MENU	= 4
COLOR_WINDOW = 5
COLOR_WINDOWFRAME	= 6
COLOR_MENUTEXT	= 7
COLOR_WINDOWTEXT	= 8
COLOR_CAPTIONTEXT	= 9
COLOR_ACTIVEBORDER	= 10
COLOR_INACTIVEBORDER	= 11
COLOR_APPWORKSPACE	= 12
COLOR_HIGHLIGHT	= 13
COLOR_HIGHLIGHTTEXT	= 14
COLOR_BTNFACE		= 15
COLOR_BTNSHADOW	= 16
COLOR_GRAYTEXT		= 17
COLOR_BTNTEXT		= 18
COLOR_INACTIVECAPTIONTEXT	= 19
COLOR_BTNHIGHLIGHT	= 20
COLOR_3DDKSHADOW	= 21
COLOR_3DLIGHT		= 22
COLOR_INFOTEXT		= 23
COLOR_INFOBK		= 24
COLOR_DESKTOP		= COLOR_BACKGROUND
COLOR_3DFACE		= COLOR_BTNFACE
COLOR_3DSHADOW	= COLOR_BTNSHADOW
COLOR_3DHIGHLIGHT	= COLOR_BTNHIGHLIGHT
COLOR_3DHILIGHT	= COLOR_BTNHIGHLIGHT
COLOR_BTNHILIGHT	= COLOR_BTNHIGHLIGHT

; GetSystemMetrics codes

SM_CXSCREEN		= 0
SM_CYSCREEN		= 1
SM_CXVSCROLL		= 2
SM_CYHSCROLL		= 3
SM_CYCAPTION		= 4
SM_CXBORDER		= 5
SM_CYBORDER		= 6
SM_CXDLGFRAME		= 7
SM_CYDLGFRAME		= 8
SM_CYVTHUMB		= 9
SM_CXHTHUMB		= 10
SM_CXICON		= 11
SM_CYICON		= 12
SM_CXCURSOR		= 13
SM_CYCURSOR		= 14
SM_CYMENU		= 15
SM_CXFULLSCREEN	= 16
SM_CYFULLSCREEN	= 17
SM_CYKANJIWINDOW	= 18
SM_MOUSEPRESENT	= 19
SM_CYVSCROLL		= 20
SM_CXHSCROLL		= 21
SM_DEBUG		= 22
SM_SWAPBUTTON		= 23
SM_RESERVED1		= 24
SM_RESERVED2		= 25
SM_RESERVED3		= 26
SM_RESERVED4		= 27
SM_CXMIN		= 28
SM_CYMIN		= 29
SM_CXSIZE		= 30
SM_CYSIZE		= 31
SM_CXFRAME		= 32
SM_CYFRAME		= 33
SM_CXMINTRACK		= 34
SM_CYMINTRACK		= 35
SM_CXDOUBLECLK		= 36
SM_CYDOUBLECLK		= 37
SM_CXICONSPACING	= 38
SM_CYICONSPACING	= 39
SM_MENUDROPALIGNMENT	= 40
SM_PENWINDOWS	= 41
SM_DBCSENABLED		= 42
SM_CMOUSEBUTTONS	= 43
SM_CXFIXEDFRAME	= SM_CXDLGFRAME	;win40 name change
SM_CYFIXEDFRAME	= SM_CYDLGFRAME		;win40 name change
SM_CXSIZEFRAME		= SM_CXFRAME	 	;win40 name change
SM_CYSIZEFRAME		= SM_CYFRAME	 	;win40 name change
SM_SECURE		= 44
SM_CXEDGE		= 45
SM_CYEDGE		= 46
SM_CXMINSPACING	= 47
SM_CYMINSPACING	= 48
SM_CXSMICON		= 49
SM_CYSMICON		= 50
SM_CYSMCAPTION	= 51
SM_CXSMSIZE		= 52
SM_CYSMSIZE		= 53
SM_CXMENUSIZE		= 54
SM_CYMENUSIZE		= 55
SM_ARRANGE		= 56
SM_CXMINIMIZED	= 57
SM_CYMINIMIZED	= 58
SM_CXMAXTRACK		= 59
SM_CYMAXTRACK		= 60
SM_CXMAXIMIZED	= 61
SM_CYMAXIMIZED	= 62
SM_NETWORK		= 63
SM_CLEANBOOT		= 67
SM_CXDRAG		= 68
SM_CYDRAG		= 69
SM_SHOWSOUNDS	= 70
SM_CXMENUCHECK	= 71	; Use instead of GetMenuCheckMarkDimensions!
SM_CYMENUCHECK	= 72
SM_SLOWMACHINE	= 73
SM_MIDEASTENABLED	= 74
SM_MOUSEWHEELPRESENT	= 75
SM_CMETRICS		= 75	;;SM_CMETRICS 76

; Window Styles

WS_OVERLAPPED 		= 00000000h
WS_POPUP		= 80000000h
WS_CHILD		= 40000000h
WS_MINIMIZE 		= 20000000h
WS_VISIBLE		= 10000000h
WS_DISABLED 		= 08000000h
WS_CLIPSIBLINGS 	= 04000000h
WS_CLIPCHILDREN 	= 02000000h
WS_MAXIMIZE 		= 01000000h
WS_CAPTION		= 00C00000h 		; WS_BORDER + WS_DLGFRAME;
WS_BORDER 		= 00800000h
WS_DLGFRAME 		= 00400000h
WS_VSCROLL		= 00200000h
WS_HSCROLL		= 00100000h
WS_SYSMENU		= 00080000h
WS_THICKFRAME 		= 00040000h
WS_GROUP		= 00020000h
WS_TABSTOP		= 00010000h
WS_MINIMIZEBOX	= 00020000h
WS_MAXIMIZEBOX	= 00010000h
WS_TILED		= WS_OVERLAPPED
WS_ICONIC		= WS_MINIMIZE
WS_SIZEBOX		= WS_THICKFRAME
WS_TILEDWINDOW	= WS_OVERLAPPEDWINDOW

; Common Window Styles

WS_OVERLAPPEDWINDOW	= WS_OVERLAPPED + WS_CAPTION + WS_SYSMENU + WS_THICKFRAME + WS_MINIMIZEBOX + WS_MAXIMIZEBOX
WS_POPUPWINDOW	= WS_POPUP + WS_BORDER + WS_SYSMENU
WS_CHILDWINDOW	= WS_CHILD

; Extended Window Styles

WS_EX_DLGMODALFRAME 	= 00000001h
WS_EX_NOPARENTNOTIFY	= 00000004h
WS_EX_TOPMOST 		= 00000008h
WS_EX_ACCEPTFILES 	= 00000010h
WS_EX_TRANSPARENT 	= 00000020h
WS_EX_MDICHILD		= 00000040h
WS_EX_TOOLWINDOW	= 00000080h
WS_EX_WINDOWEDGE	= 00000100h
WS_EX_CLIENTEDGE	= 00000200h
WS_EX_CONTEXTHELP 	= 00000400h
WS_EX_RIGHT 		= 00001000h
WS_EX_LEFT		= 00000000h
WS_EX_RTLREADING	= 00002000h
WS_EX_LTRREADING	= 00000000h
WS_EX_LEFTSCROLLBAR 	= 00004000h
WS_EX_RIGHTSCROLLBAR	= 00000000h
WS_EX_CONTROLPARENT 	= 00010000h
WS_EX_STATICEDGE	= 00020000h
WS_EX_APPWINDOW 	= 00040000h
WS_EX_OVERLAPPEDWINDOW	= WS_EX_WINDOWEDGE + WS_EX_CLIENTEDGE
WS_EX_PALETTEWINDOW	= WS_EX_WINDOWEDGE + WS_EX_TOOLWINDOW + WS_EX_TOPMOST

GWLP_WNDPROC	= (-4)
GWLP_HINSTANCE	= (-6)
GWLP_HWNDPARENT 	= (-8)
GWLP_USERDATA 	= (-21)
GWLP_ID 		= (-12)

; ShowWindow Commands

SW_HIDE		= 0
SW_SHOWNORMAL	= 1
SW_NORMAL		= 1
SW_SHOWMINIMIZED	= 2
SW_SHOWMAXIMIZED	= 3
SW_MAXIMIZE		= 3
SW_SHOWNOACTIVATE	= 4
SW_SHOW		= 5
SW_MINIMIZE		= 6
SW_SHOWMINNOACTIVE	= 7
SW_SHOWNA		= 8
SW_RESTORE		= 9
SW_SHOWDEFAULT	= 10
SW_MAX		= 10

; Old ShowWindow Commands

HIDE_WINDOW		= 0
SHOW_OPENWINDOW	= 1
SHOW_ICONWINDOW	= 2
SHOW_FULLSCREEN	= 3
SHOW_OPENNOACTIVATE	= 4



; WM_PRINT flags ;

PRF_CHECKVISIBLE	= 00000001h
PRF_NONCLIENT 		= 00000002h
PRF_CLIENT		= 00000004h
PRF_ERASEBKGND		= 00000008h
PRF_CHILDREN		= 00000010h
PRF_OWNED 		= 00000020h

; 3D border styles ;
BDR_RAISEDOUTER 	= 0001h
BDR_SUNKENOUTER 	= 0002h
BDR_RAISEDINNER 	= 0004h
BDR_SUNKENINNER 	= 0008h
BDR_OUTER 		= 0003h
BDR_INNER 		= 000ch
BDR_RAISED		= 0005h
BDR_SUNKEN		= 000ah

EDGE_RAISED		= BDR_RAISEDOUTER + BDR_RAISEDINNER
EDGE_SUNKEN		= BDR_SUNKENOUTER + BDR_SUNKENINNER
EDGE_ETCHED		= BDR_SUNKENOUTER + BDR_RAISEDINNER
EDGE_BUMP		= BDR_RAISEDOUTER + BDR_SUNKENINNER

; Border flags

BF_LEFT 		= 0001h
BF_TOP		= 0002h
BF_RIGHT		= 0004h
BF_BOTTOM 		= 0008h
BF_TOPLEFT		= BF_TOP + BF_LEFT
BF_TOPRIGHT		= BF_TOP + BF_RIGHT
BF_BOTTOMLEFT		= BF_BOTTOM + BF_LEFT
BF_BOTTOMRIGHT		= BF_BOTTOM + BF_RIGHT
BF_RECT		= BF_LEFT + BF_TOP + BF_RIGHT + BF_BOTTOM
BF_DIAGONAL 		= 0010h

; For diagonal lines, the BF_RECT flags specify the end point of the vector bounded by the rectangle parameter.

BF_DIAGONAL_ENDTOPRIGHT	= BF_DIAGONAL + BF_TOP + BF_RIGHT
BF_DIAGONAL_ENDTOPLEFT	= BF_DIAGONAL + BF_TOP + BF_LEFT
BF_DIAGONAL_ENDBOTTOMLEFT	= BF_DIAGONAL + BF_BOTTOM + BF_LEFT
BF_DIAGONAL_ENDBOTTOMRIGHT	= BF_DIAGONAL + BF_BOTTOM + BF_RIGHT

BF_MIDDLE 	= 0800h	; Fill in the middle
BF_SOFT 	= 1000h	; For softer buttons
BF_ADJUST 	= 2000h	; Calculate the space left over
BF_FLAT 	= 4000h	; For flat rather than 3D borders
BF_MONO 	= 8000h	; For monochrome borders

; flags for DrawFrameControl

DFC_CAPTION	= 1
DFC_MENU	= 2
DFC_SCROLL	= 3
DFC_BUTTON	= 4

DFCS_CAPTIONCLOSE 	= 0000h
DFCS_CAPTIONMIN 	= 0001h
DFCS_CAPTIONMAX 	= 0002h
DFCS_CAPTIONRESTORE 	= 0003h
DFCS_CAPTIONHELP	= 0004h
DFCS_MENUARROW	= 0000h
DFCS_MENUCHECK		= 0001h
DFCS_MENUBULLET 	= 0002h
DFCS_MENUARROWRIGHT 	= 0004h
DFCS_SCROLLUP	 	= 0000h
DFCS_SCROLLDOWN 	= 0001h
DFCS_SCROLLLEFT 	= 0002h
DFCS_SCROLLRIGHT	= 0003h
DFCS_SCROLLCOMBOBOX 	= 0005h
DFCS_SCROLLSIZEGRIP 	= 0008h
DFCS_SCROLLSIZEGRIPRIGHT 	= 0010h
DFCS_BUTTONCHECK	= 0000h
DFCS_BUTTONRADIOIMAGE 	= 0001h
DFCS_BUTTONRADIOMASK	= 0002h
DFCS_BUTTONRADIO	= 0004h
DFCS_BUTTON3STATE 	= 0008h
DFCS_BUTTONPUSH 	= 0010h
DFCS_INACTIVE 		= 0100h
DFCS_PUSHED 		= 0200h
DFCS_CHECKED		= 0400h
DFCS_ADJUSTRECT 	= 2000h
DFCS_FLAT 		= 4000h
DFCS_MONO	 	= 8000h

; flags for DrawCaption

DC_ACTIVE 		= 0001h
DC_SMALLCAP 		= 0002h
DC_ICON 		= 0004h
DC_TEXT 		= 0008h
DC_INBUTTON 		= 0010h

IDANI_OPEN		= 1
IDANI_CLOSE		= 2
IDANI_CAPTION		= 3

; Predefined Clipboard Formats

CF_TEXT		= 1
CF_BITMAP		= 2
CF_METAFILEPICT		= 3
CF_SYLK		= 4
CF_DIF		= 5
CF_TIFF		= 6
CF_OEMTEXT		= 7
CF_DIB		= 8
CF_PALETTE		= 9
CF_PENDATA		= 10
CF_RIFF		= 11
CF_WAVE		= 12
CF_UNICODETEXT		= 13
CF_ENHMETAFILE		= 14
CF_HDROP		= 15
CF_LOCALE		= 16
CF_MAX		= 17
CF_OWNERDISPLAY 	= 0080h
CF_DSPTEXT		= 0081h
CF_DSPBITMAP		= 0082h
CF_DSPMETAFILEPICT	= 0083h
CF_DSPENHMETAFILE 	= 008Eh

; "Private" formats don't get GlobalFree'd

CF_PRIVATEFIRST 		= 0200h
CF_PRIVATELAST		= 02FFh

; "GDIOBJ" formats do get DeleteObject'd

CF_GDIOBJFIRST		= 0300h
CF_GDIOBJLAST 		= 03FFh

PAINTSTRUCT	STRUC
 hdc	dq	?
 fErase	dd	?
 rcPaint	RECT	<?>
 fRestore	dd	?
 fIncUpdate	dd	?
 rgbReserved	db	32 dup(?)
PAINTSTRUCT	ENDS


; Scroll Bar Constants

SB_HORZ	= 0
SB_VERT	= 1
SB_CTL	= 2
SB_BOTH	= 3

; Scroll Bar Commands

SB_LINEUP		= 0
SB_LINELEFT		= 0
SB_LINEDOWN		= 1
SB_LINERIGHT		= 1
SB_PAGEUP		= 2
SB_PAGELEFT		= 2
SB_PAGEDOWN		= 3
SB_PAGERIGHT		= 3
SB_THUMBPOSITION	= 4
SB_THUMBTRACK		= 5
SB_TOP		= 6
SB_LEFT		= 6
SB_BOTTOM		= 7
SB_RIGHT		= 7
SB_ENDSCROLL		= 8


; Identifiers for the WM_SHOWWINDOW message

SW_PARENTCLOSING	= 1
SW_OTHERZOOM		= 2
SW_PARENTOPENING	= 3
SW_OTHERUNZOOM	= 4

; WM_KEYUP/DOWN/CHAR HIWORDlParam flags

KF_EXTENDED 	= 0100h
KF_DLGMODE	= 0800h
KF_MENUMODE 	= 1000h
KF_ALTDOWN	= 2000h
KF_REPEAT 	= 4000h
KF_UP 	= 8000h

; Virtual Keys, Standard Set

VK_LBUTTON	= 01h
VK_RBUTTON	= 02h
VK_CANCEL 	= 03h
VK_MBUTTON	= 04h	; NOT contiguous with L & RBUTTON ;
VK_BACK 	= 08h
VK_TAB	= 09h
VK_CLEAR	= 0Ch
VK_RETURN 	= 0Dh
VK_SHIFT	= 10h
VK_CONTROL	= 11h
VK_MENU 	= 12h
VK_PAUSE	= 13h
VK_CAPITAL	= 14h
VK_ESCAPE 	= 1Bh
VK_SPACE	= 20h
VK_PRIOR	= 21h
VK_NEXT 	= 22h
VK_END	= 23h
VK_HOME 	= 24h
VK_LEFT 	= 25h
VK_UP 	= 26h
VK_RIGHT	= 27h
VK_DOWN 	= 28h
VK_SELECT 	= 29h
VK_PRINT	= 2Ah
VK_EXECUTE	= 2Bh
VK_SNAPSHOT 	= 2Ch
VK_INSERT 	= 2Dh
VK_DELETE 	= 2Eh
VK_HELP 	= 2Fh

; VK_0 thru VK_9 are the same as ASCII '0' thru '9' 30 - 39 ;
; VK_A thru VK_Z are the same as ASCII 'A' thru 'Z' 41 - 5A ;

VK_LWIN 	= 5Bh
VK_RWIN 	= 5Ch
VK_APPS 	= 5Dh
VK_NUMPAD0	= 60h
VK_NUMPAD1	= 61h
VK_NUMPAD2	= 62h
VK_NUMPAD3	= 63h
VK_NUMPAD4	= 64h
VK_NUMPAD5	= 65h
VK_NUMPAD6	= 66h
VK_NUMPAD7	= 67h
VK_NUMPAD8	= 68h
VK_NUMPAD9	= 69h
VK_MULTIPLY 	= 6Ah
VK_ADD	= 6Bh
VK_SEPARATOR	= 6Ch
VK_SUBTRACT 	= 6Dh
VK_DECIMAL	= 6Eh
VK_DIVIDE 	= 6Fh
VK_F1 	= 70h
VK_F2 	= 71h
VK_F3 	= 72h
VK_F4 	= 73h
VK_F5 	= 74h
VK_F6 	= 75h
VK_F7 	= 76h
VK_F8 	= 77h
VK_F9 	= 78h
VK_F10	= 79h
VK_F11	= 7Ah
VK_F12	= 7Bh
VK_F13	= 7Ch
VK_F14	= 7Dh
VK_F15	= 7Eh
VK_F16	= 7Fh
VK_F17	= 80h
VK_F18	= 81h
VK_F19	= 82h
VK_F20	= 83h
VK_F21	= 84h
VK_F22	= 85h
VK_F23	= 86h
VK_F24	= 87h
VK_NUMLOCK	= 90h
VK_SCROLL 	= 91h

; VK_L; & VK_R; - left and right Alt, Ctrl and Shift virtual keys.
; Used only as parameters to GetAsyncKeyState and GetKeyState.
; No other API or message will distinguish left and right keys in this way.

VK_LSHIFT 	= 0A0h
VK_RSHIFT 	= 0A1h
VK_LCONTROL 	= 0A2h
VK_RCONTROL 	= 0A3h
VK_LMENU	= 0A4h
VK_RMENU	= 0A5h
VK_PROCESSKEY 	= 0E5h
VK_ATTN 	= 0F6h
VK_CRSEL	= 0F7h
VK_EXSEL	= 0F8h
VK_EREOF	= 0F9h
VK_PLAY 	= 0FAh
VK_ZOOM 	= 0FBh
VK_NONAME 	= 0FCh
VK_PA1	= 0FDh
VK_OEM_CLEAR	= 0FEh

; SetWindowsHook codes

WH_MIN		= -1
WH_MSGFILTER		= -1
WH_JOURNALRECORD	= 0
WH_JOURNALPLAYBACK	= 1
WH_KEYBOARD		= 2
WH_GETMESSAGE		= 3
WH_CALLWNDPROC	= 4
WH_CBT		= 5
WH_SYSMSGFILTER	= 6
WH_MOUSE		= 7
WH_HARDWARE		= 8
WH_DEBUG		= 9
WH_SHELL		= 10
WH_FOREGROUNDIDLE	= 11
WH_CALLWNDPROCRET	= 12
WH_MAX		= 12
WH_MINHOOK		= WH_MIN
WH_MAXHOOK		= WH_MAX

; Hook Codes

HC_ACTION		= 0
HC_GETNEXT		= 1
HC_SKIP		= 2
HC_NOREMOVE		= 3
HC_NOREM		= HC_NOREMOVE
HC_SYSMODALON		= 4
HC_SYSMODALOFF	= 5

; CBT Hook Codes

HCBT_MOVESIZE		= 0
HCBT_MINMAX		= 1
HCBT_QS		= 2
HCBT_CREATEWND	= 3
HCBT_DESTROYWND	= 4
HCBT_ACTIVATE		= 5
HCBT_CLICKSKIPPED	= 6
HCBT_KEYSKIPPED		= 7
HCBT_SYSCOMMAND	= 8
HCBT_SETFOCUS		= 9


IMAGE_BITMAP		= 0
IMAGE_ICON		= 1
IMAGE_CURSOR		= 2
IMAGE_ENHMETAFILE	= 3

LR_DEFAULTCOLOR 	= 0000h
LR_MONOCHROME 		= 0001h
LR_COLOR		= 0002h
LR_COPYRETURNORG	= 0004h
LR_COPYDELETEORG	= 0008h
LR_LOADFROMFILE 	= 0010h
LR_LOADTRANSPARENT	= 0020h
LR_DEFAULTSIZE		= 0040h
LR_VGACOLOR 		= 0080h
LR_LOADMAP3DCOLORS	= 1000h
LR_CREATEDIBSECTION 	= 2000h
LR_COPYFROMRESOURCE 	= 4000h
LR_SHARED 		= 8000h

DI_MASK 		= 0001h
DI_IMAGE		= 0002h
DI_NORMAL 		= 0003h
DI_COMPAT 		= 0004h
DI_DEFAULTSIZE		= 0008h

RES_ICON	= 1
RES_CURSOR	= 2

; OEM Resource Ordinal Numbers

OBM_CLOSE		= 32754
OBM_UPARROW		= 32753
OBM_DNARROW		= 32752
OBM_RGARROW		= 32751
OBM_LFARROW		= 32750
OBM_REDUCE		= 32749
OBM_ZOOM		= 32748
OBM_RESTORE		= 32747
OBM_REDUCED		= 32746
OBM_ZOOMD		= 32745
OBM_RESTORED		= 32744
OBM_UPARROWD		= 32743
OBM_DNARROWD		= 32742
OBM_RGARROWD		= 32741
OBM_LFARROWD		= 32740
OBM_MNARROW		= 32739
OBM_COMBO		= 32738
OBM_UPARROWI		= 32737
OBM_DNARROWI		= 32736
OBM_RGARROWI		= 32735
OBM_LFARROWI		= 32734
OBM_OLD_CLOSE		= 32767
OBM_SIZE		= 32766
OBM_OLD_UPARROW	= 32765
OBM_OLD_DNARROW	= 32764
OBM_OLD_RGARROW	= 32763
OBM_OLD_LFARROW	= 32762
OBM_BTSIZE		= 32761
OBM_CHECK		= 32760
OBM_CHECKBOXES		= 32759
OBM_BTNCORNERS	= 32758
OBM_OLD_REDUCE		= 32757
OBM_OLD_ZOOM		= 32756
OBM_OLD_RESTORE	= 32755

OCR_NORMAL		= 32512
OCR_IBEAM		= 32513
OCR_WAIT		= 32514
OCR_CROSS		= 32515
OCR_UP		= 32516
OCR_SIZE		= 32640		; OBSOLETE: use OCR_SIZEALL
OCR_ICON		= 32641 		; OBSOLETE: use OCR_NORMAL
OCR_SIZENWSE		= 32642
OCR_SIZENESW		= 32643
OCR_SIZEWE		= 32644
OCR_SIZENS		= 32645
OCR_SIZEALL		= 32646
OCR_ICOCUR		= 32647		; OBSOLETE: use OIC_WINLOGO
OCR_NO		= 32648
OCR_APPSTARTING	= 32650

OIC_SAMPLE		= 32512
OIC_HAND		= 32513
OIC_QUES		= 32514
OIC_BANG		= 32515
OIC_NOTE		= 32516

OIC_WINLOGO		= 32517
OIC_WARNING		= OIC_BANG
OIC_ERROR 		= OIC_HAND
OIC_INFORMATION	= OIC_NOTE

ORD_LANGDRIVER		= 1	; The ordinal number for the entry point of

; Standard Icon IDs

IDI_APPLICATION		= 32512
IDI_HAND		= 32513
IDI_QUESTION		= 32514
IDI_EXCLAMATION	= 32515
IDI_ASTERISK		= 32516
IDI_WINLOGO		= 32517
IDI_WARNING		= IDI_EXCLAMATION
IDI_ERROR		= IDI_HAND
IDI_INFORMATION	= IDI_ASTERISK

; Dialog Box Command IDs

IDOK	= 1
IDCANCEL	= 2
IDABORT	= 3
IDRETRY	= 4
IDIGNORE	= 5
IDYES	= 6
IDNO	= 7
IDCLOSE	= 8
IDHELP	= 9

; Edit Control Styles

ES_LEFT 	= 0000h
ES_CENTER 	= 0001h
ES_RIGHT	= 0002h
ES_MULTILINE	= 0004h
ES_UPPERCASE	= 0008h
ES_LOWERCASE	= 0010h
ES_PASSWORD 	= 0020h
ES_AUTOVSCROLL	= 0040h
ES_AUTOHSCROLL	= 0080h
ES_NOHIDESEL	= 0100h
ES_OEMCONVERT 	= 0400h
ES_READONLY 	= 0800h
ES_WANTRETURN 	= 1000h
ES_NUMBER 	= 2000h

; Edit Control Notification Codes

EN_SETFOCUS 	= 0100h
EN_KILLFOCUS	= 0200h
EN_CHANGE 	= 0300h
EN_UPDATE 	= 0400h
EN_ERRSPACE 	= 0500h
EN_MAXTEXT	= 0501h
EN_HSCROLL	= 0601h
EN_VSCROLL	= 0602h

; Edit control EM_SETMARGIN parameters ;

EC_LEFTMARGIN 	= 0001h
EC_RIGHTMARGIN	= 0002h
EC_USEFONTINFO	= 0ffffh

; Edit Control Messages

EM_GETSEL 		= 00B0h
EM_SETSEL 		= 00B1h
EM_GETRECT		= 00B2h
EM_SETRECT		= 00B3h
EM_SETRECTNP		= 00B4h
EM_SCROLL 		= 00B5h
EM_LINESCROLL 		= 00B6h
EM_SCROLLCARET		= 00B7h
EM_GETMODIFY		= 00B8h
EM_SETMODIFY		= 00B9h
EM_GETLINECOUNT 	= 00BAh
EM_LINEINDEX		= 00BBh
EM_SETHANDLE		= 00BCh
EM_GETHANDLE		= 00BDh
EM_GETTHUMB 		= 00BEh
EM_LINELENGTH 		= 00C1h
EM_REPLACESEL 		= 00C2h
EM_GETLINE		= 00C4h
EM_LIMITTEXT		= 00C5h
EM_CANUNDO		= 00C6h
EM_UNDO 		= 00C7h
EM_FMTLINES 		= 00C8h
EM_LINEFROMCHAR 	= 00C9h
EM_SETTABSTOPS		= 00CBh
EM_SETPASSWORDCHAR	= 00CCh
EM_EMPTYUNDOBUFFER	= 00CDh
EM_GETFIRSTVISIBLELINE	= 00CEh
EM_SETREADONLY		= 00CFh
EM_SETWORDBREAKPROC 	= 00D0h
EM_GETWORDBREAKPROC 	= 00D1h
EM_GETPASSWORDCHAR	= 00D2h
EM_SETMARGINS 		= 00D3h
EM_GETMARGINS 		= 00D4h
EM_SETLIMITTEXT	= EM_LIMITTEXT		;win40 Name change
EM_GETLIMITTEXT 	= 00D5h
EM_POSFROMCHAR	= 00D6h
EM_CHARFROMPOS	= 00D7h

; EDITWORDBREAKPROC code values

WB_LEFT		= 0
WB_RIGHT		= 1
WB_ISDELIMITER		= 2

; Button Control Styles

BS_PUSHBUTTON 		= 00000000h
BS_DEFPUSHBUTTON	= 00000001h
BS_CHECKBOX 		= 00000002h
BS_AUTOCHECKBOX 	= 00000003h
BS_RADIOBUTTON		= 00000004h
BS_3STATE 		= 00000005h
BS_AUTO3STATE 		= 00000006h
BS_GROUPBOX 		= 00000007h
BS_USERBUTTON 		= 00000008h
BS_AUTORADIOBUTTON	= 00000009h
BS_OWNERDRAW		= 0000000Bh
BS_LEFTTEXT 		= 00000020h
BS_TEXT 		= 00000000h
BS_ICON 		= 00000040h
BS_BITMAP 		= 00000080h
BS_LEFT 		= 00000100h
BS_RIGHT		= 00000200h
BS_CENTER 		= 00000300h
BS_TOP		= 00000400h
BS_BOTTOM 		= 00000800h
BS_VCENTER		= 00000C00h
BS_PUSHLIKE 		= 00001000h
BS_MULTILINE		= 00002000h
BS_NOTIFY 		= 00004000h
BS_FLAT 		= 00008000h
BS_RIGHTBUTTON		= BS_LEFTTEXT

; User Button Notification Codes

BN_CLICKED		= 0
BN_PAINT		= 1
BN_HILITE		= 2
BN_UNHILITE		= 3
BN_DISABLE		= 4
BN_DOUBLECLICKED	= 5

BN_PUSHED		= BN_HILITE
BN_UNPUSHED		= BN_UNHILITE
BN_DBLCLK		= BN_DOUBLECLICKED
BN_SETFOCUS		= 6
BN_KILLFOCUS		= 7

; Button Control Messages

BM_GETCHECK		= 00F0h
BM_SETCHECK		= 00F1h
BM_GETSTATE		= 00F2h
BM_SETSTATE		= 00F3h
BM_SETSTYLE		= 00F4h
BM_CLICK 		= 00F5h
BM_GETIMAGE		= 00F6h
BM_SETIMAGE		= 00F7h

BST_UNCHECKED		= 0000h
BST_CHECKED		= 0001h
BST_INDETERMINATE	= 0002h
BST_PUSHED 		= 0004h
BST_FOCUS		= 0008h

; Static Control Constants

SS_LEFT 		= 00000000h
SS_CENTER 		= 00000001h
SS_RIGHT		= 00000002h
SS_ICON 		= 00000003h
SS_BLACKRECT		= 00000004h
SS_GRAYRECT 		= 00000005h
SS_WHITERECT		= 00000006h
SS_BLACKFRAME 		= 00000007h
SS_GRAYFRAME		= 00000008h
SS_WHITEFRAME 		= 00000009h
SS_USERITEM 		= 0000000Ah
SS_SIMPLE 		= 0000000Bh
SS_LEFTNOWORDWRAP 	= 0000000Ch
SS_OWNERDRAW		= 0000000Dh
SS_BITMAP 		= 0000000Eh
SS_ENHMETAFILE		= 0000000Fh
SS_ETCHEDHORZ 		= 00000010h
SS_ETCHEDVERT 		= 00000011h
SS_ETCHEDFRAME		= 00000012h
SS_TYPEMASK 		= 0000001Fh
SS_NOPREFIX 		= 00000080h	; Don't do "&" character translation ;
SS_NOTIFY 		= 00000100h
SS_CENTERIMAGE		= 00000200h
SS_RIGHTJUST		= 00000400h
SS_REALSIZEIMAGE	= 00000800h
SS_SUNKEN 		= 00001000h
SS_ENDELLIPSIS		= 00004000h
SS_PATHELLIPSIS 		= 00008000h
SS_WORDELLIPSIS 	= 0000C000h
SS_ELLIPSISMASK 	= 0000C000h

; Static Control Mesages

STM_SETICON 	= 0170h
STM_GETICON 	= 0171h
STM_SETIMAGE	= 0172h
STM_GETIMAGE	= 0173h

STN_CLICKED	= 0
STN_DBLCLK	= 1
STN_ENABLE	= 2
STN_DISABLE	= 3

STM_MSGMAX	= 0174h

; Dialog window class

WC_DIALOG		= 8002h

; Get/SetWindowWord/Long offsets for use with WC_DIALOG windows

DWL_MSGRESULT	= 0
DWL_DLGPROC	= 4
DWL_USER	= 8

DWLP_MSGRESULT = 0
DWLP_DLGPROC	= DWLP_MSGRESULT + 8
DWLP_USER	= DWLP_DLGPROC + 8

; DlgDirList, DlgDirListComboBox flags values

DDL_READWRITE 	= 0000h
DDL_READONLY	= 0001h
DDL_HIDDEN	= 0002h
DDL_SYSTEM	= 0004h
DDL_DIRECTORY 	= 0010h
DDL_ARCHIVE 	= 0020h
DDL_POSTMSGS	= 2000h
DDL_DRIVES	= 4000h
DDL_EXCLUSIVE 	= 8000h

; Dialog Styles

DS_ABSALIGN 		= 01h
DS_SYSMODAL 		= 02h
DS_LOCALEDIT		= 20h	; Edit items get Local storage.
DS_SETFONT		= 40h	; User specified font for Dlg controls
DS_MODALFRAME 		= 80h	; Can be combined with WS_CAPTION
DS_NOIDLEMSG		= 100h	; WM_ENTERIDLE message will not be sent
DS_SETFOREGROUND	= 200h	; not in win3.1
DS_3DLOOK 		= 0004h
DS_FIXEDSYS 		= 0008h
DS_NOFAILCREATE 	= 0010h
DS_CONTROL		= 0400h
DS_CENTER 		= 0800h
DS_CENTERMOUSE		= 1000h
DS_CONTEXTHELP		= 2000h

DM_GETDEFID		= WM_USER+0
DM_SETDEFID		= WM_USER+1
DM_REPOSITION		= WM_USER+2

PSM_PAGEINFO		= WM_USER+100
PSM_SHEETINFO		= WM_USER+101

PSI_SETACTIVE 	= 0001h
PSI_KILLACTIVE	= 0002h
PSI_APPLY 	= 0003h
PSI_RESET 	= 0004h
PSI_HASHELP 	= 0005h
PSI_HELP	= 0006h
PSI_CHANGED 	= 0001h
PSI_GUISTART	= 0002h
PSI_REBOOT	= 0003h
PSI_GETSIBLINGS 	= 0004h

; Returned in HIWORD of DM_GETDEFID result if msg is supported

DC_HASDEFID 	= 534Bh

; Dialog Codes

DLGC_WANTARROWS 	= 0001h	; Control wants arrow keys ;
DLGC_WANTTAB		= 0002h	; Control wants tab keys ;
DLGC_WANTALLKEYS	= 0004h	; Control wants all keys ;
DLGC_WANTMESSAGE	= 0004h	; Pass message to control;
DLGC_HASSETSEL		= 0008h	; Understands EM_SETSEL message;
DLGC_DEFPUSHBUTTON	= 0010h	; Default pushbutton ;
DLGC_UNDEFPUSHBUTTON 	= 0020h	; Non-default pushbutton ;
DLGC_RADIOBUTTON	= 0040h	; Radio button ;
DLGC_WANTCHARS	= 0080h	; Want WM_CHAR messages;
DLGC_STATIC 		= 0100h	; Static item: don't include ;
DLGC_BUTTON 		= 2000h	; Button item: can be checked;

LB_CTLCODE		= 0h

; Listbox Return Values

LB_OKAY		= 0
LB_ERR		= -1
LB_ERRSPACE		= -2

;The idStaticPath parameter to DlgDirList can have the following values ORed if the list box should show other details of the files along with the name of the files all other details also will be returned

; Listbox Notification Codes

LBN_ERRSPACE		= -2
LBN_SELCHANGE		= 1
LBN_DBLCLK		= 2
LBN_SELCANCEL		= 3
LBN_SETFOCUS		= 4
LBN_KILLFOCUS		= 5

; Listbox messages

LB_ADDSTRING		= 0180h
LB_INSERTSTRING 	= 0181h
LB_DELETESTRING 	= 0182h
LB_SELITEMRANGEEX 	= 0183h
LB_RESETCONTENT 	= 0184h
LB_SETSEL 		= 0185h
LB_SETCURSEL		= 0186h
LB_GETSEL 		= 0187h
LB_GETCURSEL		= 0188h
LB_GETTEXT		= 0189h
LB_GETTEXTLEN 		= 018Ah
LB_GETCOUNT 		= 018Bh
LB_SELECTSTRING 	= 018Ch
LB_DIR		= 018Dh
LB_GETTOPINDEX		= 018Eh
LB_FINDSTRING 		= 018Fh
LB_GETSELCOUNT		= 0190h
LB_GETSELITEMS		= 0191h
LB_SETTABSTOPS		= 0192h
LB_GETHORIZONTALEXTENT	= 0193h
LB_SETHORIZONTALEXTENT	= 0194h
LB_SETCOLUMNWIDTH 	= 0195h
LB_ADDFILE		= 0196h
LB_SETTOPINDEX		= 0197h
LB_GETITEMRECT		= 0198h
LB_GETITEMDATA		= 0199h
LB_SETITEMDATA		= 019Ah
LB_SELITEMRANGE 	= 019Bh
LB_SETANCHORINDEX 	= 019Ch
LB_GETANCHORINDEX 	= 019Dh
LB_SETCARETINDEX	= 019Eh
LB_GETCARETINDEX	= 019Fh
LB_SETITEMHEIGHT	= 01A0h
LB_GETITEMHEIGHT	= 01A1h
LB_FINDSTRINGEXACT	= 01A2h
LB_SETLOCALE		= 01A5h
LB_GETLOCALE		= 01A6h
LB_SETCOUNT 		= 01A7h
LB_INITSTORAGE		= 01A8h
LB_ITEMFROMPOINT	= 01A9h
LB_MSGMAX 		= 01B0h

; Listbox Styles

LBS_NOTIFY		= 0001h
LBS_SORT		= 0002h
LBS_NOREDRAW		= 0004h
LBS_MULTIPLESEL 		= 0008h
LBS_OWNERDRAWFIXED	= 0010h
LBS_OWNERDRAWVARIABLE 	= 0020h
LBS_HASSTRINGS		= 0040h
LBS_USETABSTOPS 	= 0080h
LBS_NOINTEGRALHEIGHT	= 0100h
LBS_MULTICOLUMN 	= 0200h
LBS_WANTKEYBOARDINPUT 	= 0400h
LBS_EXTENDEDSEL 	= 0800h
LBS_DISABLENOSCROLL 	= 1000h
LBS_NODATA		= 2000h
LBS_NOSEL 		= 4000h
LBS_STANDARD		= LBS_NOTIFY + LBS_SORT + WS_VSCROLL + WS_BORDER

; Combo Box return Values

CB_OKAY	= 0
CB_ERR	= -1
CB_ERRSPACE	= -2

; Combo Box Notification Codes

CBN_ERRSPACE		= -1
CBN_SELCHANGE		= 1
CBN_DBLCLK		= 2
CBN_SETFOCUS		= 3
CBN_KILLFOCUS		= 4
CBN_EDITCHANGE		= 5
CBN_EDITUPDATE		= 6
CBN_DROPDOWN		= 7
CBN_CLOSEUP		= 8
CBN_SELENDOK		= 9
CBN_SELENDCANCEL	= 10

; Combo Box styles

CBS_SIMPLE		= 0001h
CBS_DROPDOWN		= 0002h
CBS_DROPDOWNLIST	= 0003h
CBS_OWNERDRAWFIXED	= 0010h
CBS_OWNERDRAWVARIABLE 	= 0020h
CBS_AUTOHSCROLL 	= 0040h
CBS_OEMCONVERT		= 0080h
CBS_SORT		= 0100h
CBS_HASSTRINGS		= 0200h
CBS_NOINTEGRALHEIGHT	= 0400h
CBS_DISABLENOSCROLL 	= 0800h
CBS_UPPERCASE 		= 2000h
CBS_LOWERCASE 		= 4000h

; Combo Box messages

CB_GETEDITSEL 		= 0140h
CB_LIMITTEXT		= 0141h
CB_SETEDITSEL 		= 0142h
CB_ADDSTRING		= 0143h
CB_DELETESTRING 	= 0144h
CB_DIR		= 0145h
CB_GETCOUNT 		= 0146h
CB_GETCURSEL		= 0147h
CB_GETLBTEXT		= 0148h
CB_GETLBTEXTLEN 	= 0149h
CB_INSERTSTRING 	= 014Ah
CB_RESETCONTENT 	= 014Bh
CB_FINDSTRING 		= 014Ch
CB_SELECTSTRING 	= 014Dh
CB_SETCURSEL		= 014Eh
CB_SHOWDROPDOWN 	= 014Fh
CB_GETITEMDATA		= 0150h
CB_SETITEMDATA		= 0151h
CB_GETDROPPEDCONTROLRECT	= 0152h
CB_SETITEMHEIGHT	= 0153h
CB_GETITEMHEIGHT	= 0154h
CB_SETEXTENDEDUI	= 0155h
CB_GETEXTENDEDUI	= 0156h
CB_GETDROPPEDSTATE	= 0157h
CB_FINDSTRINGEXACT	= 0158h
CB_SETLOCALE		= 0159h
CB_GETLOCALE		= 015Ah
CB_GETTOPINDEX		= 015bh
CB_SETTOPINDEX		= 015ch
CB_GETHORIZONTALEXTENT	= 015dh
CB_SETHORIZONTALEXTENT	= 015eh
CB_GETDROPPEDWIDTH	= 015fh
CB_SETDROPPEDWIDTH	= 0160h
CB_INITSTORAGE		= 0161h
CB_MSGMAX 		= 0162h

; Scroll Bar Styles

SBS_HORZ		= 0000h
SBS_VERT		= 0001h
SBS_TOPALIGN		= 0002h
SBS_LEFTALIGN 		= 0002h
SBS_BOTTOMALIGN 	= 0004h
SBS_RIGHTALIGN		= 0004h
SBS_SIZEBOXTOPLEFTALIGN 	= 0002h
SBS_SIZEBOXBOTTOMRIGHTALIGN 	= 0004h
SBS_SIZEBOX 		= 0008h
SBS_SIZEGRIP		= 0010h

; Scroll bar messages

SBM_SETPOS		= 00E0h	 ;not in win3.1
SBM_GETPOS		= 00E1h	 ;not in win3.1
SBM_SETRANGE		= 00E2h	 ;not in win3.1
SBM_SETRANGEREDRAW	= 00E6h	 ;not in win3.1
SBM_GETRANGE		= 00E3h	 ;not in win3.1
SBM_ENABLE_ARROWS 	= 00E4h	 ;not in win3.1
SBM_SETSCROLLINFO 	= 00E9h
SBM_GETSCROLLINFO 	= 00EAh

SIF_RANGE 		= 0001h
SIF_PAGE		= 0002h
SIF_POS 		= 0004h
SIF_DISABLENOSCROLL 	= 0008h
SIF_TRACKPOS		= 0010h
SIF_ALL		= SIF_RANGE + SIF_PAGE + SIF_POS + SIF_TRACKPOS

; Special HWND value for use with PostMessage and SendMessage

HWND_BROADCAST	= 0FFFFh



 ; Special value for CreateWindow, et al.

HWND_DESKTOP		= 0


; SetWindowPos Flags

SWP_NOSIZE		= 0001h
SWP_NOMOVE		= 0002h
SWP_NOZORDER		= 0004h
SWP_NOREDRAW		= 0008h
SWP_NOACTIVATE	= 0010h
SWP_FRAMECHANGED	= 0020h	; The frame changed: send WM_NCCALCSIZE ;
SWP_SHOWWINDOW	= 0040h
SWP_HIDEWINDOW	= 0080h
SWP_NOCOPYBITS		= 0100h
SWP_NOOWNERZORDER 	= 0200h	; Don't do owner Z ordering ;
SWP_NOSENDCHANGING	= 0400h	; Don't send WM_WINDOWPOSCHANGING ;
SWP_DRAWFRAME		= SWP_FRAMECHANGED
SWP_NOREPOSITION	= SWP_NOOWNERZORDER
SWP_DEFERERASE		= 2000h
SWP_ASYNCWINDOWPOS	= 4000h

HWND_TOP		= 0
HWND_BOTTOM		= 1
HWND_TOPMOST		= -1
HWND_NOTOPMOST	= -2

; Defines for the fVirt field of the Accelerator table structure.

FVIRTKEY	= TRUE	; Assumed to be == TRUE ;
FNOINVERT 	= 02h
FSHIFT	= 04h
FCONTROL	= 08h
FALT	= 10h

NMHDR	struc
 hwndFrom	dq	?
 idFrom	dq	?
 lcode	dd	?
 	dd	?
NMHDR	ends


CWP_ALL 		= 0000h
CWP_SKIPINVISIBLE 	= 0001h
CWP_SKIPDISABLED	= 0002h
CWP_SKIPTRANSPARENT 	= 0004h


; GetWindow Constants

GW_HWNDFIRST	= 0
GW_HWNDLAST	= 1
GW_HWNDNEXT	= 2
GW_HWNDPREV	= 3
GW_OWNER	= 4
GW_CHILD	= 5
GW_MAX	= 5


; Menu flags for Add/Check/EnableMenuItem

MF_INSERT 		= 00000000h
MF_CHANGE 		= 00000080h
MF_APPEND 		= 00000100h
MF_DELETE 		= 00000200h
MF_REMOVE 		= 00001000h
MF_BYCOMMAND		= 00000000h
MF_BYPOSITION 		= 00000400h
MF_SEPARATOR		= 00000800h
MF_ENABLED		= 00000000h
MF_GRAYED 		= 00000001h
MF_DISABLED 		= 00000002h
MF_UNCHECKED		= 00000000h
MF_CHECKED		= 00000008h
MF_USECHECKBITMAPS	= 00000200h
MF_STRING 		= 00000000h
MF_BITMAP 		= 00000004h
MF_OWNERDRAW		= 00000100h
MF_POPUP		= 00000010h
MF_MENUBARBREAK 	= 00000020h
MF_MENUBREAK		= 00000040h
MF_UNHILITE 		= 00000000h
MF_HILITE 		= 00000080h
MF_DEFAULT		= 00001000h
MF_SYSMENU		= 00002000h
MF_HELP 		= 00004000h
MF_RIGHTJUSTIFY 	= 00004000h
MF_MOUSESELECT		= 00008000h
MF_END		= 00000080h	; Obsolete -- only used by old RES files ;

MFT_STRING		= MF_STRING
MFT_BITMAP		= MF_BITMAP
MFT_MENUBARBREAK	= MF_MENUBARBREAK
MFT_MENUBREAK		= MF_MENUBREAK
MFT_OWNERDRAW	= MF_OWNERDRAW
MFT_RADIOCHECK		= 00000200h
MFT_SEPARATOR		= MF_SEPARATOR
MFT_RIGHTORDER		= 00002000h
MFT_RIGHTJUSTIFY	= MF_RIGHTJUSTIFY

; Menu flags for Add/Check/EnableMenuItem

MFS_GRAYED		= 00000003h
MFS_DISABLED		= MFS_GRAYED
MFS_CHECKED		= MF_CHECKED
MFS_HILITE		= MF_HILITE
MFS_ENABLED		= MF_ENABLED
MFS_UNCHECKED		= MF_UNCHECKED
MFS_UNHILITE		= MF_UNHILITE
MFS_DEFAULT		= MF_DEFAULT

MIIM_STATE 		= 00000001h
MIIM_ID		= 00000002h
MIIM_SUBMENU 		= 00000004h
MIIM_CHECKMARKS	= 00000008h
MIIM_TYPE		= 00000010h
MIIM_DATA		= 00000020h

MENUITEMINFOA		STRUC
 cbSize		dd	?
 fMask		dd	?
 fType		dd	?	; used if MIIM_TYPE
 fState		dd	?	; used if MIIM_STATE
 wID		dd	?	; used if MIIM_ID
 		dd	?
 hSubMenu		dq	?	; used if MIIM_SUBMENU
 hbmpChecked		dq	?	; used if MIIM_CHECKMARKS
 hbmpUnchecked		dq	?	; used if MIIM_CHECKMARKS
 dwItemData		dq	?	; used if MIIM_DATA
 dwTypeData		dq	?	; used if MIIM_TYPE
 cch		dd	?	; used if MIIM_TYPE
 		dd	?
 hbmpItem		dq	?
MENUITEMINFOA		ENDS

MENUITEMINFOW		STRUC
 cbSize		dd	?
 fMask		dd	?
 fType		dd	?	; used if MIIM_TYPE
 fState		dd	?	; used if MIIM_STATE
 wID		dd	?	; used if MIIM_ID
 		dd	?
 hSubMenu		dq	?	; used if MIIM_SUBMENU
 hbmpChecked		dq	?	; used if MIIM_CHECKMARKS
 hbmpUnchecked		dq	?	; used if MIIM_CHECKMARKS
 dwItemData		dq	?	; used if MIIM_DATA
 dwTypeData		dq	?	; used if MIIM_TYPE
 cch		dd	?	; used if MIIM_TYPE
 		dd	?
 hbmpItem		dq	?
MENUITEMINFOW		ENDS

; MessageBox Flags

MB_OK 		= 00000000h
MB_OKCANCEL 		= 00000001h
MB_ABORTRETRYIGNORE 	= 00000002h
MB_YESNOCANCEL		= 00000003h
MB_YESNO		= 00000004h
MB_RETRYCANCEL		= 00000005h
MB_ICONHAND 		= 00000010h
MB_ICONQUESTION 	= 00000020h
MB_ICONEXCLAMATION	= 00000030h
MB_ICONASTERISK 	= 00000040h
MB_USERICON 		= 00000080h
MB_ICONWARNING	= MB_ICONEXCLAMATION
MB_ICONERROR		= MB_ICONHAND
MB_ICONINFORMATION	= MB_ICONASTERISK
MB_ICONSTOP		= MB_ICONHAND
MB_DEFBUTTON1 		= 00000000h
MB_DEFBUTTON2 		= 00000100h
MB_DEFBUTTON3 		= 00000200h
MB_DEFBUTTON4 		= 00000300h
MB_APPLMODAL		= 00000000h
MB_SYSTEMMODAL	= 00001000h
MB_TASKMODAL		= 00002000h
MB_HELP 		= 00004000h 	; Help Button
MB_NOFOCUS		= 00008000h
MB_SETFOREGROUND	= 00010000h
MB_DEFAULT_DESKTOP_ONLY 	= 00020000h
MB_TOPMOST		= 00040000h
MB_RIGHT		= 00080000h
MB_RTLREADING 		= 00100000h
MB_SERVICE_NOTIFICATION	= 00200000h
MB_SERVICE_NOTIFICATION_NT3X 	= 00040000h
MB_TYPEMASK 		= 0000000Fh
MB_ICONMASK 		= 000000F0h
MB_DEFMASK		= 00000F00h
MB_MODEMASK 		= 00003000h
MB_MISCMASK 		= 0000C000h

; PeekMessage Options

PM_NOREMOVE 	= 0000h
PM_REMOVE 	= 0001h
PM_NOYIELD	= 0002h

MOD_ALT 	= 0001h
MOD_CONTROL 	= 0002h
MOD_SHIFT 	= 0004h
MOD_WIN 	= 0008h

IDHOT_SNAPWINDOW	= -1	; SHIFT-PRINTSCRN
IDHOT_SNAPDESKTOP	= -2	; PRINTSCRN

EW_RESTARTWINDOWS	= 0042h
EW_REBOOTSYSTEM	= 0043h
EW_EXITANDEXECAPP	= 0044h

ENDSESSION_LOGOFF	= 80000000h

EWX_LOGOFF	= 0
EWX_SHUTDOWN	= 1
EWX_REBOOT	= 2
EWX_FORCE	= 4
EWX_POWEROFF	= 8


;Broadcast Special Message Recipient list

BSM_ALLCOMPONENTS 	= 00000000h
BSM_VXDS		= 00000001h
BSM_NETDRIVER 		= 00000002h
BSM_INSTALLABLEDRIVERS	= 00000004h
BSM_APPLICATIONS	= 00000008h
BSM_ALLDESKTOPS 	= 00000010h

;Broadcast Special Message Flags
BSF_QUERY 		= 00000001h
BSF_IGNORECURRENTTASK 	= 00000002h
BSF_FLUSHDISK 		= 00000004h
BSF_NOHANG		= 00000008h
BSF_POSTMESSAGE 	= 00000010h
BSF_FORCEIFHUNG 	= 00000020h
BSF_NOTIMEOUTIFNOTHUNG	= 00000040h


; Window extra byted needed for private dialog classes.

DLGWINDOWEXTRA	= 30

; Compatibility defines for character translation routines
KEYEVENTF_EXTENDEDKEY 	= 0001h
KEYEVENTF_KEYUP 	= 0002h

MOUSEEVENTF_MOVE	= 0001h	; mouse move ;
MOUSEEVENTF_LEFTDOWN	= 0002h	; left button down ;
MOUSEEVENTF_LEFTUP	= 0004h	; left button up ;
MOUSEEVENTF_RIGHTDOWN 	= 0008h	; right button down ;
MOUSEEVENTF_RIGHTUP 	= 0010h	; right button up ;
MOUSEEVENTF_MIDDLEDOWN	= 0020h	; middle button down ;
MOUSEEVENTF_MIDDLEUP	= 0040h	; middle button up ;
MOUSEEVENTF_WHEEL 	= 0800h	; wheel button rolled ;
MOUSEEVENTF_ABSOLUTE	= 8000h	; absolute move ;

MWMO_WAITALL		= 0001h
MWMO_ALERTABLE	= 0002h

; Queue status flags for GetQueueStatus and MsgWaitForMultipleObjects

QS_KEY		= 0001h
QS_MOUSEMOVE		= 0002h
QS_MOUSEBUTTON	= 0004h
QS_POSTMESSAGE	= 0008h
QS_TIMER		= 0010h
QS_PAINT		= 0020h
QS_SENDMESSAGE	= 0040h
QS_HOTKEY 		= 0080h
QS_ALLPOSTMESSAGE 	= 0100h
QS_MOUSE		= QS_MOUSEMOVE + QS_MOUSEBUTTON
QS_INPUT		= QS_MOUSE + QS_KEY
QS_ALLEVENTS		= QS_INPUT + QS_POSTMESSAGE + QS_TIMER + QS_PAINT + QS_HOTKEY
QS_ALLINPUT		= QS_INPUT + QS_POSTMESSAGE + QS_TIMER + QS_PAINT + QS_HOTKEY+ QS_SENDMESSAGE


; Windows Functions

; WM_SETICON / WM_GETICON Type Codes

ICON_SMALL = 0
ICON_BIG = 1



	


; return codes for WM_MENUCHAR

MNC_IGNORE	= 0
MNC_CLOSE	= 1
MNC_EXECUTE	= 2
MNC_SELECT	= 3

comment #

IFDEF UNICODE
AppendMenu		equ	AppendMenuW
BroadcastSystemMessage	equ	BroadcastSystemMessageW
CallMsgFilter		equ	CallMsgFilterW
ChangeDisplaySettings	equ	ChangeDisplaySettingsW
ChangeDisplaySettingsEx	equ	ChangeDisplaySettingsExW
ChangeMenu		equ	ChangeMenuW
CharLower		equ	CharLowerW
CharLowerBuff		equ	CharLowerBuffW
CharNext		equ	CharNextW
CharPrev		equ	CharPrevW
CharToOem		equ	CharToOemW
CharToOemBuff		equ	CharToOemBuffW
CharUpper		equ	CharUpperW
CharUpperBuff		equ	CharUpperBuffW
CopyAcceleratorTable	equ	CopyAcceleratorTableW
CreateAcceleratorTable	equ	CreateAcceleratorTableW
CreateDesktop		equ	CreateDesktopW
CreateDialogIndirect	equ	CreateDialogIndirectW
CreateDialogIndirectParam	equ	CreateDialogIndirectParamW
CreateEvent		equ	CreateEventW
CreateMDIWindow		equ	CreateMDIWindowW
CreateMutex		equ	CreateMutexW
CreateWindow		equ	CreateWindowW
CreateWindowStation	equ	CreateWindowStationW
DefDlgProc		equ	DefDlgProcW
DefFrameProc		equ	DefFrameProcW
DefMDIChildProc		equ	DefMDIChildProcW
DialogBox		equ	DialogBoxW
DialogBoxIndirect		equ	DialogBoxIndirectW
DialogBoxIndirectParam	equ	DialogBoxIndirectParamW
DialogBoxParam		equ	DialogBoxParamW
DlgDirList		equ	DlgDirListW
DlgDirListComboBox		equ	DlgDirListComboBoxW
DlgDirSelectEx		equ	DlgDirSelectExW
DlgDirSelectComboBoxEx	equ	DlgDirSelectComboBoxExW
DrawState		equ	DrawStateW
DrawText		equ	DrawTextW
DrawTextEx		equ	DrawTextExW
EnumDesktops		equ	EnumDesktopsW
EnumDisplaySettings	equ	EnumDisplaySettingsW
EnumProps		equ	EnumPropsW
EnumPropsEx		equ	EnumPropsExW
EnumWindowStations	equ	EnumWindowStationsW
FindWindow		equ	FindWindowW
FindWindowEx		equ	FindWindowExW
GetClassInfo		equ	GetClassInfoW
GetClassInfoEx		equ	GetClassInfoExW
GetClassLong		equ	GetClassLongW
GetClassName		equ	GetClassNameW
GetClipboardFormatName	equ	GetClipboardFormatNameW
GetKeyboardLayoutName	equ	GetKeyboardLayoutNameW
GetMenuString		equ	GetMenuStringW
GetProp		equ	GetPropW
GetTabbedTextExtent	equ	GetTabbedTextExtentW
GetUserObjectInformation	equ	GetUserObjectInformationW
GetWindowLong		equ	GetWindowLongW
GetWindowText		equ	GetWindowTextW
GetWindowTextLength	equ	GetWindowTextLengthW
GrayString		equ	GrayStringW
InsertMenu		equ	InsertMenuW
InsertMenuItem		equ	InsertMenuItemW
IsCharAlpha		equ	IsCharAlphaW
IsCharAlphaNumeric	equ	IsCharAlphaNumericW
IsCharLower		equ	IsCharLowerW
IsCharUpper		equ	IsCharUpperW
IsDialogMessage		equ	IsDialogMessageW
LoadAccelerators		equ	LoadAcceleratorsW
LoadCursorFromFile		equ	LoadCursorFromFileW
LoadImage		equ	LoadImageW
LoadKeyboardLayout	equ	LoadKeyboardLayoutW
LoadMenuIndirect		equ	LoadMenuIndirectW
MapVirtualKey		equ	MapVirtualKeyW
MapVirtualKeyEx		equ	MapVirtualKeyExW
MessageBoxEx		equ	MessageBoxExW
MessageBoxIndirect	equ	MessageBoxIndirectW
ModifyMenu		equ	ModifyMenuW
OemToChar		equ	OemToCharW
OemToCharBuff		equ	OemToCharBuffW
OpenDesktop		equ	OpenDesktopW
OpenWindowStation	equ	OpenWindowStationW
PostAppMessage		equ	PostAppMessageW
PostMessage		equ	PostMessageW
PostThreadMessage	equ	PostThreadMessageW
RegisterClass		equ	RegisterClassW
RegisterClipboardFormat	equ	RegisterClipboardFormatW
RegisterWindowMessage	equ	RegisterWindowMessageW
RemoveProp		equ	RemovePropW
SendMessageCallback	equ	SendMessageCallbackW
SendMessageTimeout	equ	SendMessageTimeoutW
SendNotifyMessage	equ	SendNotifyMessageW
SetClassLong		equ	SetClassLongW
SetProp		equ	SetPropW
SetUserObjectInformation	equ	SetUserObjectInformationW
SetWindowLong		equ	SetWindowLongW
SetWindowsHook		equ	SetWindowsHookW
SetWindowsHookEx	equ	SetWindowsHookExW
SystemParametersInfo	equ	SystemParametersInfoW
TabbedTextOut		equ	TabbedTextOutW
TranslateAccelerator	equ	TranslateAcceleratorW
UnregisterClass		equ	UnregisterClassW
WinHelp		equ	WinHelpW
ELSE
AppendMenu		equ	AppendMenuA
BroadcastSystemMessage	equ	BroadcastSystemMessageA
CallMsgFilter		equ	CallMsgFilterA
ChangeDisplaySettings	equ	ChangeDisplaySettingsA
ChangeDisplaySettingsEx	equ	ChangeDisplaySettingsExA
ChangeMenu		equ	ChangeMenuA
CharLower		equ	CharLowerA
CharLowerBuff		equ	CharLowerBuffA
CharNext		equ	CharNextA
CharPrev		equ	CharPrevA
CharToOem		equ	CharToOemA
CharToOemBuff		equ	CharToOemBuffA
CharUpper		equ	CharUpperA
CharUpperBuff		equ	CharUpperBuffA
CopyAcceleratorTable	equ	CopyAcceleratorTableA
CreateAcceleratorTable	equ	CreateAcceleratorTableA
CreateDesktop		equ	CreateDesktopA
CreateDialog		equ	CreateDialogA
CreateDialogIndirect	equ	CreateDialogIndirectA
CreateDialogIndirectParam	equ	CreateDialogIndirectParamA
CreateMDIWindow		equ	CreateMDIWindowA
CreateWindow		equ	CreateWindowA
CreateWindowStation	equ	CreateWindowStationA
DefDlgProc		equ	DefDlgProcA
DefFrameProc		equ	DefFrameProcA
DefMDIChildProc		equ	DefMDIChildProcA
DialogBox		equ	DialogBoxA
DialogBoxIndirect		equ	DialogBoxIndirectA
DialogBoxIndirectParam	equ	DialogBoxIndirectParamA
DialogBoxParam		equ	DialogBoxParamA
DlgDirList		equ	DlgDirListA
DlgDirListComboBox		equ	DlgDirListComboBoxA
DlgDirSelectComboBoxEx	equ	DlgDirSelectComboBoxExA
DlgDirSelectEx		equ	DlgDirSelectExA
DrawState		equ	DrawStateA
DrawText		equ	DrawTextA
DrawTextEx		equ	DrawTextExA
EnumDesktops		equ	EnumDesktopsA
EnumDisplaySettings	equ	EnumDisplaySettingsA
EnumProps		equ	EnumPropsA
EnumPropsEx		equ	EnumPropsExA
EnumWindowStations	equ	EnumWindowStationsA
FindWindow		equ	FindWindowA
FindWindowEx		equ	FindWindowExA
GetClassInfo		equ	GetClassInfoA
GetClassInfoEx		equ	GetClassInfoExA
GetClassLong		equ	GetClassLongA
GetClassName		equ	GetClassNameA
GetClipboardFormatName	equ	GetClipboardFormatNameA
GetKeyboardLayoutName	equ	GetKeyboardLayoutNameA
GetMenuString		equ	GetMenuStringA
GetProp		equ	GetPropA
GetTabbedTextExtent	equ	GetTabbedTextExtentA
GetUserObjectInformation	equ	GetUserObjectInformationA
GetWindowLong		equ	GetWindowLongA
GetWindowText		equ	GetWindowTextA
GetWindowTextLength	equ	GetWindowTextLengthA
GrayString		equ	GrayStringA
InsertMenu		equ	InsertMenuA
InsertMenuItem		equ	InsertMenuItemA
IsDialogMessage		equ	IsDialogMessageA
IsCharAlpha		equ	IsCharAlphaA
IsCharAlphaNumeric	equ	IsCharAlphaNumericA
IsCharLower		equ	IsCharLowerA
IsCharUpper		equ	IsCharUpperA
LoadAccelerators		equ	LoadAcceleratorsA
LoadCursorFromFile		equ	LoadCursorFromFileA
LoadImage		equ	LoadImageA
LoadKeyboardLayout	equ	LoadKeyboardLayoutA
LoadMenuIndirect		equ	LoadMenuIndirectA
MapVirtualKey		equ	MapVirtualKeyA
MapVirtualKeyEx		equ	MapVirtualKeyExA
MessageBox		equ	MessageBoxA
MessageBoxEx		equ	MessageBoxExA
MessageBoxIndirect	equ	MessageBoxIndirectA
ModifyMenu		equ	ModifyMenuA
OemToChar		equ	OemToCharA
OemToCharBuff		equ	OemToCharBuffA
OpenDesktop		equ	OpenDesktopA
OpenWindowStation	equ	OpenWindowStationA
PostAppMessage		equ	PostAppMessageA
PostMessage		equ	PostMessageA
PostThreadMessage	equ	PostThreadMessageA
RegisterClass		equ	RegisterClassA
RegisterClipboardFormat	equ	RegisterClipboardFormatA
RegisterWindowMessage	equ	RegisterWindowMessageA
RemoveProp		equ	RemovePropA
SendDlgItemMessage	equ	SendDlgItemMessageA
SendMessage		equ	SendMessageA
SendMessageCallback	equ	SendMessageCallbackA
SendMessageTimeout	equ	SendMessageTimeoutA
SendNotifyMessage	equ	SendNotifyMessageA
SetClassLong		equ	SetClassLongA
SetDlgItemText		equ	SetDlgItemTextA
SetProp		equ	SetPropA
SetUserObjectInformation	equ	SetUserObjectInformationA
SetWindowLong		equ	SetWindowLongA
SetWindowsHook		equ	SetWindowsHookA
SetWindowsHookEx	equ	SetWindowsHookExA
SystemParametersInfo	equ	SystemParametersInfoA
TabbedTextOut		equ	TabbedTextOutA
TranslateAccelerator	equ	TranslateAcceleratorA
UnregisterClass		equ	UnregisterClassA
WinHelp		equ	WinHelpA
ENDIF


 ; HCBT_CREATEWND parameters pointed to by lParam

;CBT_CREATEWND		STRUC
;struct tagCREATESTRUCTA ;lpcs;
;HWND hwndInsertAfter;
;CBT_CREATEWNDA	ENDS

; HCBT_ACTIVATE structure pointed to by lParam

CBTACTIVATESTRUCT	STRUC
 cbt_fMouse	HANDLE	?
 cbt_hWndActive	HWND	?
CBTACTIVATESTRUCT	ENDS

; WH_MSGFILTER Filter Proc Codes

MSGF_DIALOGBOX		= 0
MSGF_MESSAGEBOX	= 1
MSGF_MENU		= 2
MSGF_MOVE		= 3
MSGF_SIZE		= 4
MSGF_SCROLLBAR		= 5
MSGF_NEXTWINDOW	= 6
MSGF_MAINLOOP		= 8
MSGF_MAX		= 8
MSGF_USER		= 4096

; Shell support

HSHELL_WINDOWCREATED	= 1
HSHELL_WINDOWDESTROYED	= 2
HSHELL_ACTIVATESHELLWINDOW	= 3
HSHELL_WINDOWACTIVATED	= 4
HSHELL_GETMINRECT	= 5
HSHELL_REDRAW		= 6
HSHELL_TASKMAN	= 7
HSHELL_LANGUAGE	= 8

; Message Structure used in Journaling

EVENTMSG	STRUC
 ev_message	HANDLE	?
 ev_paramL	HANDLE	?
 ev_paramH	HANDLE	?
 ev_time	dd	?
 ev_hwnd	HWND	?
EVENTMSG	ENDS

; Message structure used by WH_CALLWNDPROC

CWPSTRUCT	STRUC
 cwp_lParam	dd	?
 cwp_wParam	HANDLE	?
 cwp_message	HANDLE	?
 cwp_hwnd	HWND	?
CWPSTRUCT	ENDS

; Message structure used by WH_CALLWNDPROCRET

CWPRETSTRUCT	STRUC
 cwr_lResult	dd	?
 cwr_lParam	dd	?
 cwr_wParam	HANDLE	?
 cwr_message	HANDLE	?
 cwr_hwnd	HWND	?
CWPRETSTRUCT	ENDS

; Structure used by WH_DEBUG

DEBUGHOOKINFO		STRUC
 dhi_idThread		dd	?
 dhi_idThreadInstaller	dd	?
 dhi_lParam		dd	?
 dhi_wParam		HANDLE	?
 dhi_code		HANDLE	?
DEBUGHOOKINFO		ENDS

; Structure used by WH_MOUSE

MOUSEHOOKSTRUCT	STRUC
 mhs_pt		dd	?, ?
 mhs_hwnd		HWND	?
 mhs_wHitTestCode		HANDLE	?
 mhs_dwExtraInfo		dd	?
MOUSEHOOKSTRUCT	ENDS

; Structure used by WH_HARDWARE

HARDWAREHOOKSTRUCT	STRUC
 hhs_hwnd		HWND	?
 hhs_message		HANDLE	?
 hhs_wParam		HANDLE	?
 hhs_lParam		dd	?
HARDWAREHOOKSTRUCT	ENDS

; Keyboard Layout API

HKL_PREV		= 0
HKL_NEXT		=1

KLF_ACTIVATE		= 00000001h
KLF_SUBSTITUTE_OK 	= 00000002h
KLF_UNLOADPREVIOUS	= 00000004h
KLF_REORDER 		= 00000008h
KLF_REPLACELANG 		= 00000010h
KLF_NOTELLSHELL 	= 00000080h

; Size of KeyboardLayoutName number of characters, including nul terminator

KL_NAMELENGTH		= 9

; Desktop-specific access flags

DESKTOP_READOBJECTS 	= 0001h
DESKTOP_CREATEWINDOW	= 0002h
DESKTOP_CREATEMENU	= 0004h
DESKTOP_HOOKCONTROL 	= 0008h
DESKTOP_JOURNALRECORD 	= 0010h
DESKTOP_JOURNALPLAYBACK 	= 0020h
DESKTOP_ENUMERATE 	= 0040h
DESKTOP_WRITEOBJECTS	= 0080h
DESKTOP_SWITCHDESKTOP 	= 0100h

; Desktop-specific control flags

DF_ALLOWOTHERACCOUNTHOOK	= 0001h

; Windowstation-specific access flags

WINSTA_ENUMDESKTOPS 	= 0001h
WINSTA_READATTRIBUTES 	= 0002h
WINSTA_ACCESSCLIPBOARD	= 0004h
WINSTA_CREATEDESKTOP	= 0008h
WINSTA_WRITEATTRIBUTES	= 0010h
WINSTA_ACCESSGLOBALATOMS	= 0020h
WINSTA_EXITWINDOWS	= 0040h
WINSTA_ENUMERATE	= 0100h
WINSTA_READSCREEN 	= 0200h

; Windowstation-specific attribute flags

WSF_VISIBLE 		= 0001h

UOI_FLAGS		= 1
UOI_NAME		= 2
UOI_TYPE		= 3
UOI_USER_SID		=4

USEROBJECTFLAGS	STRUC
 uof_fInherit		dd	?
 uof_fReserved		dd	?
 uof_dwFlags		dd	?
USEROBJECTFLAGS	ENDS


WNDCLASSA	STRUC
 cls_style	HANDLE	?
 cls_lpfnWndProc	dd	?
 cls_cbClsExtra	HANDLE	?
 cls_cbWndExtra	HANDLE	?
 cls_hInstance	HINSTANCE	?
 cls_hIcon	HICON	?
 cls_hCursor	HCURSOR	?
 cls_hbrBackground	HBRUSH	?
 cls_lpszMenuName	dd	?
 cls_lpszClassName	dd	?
WNDCLASSA	ENDS

WNDCLASS	equ	WNDCLASSA



 ; Struct pointed to by WM_GETMINMAXINFO lParam

MINMAXINFO		STRUC
 mmi_ptReserved		HANDLE	?, ?
 mmi_ptMaxSize		HANDLE	?, ?
 mmi_ptMaxPosition		HANDLE	?, ?
 mmi_ptMinTrackSize	HANDLE	?, ?
 mmi_ptMaxTrackSize	HANDLE	?, ?
MINMAXINFO		ENDS


; wParam for WM_POWER window message and DRV_POWER driver notification

PWR_OK		= 1
PWR_FAIL		= -1
PWR_SUSPENDREQUEST	= 1
PWR_SUSPENDRESUME	= 2
PWR_CRITICALRESUME	= 3


; lParam of WM_COPYDATA message points to...

COPYDATASTRUCT		STRUC
 cds_dwData		dd	?
 cds_cbData		dd	?
 cds_lpData		dd	?
COPYDATASTRUCT		ENDS


NFR_ANSI	= 1
NFR_UNICODE	= 2
NF_QUERY	= 3
NF_REQUERY	= 4

WHEEL_DELTA		= 120	; Value for rolling one detent
WHEEL_PAGESCROLL	= UINT_MAX	; Scroll one page


MENULOOP_WINDOW	= 0
MENULOOP_POPUP		= 1


MDINEXTMENU	STRUC
 mnm_hmenuIn	HMENU	?
 mnm_hmenuNext	HMENU	?
 mnm_hwndNext	HWND	?
MDINEXTMENU	ENDS

; wParam for WM_SIZING message;

WMSZ_LEFT		= 1
WMSZ_RIGHT		= 2
WMSZ_TOP		= 3
WMSZ_TOPLEFT		= 4
WMSZ_TOPRIGHT		= 5
WMSZ_BOTTOM		= 6
WMSZ_BOTTOMLEFT	= 7
WMSZ_BOTTOMRIGHT	= 8

; WM_SYNCTASK Commands

ST_BEGINSWP	= 0
ST_ENDSWP	= 1

; WM_NCHITTEST and MOUSEHOOKSTRUCT Mouse Position Codes

HTERROR	= -2
HTTRANSPARENT 	= -1
HTNOWHERE	= 0
HTCLIENT	= 1
HTCAPTION	= 2
HTSYSMENU	= 3
HTGROWBOX	= 4
HTSIZE	= HTGROWBOX
HTMENU	= 5
HTHSCROLL	= 6
HTVSCROLL	= 7
HTMINBUTTON	= 8
HTMAXBUTTON	= 9
HTLEFT	= 10
HTRIGHT	= 11
HTTOP	= 12
HTTOPLEFT	= 13
HTTOPRIGHT	= 14
HTBOTTOM	= 15
HTBOTTOMLEFT	= 16
HTBOTTOMRIGHT	= 17
HTBORDER	= 18
HTREDUCE	= HTMINBUTTON
HTZOOM	= HTMAXBUTTON
HTSIZEFIRST	= HTLEFT
HTSIZELAST	= HTBOTTOMRIGHT
HTOBJECT	= 19
HTCLOSE	= 20
HTHELP	= 21

; SendMessageTimeout values

SMTO_NORMAL 		= 0000h
SMTO_BLOCK		= 0001h
SMTO_ABORTIFHUNG	= 0002h

; WM_MOUSEACTIVATE Return Codes

MA_ACTIVATE		= 1
MA_ACTIVATEANDEAT	= 2
MA_NOACTIVATE		= 3
MA_NOACTIVATEANDEAT	= 4


; WM_SIZE message wParam values

SIZE_RESTORED	= 0
SIZE_MINIMIZED	= 1
SIZE_MAXIMIZED	= 2
SIZE_MAXSHOW	= 3
SIZE_MAXHIDE	= 4

; Obsolete constant names

SIZENORMAL		= SIZE_RESTORED
SIZEICONIC		= SIZE_MINIMIZED
SIZEFULLSCREEN		= SIZE_MAXIMIZED
SIZEZOOMSHOW		= SIZE_MAXSHOW
SIZEZOOMHIDE		= SIZE_MAXHIDE

; WM_WINDOWPOSCHANGING/CHANGED struct pointed to by lParam

WINDOWPOS		STRUC
 wp_hwnd		HWND	?
 wp_hwndInsertAfter	HWND	?
 wp_x		HANDLE	?
 wp_y		HANDLE	?
 wp_cx		HANDLE	?
 wp_cy		HANDLE	?
 wp_flags		HANDLE	?
WINDOWPOS		ENDS

; WM_NCCALCSIZE parameter structure

NCCALCSIZE_PARAMS	STRUC
 nccp_rgrc1		HANDLE	?, ?, ?, ?
 nccp_rgrc2		HANDLE	?, ?, ?, ?
 nccp_rgrc3		HANDLE	?, ?, ?, ?
 nccp_lppos		dd	?
NCCALCSIZE_PARAMS	ENDS

; WM_NCCALCSIZE "window valid rect" return values

WVR_ALIGNTOP		= 0010h
WVR_ALIGNLEFT 		= 0020h
WVR_ALIGNBOTTOM 	= 0040h
WVR_ALIGNRIGHT		= 0080h
WVR_HREDRAW 		= 0100h
WVR_VREDRAW 		= 0200h
WVR_REDRAW		= WVR_HREDRAW + WVR_VREDRAW
WVR_VALIDRECTS		= 0400h

; Key State Masks for Mouse Messages

MK_LBUTTON	= 0001h
MK_RBUTTON	= 0002h
MK_SHIFT	= 0004h
MK_CONTROL	= 0008h
MK_MBUTTON	= 0010h

TME_HOVER 	= 00000001h
TME_LEAVE 	= 00000002h
TME_QUERY 	= 40000000h
TME_CANCEL	= 80000000h

HOVER_DEFAULT 	= -1

TRACKMOUSEEVENT	STRUC
 tme_cbSize		dd	?
 tme_dwFlags		dd	?
 tme_hwndTrack		HWND	?
 tme_dwHoverTime		dd	?
TRACKMOUSEEVENT	ENDS


ACCEL	STRUC
 ac_fVirt	db	?	; Also called the flags field
 ac_key	dw	?
 ac_cmd	dw	?
ACCEL	ENDS

CREATESTRUCTA	STRUC
 cs_lpCreateParams	dd	?
 cs_hInstance	HINSTANCE	?
 cs_hMenu	HMENU	?
 cs_hwndParent	HWND	?
 cs_cy	HANDLE	?
 cs_cx	HANDLE	?
 cs_y	HANDLE	?
 cs_x	HANDLE	?
 cs_style	dd	?
 cs_lpszName	dd	?
 cs_lpszClass	dd	?
 cs_dwExStyle	dd	?
CREATESTRUCTA	ENDS

CREATESTRUC	equ	CREATESTRUCA

STYLESTRUCT		STRUC
 sts_styleOld		dd	?
 sts_styleNew		dd	?
STYLESTRUCT		ENDS

; Owner draw control types
 
ODT_MENU	= 1
ODT_LISTBOX	= 2
ODT_COMBOBOX	= 3
ODT_BUTTON	= 4
ODT_STATIC	= 5

; Owner draw actions

ODA_DRAWENTIRE	= 0001h
ODA_SELECT		= 0002h
ODA_FOCUS 		= 0004h

; Owner draw state

ODS_SELECTED		= 0001h
ODS_GRAYED		= 0002h
ODS_DISABLED		= 0004h
ODS_CHECKED 		= 0008h
ODS_FOCUS 		= 0010h
ODS_DEFAULT 		= 0020h
ODS_COMBOBOXEDIT	= 1000h

; MEASUREITEMSTRUCT for ownerdraw

MEASUREITEMSTRUCT	STRUC
 mis_CtlType	HANDLE	?
 mis_CtlID	HANDLE	?
 mis_itemID	HANDLE	?
 mis_itemWidth	HANDLE	?
 mis_itemHeight	HANDLE	?
 mis_itemData	dd	?
MEASUREITEMSTRUCT	ENDS

; DRAWITEMSTRUCT for ownerdraw
 
DRAWITEMSTRUCT	STRUC
 dis_CtlType	HANDLE	?
 dis_CtlID	HANDLE	?
 dis_itemID	HANDLE	?
 dis_itemAction	HANDLE	?
 dis_itemState	HANDLE	?
 dis_hwndItem	HWND	?
 dis_hDC	HDC	?
 dis_rcItem	HANDLE	?, ?, ?, ?
 dis_itemData	dd	?
DRAWITEMSTRUCT	ENDS

; DELETEITEMSTRUCT for ownerdraw
;
DELETEITEMSTRUCT	STRUC
 dit_CtlType	HANDLE	?
 dit_CtlID	HANDLE	?
 dit_itemID	HANDLE	?
 dit_hwndItem	HWND	?
 dit_itemData	HANDLE	?
DELETEITEMSTRUCT	ENDS

; COMPAREITEMSTUCT for ownerdraw sorting

COMPAREITEMSTRUCT	STRUC
 cis_CtlType	HANDLE	?
 cis_CtlID	HANDLE	?
 cis_hwndItem	HWND	?
 cis_itemID1	HANDLE	?
 cis_itemData1	dd	?
 cis_itemID2	HANDLE	?
 cis_itemData2	dd	?
 cis_dwLocaleId	dd	?
COMPAREITEMSTRUCT	ENDS


BROADCASTSYSMSG	STRUC
 bsm_uiMessage		dd	?
 bsm_wParam		dd	?
 bsm_lParam		dd	?
BROADCASTSYSMSG	ENDS

BROADCAST_QUERY_DENY 	= 424D5144h	; Return this value to deny a query.


; original NT 32 bit dialog template:

DLGTEMPLATE		STRUC
 dtp_style		dd	?
 dtp_dwExtendedStyle	dd	?
 dtp_cdit		dw	?
 dtp_x		dw	?
 dtp_y		dw	?
 dtp_cx		dw	?
 dtp_cy		dw	?
DLGTEMPLATE		ENDS

; 32 bit Dialog item template.

DLGITEMTEMPLATE	STRUC
 dit_style		dd	?
 dit_dwExtendedStyle	dd	?
 dit_x		dw	?
 dit_y		dw	?
 dit_cx		dw	?
 dit_cy		dw	?
 dit_id		dw	?
DLGITEMTEMPLATE	ENDS


TPMPARAMS	STRUC
 tp_cbSize	HANDLE	?
 tp_rcExclude	HANDLE	?, ?, ?, ?	;Screen coordinates of rectangle to exclude when positioning
TPMPARAMS	ENDS


GMDI_USEDISABLED	= 0001h
GMDI_GOINTOPOPUPS 	= 0002h

; Flags for TrackPopupMenu

TPM_LEFTBUTTON		= 0000h
TPM_RIGHTBUTTON 	= 0002h
TPM_LEFTALIGN 		= 0000h
TPM_CENTERALIGN 	= 0004h
TPM_RIGHTALIGN		= 0008h
TPM_TOPALIGN		= 0000h
TPM_VCENTERALIGN	= 0010h
TPM_BOTTOMALIGN 	= 0020h
TPM_HORIZONTAL	= 0000h	; Horz alignment matters more
TPM_VERTICAL		= 0040h	; Vert alignment matters more
TPM_NONOTIFY		= 0080h	; Don't send any notification msgs
TPM_RETURNCMD 		= 0100h

; Drag-and-drop support

DROPSTRUCT	STRUC
 ds_hwndSource	HWND	?
 ds_hwndSink	HWND	?
 ds_wFmt	dd	?
 ds_dwData	dd	?
 ds_ptDrop	POINT	<?>
 ds_dwControlData	dd	?
DROPSTRUCT	ENDS

DOF_EXECUTABLE	= 8001h
DOF_DOCUMENT	= 8002h
DOF_DIRECTORY 	= 8003h
DOF_MULTIPLE	= 8004h
DOF_PROGMAN 	= 0001h
DOF_SHELLDATA 	= 0002h

DO_DROPFILE 	= 454C4946h
DO_PRINTFILE	= 544E5250h

; DrawText Format Flags

DT_TOP		= 00000000h
DT_LEFT 		= 00000000h
DT_CENTER 		= 00000001h
DT_RIGHT		= 00000002h
DT_VCENTER		= 00000004h
DT_BOTTOM 		= 00000008h
DT_WORDBREAK		= 00000010h
DT_SINGLELINE 		= 00000020h
DT_EXPANDTABS 		= 00000040h
DT_TABSTOP		= 00000080h
DT_NOCLIP 		= 00000100h
DT_EXTERNALLEADING	= 00000200h
DT_CALCRECT 		= 00000400h
DT_NOPREFIX 		= 00000800h
DT_INTERNAL 		= 00001000h
DT_EDITCONTROL		= 00002000h
DT_PATH_ELLIPSIS	= 00004000h
DT_END_ELLIPSIS 	= 00008000h
DT_MODIFYSTRING 	= 00010000h
DT_RTLREADING 		= 00020000h
DT_WORD_ELLIPSIS	= 00040000h

DRAWTEXTPARAMS	STRUC
 dtp_cbSize	HANDLE	?
 dtp_iTabLength	HANDLE	?
 dtp_iLeftMargin	HANDLE	?
 dtp_iRightMargin	HANDLE	?
 dtp_uiLengthDrawn	HANDLE	?
DRAWTEXTPARAMS	ENDS

; Monolithic state-drawing routineImage type

DST_COMPLEX 	= 0000h
DST_TEXT	= 0001h
DST_PREFIXTEXT	= 0002h
DST_ICON	= 0003h
DST_BITMAP	= 0004h

; State type

DSS_NORMAL	= 0000h
DSS_UNION 	= 0010h	; Gray string appearance
DSS_DISABLED	= 0020h
DSS_MONO	= 0080h
DSS_RIGHT 	= 8000h

; GetDCEx flags

DCX_WINDOW 		= 00000001h
DCX_CACHE		= 00000002h
DCX_NORESETATTRS 	= 00000004h
DCX_CLIPCHILDREN 	= 00000008h
DCX_CLIPSIBLINGS 	= 00000010h
DCX_PARENTCLIP 		= 00000020h
DCX_EXCLUDERGN 		= 00000040h
DCX_INTERSECTRGN 	= 00000080h
DCX_EXCLUDEUPDATE	= 00000100h
DCX_INTERSECTUPDATE	= 00000200h
DCX_LOCKWINDOWUPDATE 	= 00000400h
DCX_VALIDATE 		= 00200000h

; RedrawWindow flags

RDW_INVALIDATE		= 0001h
RDW_INTERNALPAINT 	= 0002h
RDW_ERASE 		= 0004h
RDW_VALIDATE		= 0008h
RDW_NOINTERNALPAINT 	= 0010h
RDW_NOERASE 		= 0020h
RDW_NOCHILDREN	= 0040h
RDW_ALLCHILDREN 	= 0080h
RDW_UPDATENOW 	= 0100h
RDW_ERASENOW		= 0200h
RDW_FRAME 		= 0400h
RDW_NOFRAME 		= 0800h

SW_SCROLLCHILDREN 	= 0001h	; Scroll children within lprcScroll
SW_INVALIDATE 		= 0002h	; Invalidate after scrolling
SW_ERASE		= 0004h	; If SW_INVALIDATE, don't send WM_ERASEBACKGROUND

; EnableScrollBar flags

ESB_ENABLE_BOTH 	= 0000h
ESB_DISABLE_BOTH	= 0003h
ESB_DISABLE_LEFT	= 0001h
ESB_DISABLE_RIGHT 	= 0002h
ESB_DISABLE_UP		= 0001h
ESB_DISABLE_DOWN	= 0002h
ESB_DISABLE_LTUP	= ESB_DISABLE_LEFT
ESB_DISABLE_RTDN	= ESB_DISABLE_RIGHT

HELPINFO_WINDOW	= 0001h
HELPINFO_MENUITEM	= 0002h

HELPINFO	STRUC
 hi_cbSize	dd	?	; Size in bytes of this struct
 hi_iContextType	dd	?	; Either HELPINFO_WINDOW or HELPINFO_MENUITEM
 hi_iCtrlId	dd	?	; Control Id or a Menu item Id.
 hi_hItemHandle	HANDLE	?	; hWnd of control or hMenu.
 hi_dwContextId	dd	?	; Context Id associated with this item
 hi_MousePos	POINT	<?>	; Mouse Position in screen co-ordinates
HELPINFO	ENDS


MSGBOXPARAMSA		STRUC
 mbp_cbSize		dd	?
 mbp_hwndOwner		HWND	?
 mbp_hInstance		HINSTANCE	?
 mbp_lpszText		dd	?
 mbp_lpszCaption		dd	?
 mbp_dwStyle		dd	?
 mbp_lpszIcon		dd	?
 mbp_dwContextHelpId	dd	?
 mbp_lpfnMsgBoxCallback	dd	?
 mbp_dwLanguageId		dd	?
MSGBOXPARAMSA		ENDS

MSGBOXPARAMS		equ	MSGBOXPARAMSA


; Menu item resource format

MENUITEMTEMPLATEHEADER	STRUC
 mith_versionNumber	dw	?
 mith_offset		dw	?
MENUITEMTEMPLATEHEADER	ENDS

MENUITEMTEMPLATE	STRUC
 mit_mtOption		dw	?
 mit_mtID		dw	?
 mit_mtString		dw	?
MENUITEMTEMPLATE	ENDS

MF_END 	= 00000080h

; System Menu Command Values

SC_SIZE 		= 0F000h
SC_MOVE 		= 0F010h
SC_MINIMIZE 		= 0F020h
SC_MAXIMIZE 		= 0F030h
SC_NEXTWINDOW 	= 0F040h
SC_PREVWINDOW 		= 0F050h
SC_CLOSE		= 0F060h
SC_VSCROLL		= 0F070h
SC_HSCROLL		= 0F080h
SC_MOUSEMENU		= 0F090h
SC_KEYMENU		= 0F100h
SC_ARRANGE		= 0F110h
SC_RESTORE		= 0F120h
SC_TASKLIST 		= 0F130h
SC_SCREENSAVE 		= 0F140h
SC_HOTKEY 		= 0F150h
SC_DEFAULT		= 0F160h
SC_MONITORPOWER 	= 0F170h
SC_CONTEXTHELP		= 0F180h
SC_SEPARATOR		= 0F00Fh

; Obsolete names

SC_ICON		= SC_MINIMIZE
SC_ZOOM		= SC_MAXIMIZE



ICONINFO	STRUC
 ii_fIcon	dd	?
 ii_xHotspot	dd	?
 ii_yHotspot	dd	?
 ii_hbmMask	HBITMAP	?
 ii_hbmColor	HBITMAP	?
ICONINFO	ENDS

; Icon/Cursor header

CURSORSHAPE	STRUC
 csh_xHotSpot	dd	?
 csh_yHotSpot	dd	?
 csh_cx	dd	?
 csh_cy	dd	?
 csh_cbWidth	dd	?
 csh_Planes	db	?
 csh_BitsPixel	db	?
CURSORSHAPE	ENDS

SCROLLINFO	STRUC
 sif_cbSize	dd	?
 sif_fMask	dd	?
 sif_nMin	dd	?
 sif_nMax	dd	?
 sif_nPage	dd	?
 sif_nPos	dd	?
 sif_nTrackPos	dd	?
SCROLLINFO	ENDS

; MDI client style bits

MDIS_ALLCHILDSTYLES	= 0001

; wParam Flags for WM_MDITILE and WM_MDICASCADE messages.

MDITILE_VERTICAL 	= 0000 	;not in win3.1
MDITILE_HORIZONTAL 	= 0001 	;not in win3.1
MDITILE_SKIPDISABLED 	= 0002	;not in win3.1

MDICREATESTRUCTA	STRUC
 mcs_szClass	dd	?
 mcs_szTitle	dd	?
 mcs_hOwner	HANDLE	?
 mcs_x	HANDLE	?
 mcs_y	HANDLE	?
 mcs_cx	HANDLE	?
 mcs_cy	HANDLE	?
 mcs_style	dd	?
 mcs_lParam	dd	?	; app-defined stuff
MDICREATESTRUCTA	ENDS

MDICREATESTRUCT	equ	MDICREATESTRUCTA

CLIENTCREATESTRUCT	STRUC
 ccs_hWindowMenu		HANDLE	?
 ccs_idFirstChild		HANDLE	?
CLIENTCREATESTRUCT	ENDS

MULTIKEYHELPA	STRUC
 mkh_mkSize	dd	?
 mkh_mkKeylist	db	?
 mkh_szKeyphrase	db	?
MULTIKEYHELPA	ENDS

HELPWININFOA	STRUC
 hwi_wStructSize	HANDLE	?
 hwi_x	HANDLE	?
 hwi_y	HANDLE	?
 hwi_dx	HANDLE	?
 hwi_dy	HANDLE	?
 hwi_wMax	HANDLE	?
 hwi_rgchMember	dw	?
HELPWININFOA	ENDS

HELPWININFO	equ	HELPWININFOA

; Commands to pass to WinHelp

HELP_CONTEXT		= 0001h;	 Display topic in ulTopic
HELP_QUIT 		= 0002h	; Terminate help
HELP_INDEX		= 0003h	; Display index
HELP_CONTENTS 		= 0003h
HELP_HELPONHELP 	= 0004h	; Display help on using help
HELP_SETINDEX 		= 0005h	; Set current Index for multi index help
HELP_SETCONTENTS	= 0005h
HELP_CONTEXTPOPUP 	= 0008h
HELP_FORCEFILE		= 0009h
HELP_KEY		= 0101h	; Display topic for keyword in offabData
HELP_COMMAND		= 0102h
HELP_PARTIALKEY 		= 0105h
HELP_MULTIKEY 		= 0201h
HELP_SETWINPOS		= 0203h
HELP_CONTEXTMENU	= 000ah
HELP_FINDER 		= 000bh
HELP_WM_HELP		= 000ch
HELP_SETPOPUP_POS 	= 000dh
HELP_TCARD		= 8000h
HELP_TCARD_DATA 	= 0010h
HELP_TCARD_OTHER_CALLER 	= 0011h

; These are in winhelp.h in Win95.
IDH_NO_HELP		= 28440
IDH_MISSING_CONTEXT	= 28441	; Control doesn't have matching help context
IDH_GENERIC_HELP_BUTTON	= 28442	; Property sheet help button
IDH_OK		= 28443
IDH_CANCEL		= 28444
IDH_HELP		= 28445

; Parameter for SystemParametersInfo

SPI_GETBEEP		= 1
SPI_SETBEEP		= 2
SPI_GETMOUSE		= 3
SPI_SETMOUSE		= 4
SPI_GETBORDER		= 5
SPI_SETBORDER		= 6
SPI_GETKEYBOARDSPEED	= 10
SPI_SETKEYBOARDSPEED	= 11
SPI_LANGDRIVER		= 12
SPI_ICONHORIZONTALSPACING	= 13
SPI_GETSCREENSAVETIMEOUT	= 14
SPI_SETSCREENSAVETIMEOUT	= 15
SPI_GETSCREENSAVEACTIVE	= 16
SPI_SETSCREENSAVEACTIVE	= 17
SPI_GETGRIDGRANULARITY	= 18
SPI_SETGRIDGRANULARITY	= 19
SPI_SETDESKWALLPAPER	= 20
SPI_SETDESKPATTERN	= 21
SPI_GETKEYBOARDDELAY	= 22
SPI_SETKEYBOARDDELAY	= 23
SPI_ICONVERTICALSPACING	= 24
SPI_GETICONTITLEWRAP	= 25
SPI_SETICONTITLEWRAP	= 26
SPI_GETMENUDROPALIGNMENT	= 27
SPI_SETMENUDROPALIGNMENT	= 28
SPI_SETDOUBLECLKWIDTH	= 29
SPI_SETDOUBLECLKHEIGHT	= 30
SPI_GETICONTITLELOGFONT	= 31
SPI_SETDOUBLECLICKTIME	= 32
SPI_SETMOUSEBUTTONSWAP	= 33
SPI_SETICONTITLELOGFONT	= 34
SPI_GETFASTTASKSWITCH	= 35
SPI_SETFASTTASKSWITCH	= 36
SPI_SETDRAGFULLWINDOWS	= 37
SPI_GETDRAGFULLWINDOWS	= 38
SPI_GETNONCLIENTMETRICS	= 41
SPI_SETNONCLIENTMETRICS	= 42
SPI_GETMINIMIZEDMETRICS	= 43
SPI_SETMINIMIZEDMETRICS	= 44
SPI_GETICONMETRICS 	= 45
SPI_SETICONMETRICS 	= 46
SPI_SETWORKAREA	= 47
SPI_GETWORKAREA	= 48
SPI_SETPENWINDOWS	= 49
SPI_GETHIGHCONTRAST	= 66
SPI_SETHIGHCONTRAST	= 67
SPI_GETKEYBOARDPREF	= 68
SPI_SETKEYBOARDPREF	= 69
SPI_GETSCREENREADER	= 70
SPI_SETSCREENREADER	= 71
SPI_GETANIMATION 	= 72
SPI_SETANIMATION 	= 73
SPI_GETFONTSMOOTHING 	= 74
SPI_SETFONTSMOOTHING 	= 75
SPI_SETDRAGWIDTH 	= 76
SPI_SETDRAGHEIGHT	= 77
SPI_SETHANDHELD	= 78
SPI_GETLOWPOWERTIMEOUT 	= 79
SPI_GETPOWEROFFTIMEOUT 	= 80
SPI_SETLOWPOWERTIMEOUT 	= 81
SPI_SETPOWEROFFTIMEOUT 	= 82
SPI_GETLOWPOWERACTIVE	= 83
SPI_GETPOWEROFFACTIVE	= 84
SPI_SETLOWPOWERACTIVE	= 85
SPI_SETPOWEROFFACTIVE	= 86
SPI_SETCURSORS 		= 87
SPI_SETICONS 		= 88
SPI_GETDEFAULTINPUTLANG	= 89
SPI_SETDEFAULTINPUTLANG	= 90
SPI_SETLANGTOGGLE	= 91
SPI_GETWINDOWSEXTENSION	= 92
SPI_SETMOUSETRAILS 	= 93
SPI_GETMOUSETRAILS 	= 94
SPI_SCREENSAVERRUNNING 	= 97
SPI_GETFILTERKEYS	= 50
SPI_SETFILTERKEYS	= 51
SPI_GETTOGGLEKEYS	= 52
SPI_SETTOGGLEKEYS	= 53
SPI_GETMOUSEKEYS 	= 54
SPI_SETMOUSEKEYS 	= 55
SPI_GETSHOWSOUNDS	= 56
SPI_SETSHOWSOUNDS	= 57
SPI_GETSTICKYKEYS	= 58
SPI_SETSTICKYKEYS	= 59
SPI_GETACCESSTIMEOUT 	= 60
SPI_SETACCESSTIMEOUT 	= 61
SPI_GETSERIALKEYS	= 62
SPI_SETSERIALKEYS	= 63
SPI_GETSOUNDSENTRY 	= 64
SPI_SETSOUNDSENTRY 	= 65
SPI_GETSNAPTODEFBUTTON 	= 95
SPI_SETSNAPTODEFBUTTON 	= 96
SPI_GETMOUSEHOVERWIDTH 	= 98
SPI_SETMOUSEHOVERWIDTH 	= 99
SPI_GETMOUSEHOVERHEIGHT	= 100
SPI_SETMOUSEHOVERHEIGHT	= 101
SPI_GETMOUSEHOVERTIME	= 102
SPI_SETMOUSEHOVERTIME	= 103
SPI_GETWHEELSCROLLLINES	= 104
SPI_SETWHEELSCROLLLINES	= 105

; Flags

SPIF_UPDATEINIFILE	= 0001h
SPIF_SENDWININICHANGE 	= 0002h
SPIF_SENDCHANGE	= SPIF_SENDWININICHANGE

METRICS_USEDEFAULT	= -1

NONCLIENTMETRICSA	STRUC
 ncm_cbSize		dd	?
 ncm_iBorderWidth		dd	?
 ncm_iScrollWidth		dd	?
 ncm_iScrollHeight		dd	?
 ncm_iCaptionWidth	dd	?
 ncm_iCaptionHeight	dd	?
 ncm_lfCaptionFont	LOGFONTA	<?>
 ncm_iSmCaptionWidth	dd	?
 ncm_iSmCaptionHeight	dd	?
 ncm_lfSmCaptionFont	LOGFONTA	<?>
 ncm_iMenuWidth		dd	?
 ncm_iMenuHeight		dd	?
 ncm_lfMenuFont		LOGFONTA	<?>
 ncm_lfStatusFont		LOGFONTA	<?>
 ncm_lfMessageFont	LOGFONTA	<?>
NONCLIENTMETRICSA	ENDS

NONCLIENTMETRICS	equ	NONCLIENTMETRICSA


ARW_BOTTOMLEFT	= 0000h
ARW_BOTTOMRIGHT 	= 0001h
ARW_TOPLEFT 		= 0002h
ARW_TOPRIGHT		= 0003h
ARW_STARTMASK 		= 0003h
ARW_STARTRIGHT		= 0001h
ARW_STARTTOP		= 0002h
ARW_LEFT		= 0000h
ARW_RIGHT 		= 0000h
ARW_UP		= 0004h
ARW_DOWN		= 0004h
ARW_HIDE		= 0008h
ARW_VALID 		= 000Fh

MINIMIZEDMETRICS	STRUC
 mmm_cbSize	dd	?
 mmm_iWidth	dd	?
 mmm_iHorzGap	dd	?
 mmm_iVertGap	dd	?
 mmm_iArrange	dd	?
MINIMIZEDMETRICS	ENDS


ICONMETRICSA		STRUC
 icm_cbSize	dd	?
 icm_iHorzSpacing	dd	?
 icm_iVertSpacing	dd	?
 icm_iTitleWrap	dd	?
 icm_lfFont	LOGFONT	<?>
ICONMETRICSA		ENDS

ICONMETRICS	equ	ICONMETRICSA


ANIMATIONINFO		STRUC
 ani_cbSize	dd	?
 ani_iMinAnimate	dd	?
ANIMATIONINFO		ENDS

SERIALKEYSA		STRUC
 sks_cbSize	dd	?
 sks_dwFlags	dd	?
 sks_lpszActivePort	dd	?
 sks_lpszPort	dd	?
 sks_iBaudRate	dd	?
 sks_iPortState	dd	?
 sks_iActive	dd	?
SERIALKEYSA		ENDS

SERIALKEYS	equ	SERIALKEYSA

; flags for SERIALKEYS dwFlags field

SERKF_SERIALKEYSON	= 00000001h
SERKF_AVAILABLE 	= 00000002h
SERKF_INDICATOR 	= 00000004h

HIGHCONTRASTA		STRUC
 hct_cbSize		dd	?
 hct_dwFlags		dd	?
 hct_lpszDefaultScheme	dd	?
HIGHCONTRASTA		ENDS

HIGHCONTRAST		equ	HIGHCONTRASTA

; flags for HIGHCONTRAST dwFlags field

HCF_HIGHCONTRASTON	= 00000001h
HCF_AVAILABLE 		= 00000002h
HCF_HOTKEYACTIVE	= 00000004h
HCF_CONFIRMHOTKEY 	= 00000008h
HCF_HOTKEYSOUND 	= 00000010h
HCF_INDICATOR 		= 00000020h
HCF_HOTKEYAVAILABLE 	= 00000040h

; Flags for ChangeDisplaySettings

CDS_UPDATEREGISTRY	= 00000001h
CDS_TEST		= 00000002h
CDS_FULLSCREEN		= 00000004h
CDS_GLOBAL		= 00000008h
CDS_SET_PRIMARY 	= 00000010h
CDS_RESET 		= 40000000h
CDS_SETRECT 		= 20000000h
CDS_NORESET 		= 10000000h

; Return values for ChangeDisplaySettings

DISP_CHANGE_SUCCESSFUL	= 0
DISP_CHANGE_RESTART	= 1
DISP_CHANGE_FAILED	= -1
DISP_CHANGE_BADMODE	= -2
DISP_CHANGE_NOTUPDATED	= -3
DISP_CHANGE_BADFLAGS	= -4
DISP_CHANGE_BADPARAM	= -5

ENUM_CURRENT_SETTINGS 	= -1
ENUM_REGISTRY_SETTINGS	= -2

; Accessibility support

FILTERKEYS	STRUC
 fik_cbSize	dd	?
 fik_dwFlags	dd	?
 fik_iWaitMSec	dd	?	; Acceptance Delay
 fik_iDelayMSec	dd	?	; Delay Until Repeat
 fik_iRepeatMSec	dd	?	; Repeat Rate
 fik_iBounceMSec	dd	?	; Debounce Time
FILTERKEYS	ENDS

; FILTERKEYS dwFlags field

FKF_FILTERKEYSON	= 00000001h
FKF_AVAILABLE 		= 00000002h
FKF_HOTKEYACTIVE	= 00000004h
FKF_CONFIRMHOTKEY 	= 00000008h
FKF_HOTKEYSOUND 	= 00000010h
FKF_INDICATOR 		= 00000020h
FKF_CLICKON 		= 00000040h

STICKYKEYS	STRUC
 stk_cbSize	dd	?
 stk_dwFlags	dd	?
STICKYKEYS	ENDS

; STICKYKEYS dwFlags field

SKF_STICKYKEYSON	= 00000001h
SKF_AVAILABLE 		= 00000002h
SKF_HOTKEYACTIVE	= 00000004h
SKF_CONFIRMHOTKEY 	= 00000008h
SKF_HOTKEYSOUND 	= 00000010h
SKF_INDICATOR 		= 00000020h
SKF_AUDIBLEFEEDBACK 	= 00000040h
SKF_TRISTATE		= 00000080h
SKF_TWOKEYSOFF		= 00000100h

MOUSEKEYS		STRUC
 mks_cbSize		dd	?
 mks_dwFlags		dd	?
 mks_iMaxSpeed		dd	?
 mks_iTimeToMaxSpeed	dd	?
 mks_iCtrlSpeed		dd	?
 mks_dwReserved1		dd	?
 mks_dwReserved2		dd	?
MOUSEKEYS		ENDS

; MOUSEKEYS dwFlags field

MKF_MOUSEKEYSON 	= 00000001h
MKF_AVAILABLE 		= 00000002h
MKF_HOTKEYACTIVE	= 00000004h
MKF_CONFIRMHOTKEY 	= 00000008h
MKF_HOTKEYSOUND 	= 00000010h
MKF_INDICATOR 		= 00000020h
MKF_MODIFIERS 		= 00000040h
MKF_REPLACENUMBERS	= 00000080h

ACCESSTIMEOUT	STRUC
 ato_cbSize	dd	?
 ato_dwFlags	dd	?
 ato_iTimeOutMSec	dd	?
ACCESSTIMEOUT	ENDS

; ACCESSTIMEOUT dwFlags field

ATF_TIMEOUTON 		= 00000001h
ATF_ONOFFFEEDBACK 	= 00000002h

; values for SOUNDSENTRY iFSGrafEffect field

SSGF_NONE	= 0
SSGF_DISPLAY	= 3

; values for SOUNDSENTRY iFSTextEffect field

SSTF_NONE	= 0
SSTF_CHARS	= 1
SSTF_BORDER	= 2
SSTF_DISPLAY	= 3

; values for SOUNDSENTRY iWindowsEffect field
SSWF_NONE	= 0
SSWF_TITLE	= 1
SSWF_WINDOW	= 2
SSWF_DISPLAY	= 3
SSWF_CUSTOM	= 4

SOUNDSENTRYA		STRUC
 sse_cbSize		dd	?
 sse_dwFlags		dd	?
 sse_iFSTextEffect		dd	?
 sse_iFSTextEffectMSec	dd	?
 sse_iFSTextEffectColorBits	dd	?
 sse_iFSGrafEffect		dd	?
 sse_iFSGrafEffectMSec	dd	?
 sse_iFSGrafEffectColor	dd	?
 sse_iWindowsEffect	dd	?
 sse_iWindowsEffectMSec	dd	?
 sse_lpszWindowsEffectDLL	dd	?
 sse_iWindowsEffectOrdinal	dd	?
SOUNDSENTRYA		ENDS

SOUNDSENTRY	equ	SOUNDSENTRYA

; SOUNDSENTRY dwFlags field

SSF_SOUNDSENTRYON 	= 00000001h
SSF_AVAILABLE 		= 00000002h
SSF_INDICATOR 		= 00000004h

TOGGLEKEYS	STRUC
 tks_cbSize	dd	?
 tks_dwFlags	dd	?
TOGGLEKEYS	ENDS

; TOGGLEKEYS dwFlags field

TKF_TOGGLEKEYSON	= 00000001h
TKF_AVAILABLE 		= 00000002h
TKF_HOTKEYACTIVE	= 00000004h
TKF_CONFIRMHOTKEY 	= 00000008h
TKF_HOTKEYSOUND 	= 00000010h
TKF_INDICATOR 		= 00000020h

; SetLastErrorEx types.

SLE_ERROR 	= 00000001h
SLE_MINORERROR	= 00000002h
SLE_WARNING 	= 00000003h

GA_PARENT		equ	1
GA_ROOT		equ	2
GA_ROOTOWNER		equ	3
-#
