test: inc/user.h File Reference

Main Page | Class Hierarchy | Class List | File List | Class Members | File Members

# user.h File Reference

`#include "w32wow64.h"`

Go to the source code of this file.

## Classes

struct | tagMBSTRING
struct | tagSIZERECT
struct | _CAPTUREBUF
struct | _CALLBACKSTATUS
struct | _LARGE_STRING
struct | _LARGE_ANSI_STRING
struct | _LARGE_UNICODE_STRING
struct | _CTLCOLOR
struct | _DRAWICONEXDATA
struct | _CALLBACKWND
struct | _CLIENTINFO
struct | _PROPSET
struct | tagEVENT_PACKET
struct | POINT5
struct | BROADCASTSYSTEMMSGPARAMS
struct | _PFNCLIENT
struct | _PFNCLIENTWORKER
struct | tagOEMBITMAPINFO
struct | tagPERUSERSERVERINFO
struct | tagSERVERINFO
struct | _WNDMSG
struct | tagSHAREDINFO
struct | _USERCONNECT
struct | tagGETCLIPBDATA
struct | tagSETCLIPBDATA
struct | tagHANDLETYPEINFO
struct | _HEAD
struct | _THROBJHEAD
struct | _PROCOBJHEAD
struct | _PROCMARKHEAD
struct | _DESKHEAD
struct | _DESKOBJHEAD
struct | _THRDESKHEAD
struct | _PROCDESKHEAD
struct | _HANDLEENTRY
struct | _CALLPROCDATA
struct | tagCOMMON_WNDCLASS
struct | tagCLSMENUNAME
struct | tagCLS
struct | tagSBDATA
struct | tagSBINFO
struct | tagPROP
struct | tagPROPLIST
struct | tagWND
struct | tagCBox
struct | tagCOMBOWND
struct | _SCROLLPOS
struct | tagLBIV
struct | tagLBWND
struct | tagIMC
struct | tagHOOK
struct | tagNAMELIST
struct | tagMONITOR
struct | tagDISPLAYINFO
struct | VWPL
struct | tagDESKTOPINFO
struct | tagCURSOR_ACON
struct | CURSOR_COMMON
struct | ACON_COMMON
struct | tagCURSOR
struct | tagACON
struct | tagCURSORDATA
struct | tagCURSORFIND
struct | tagITEM
struct | tagMENULIST
struct | tagMENU
struct | tagDLGENUMDATA
struct | tagSBCALC
struct | tagSBTRACK
struct | _DLG
struct | _DIALOG
struct | tagMDI
struct | tagMDIWND
struct | tagCLIENTTHREADINFO
struct | tagCARET
struct | tagSBWND
struct | tagSNDMSGTIMEOUT
struct | tagBUTN
struct | tagBUTNWND
struct | tagIMEUI
struct | tagIMEWND
struct | _MSGBOXDATA
struct | DRAWTEXTDATA
struct | tagLPKEDITCALLOUT
struct | _DOCONNECTDATA
struct | _DORECONNECTDATA
struct | tagMSG_TABLE_ENTRY
struct | tagMNDRAGOVERINFO
struct | tagINTERNALSETHIGHCONTRAST

## Defines

#define | FASTCALL
#define | UTCHAR UCHAR
#define | ICON_PROP_NAME L"SysIC"
#define | DbgPrint UserDbgPrint
#define | LOSHORT(l) ((short)LOWORD(l))
#define | HISHORT(l) ((short)HIWORD(l))
#define | GET_X_LPARAM(lp) ((int)(short)LOWORD(lp))
#define | GET_Y_LPARAM(lp) ((int)(short)HIWORD(lp))
#define | GetClientInfo() ((PCLIENTINFO)((NtCurrentTebShared())->Win32ClientInfo))
#define | HEVENT_REMOVEME ((HANDLE)IntToPtr( 0xFFFFFFFF ))
#define | SYSMET(i) ((int)gpsi->aiSysMet[SM_##i])
#define | SYSMETRTL(i) ((int)gpsi->aiSysMet[SM_##i])
#define | SYSRGB(i) gpsi->argbSystem[COLOR_##i]
#define | SYSRGBRTL(i) gpsi->argbSystem[COLOR_##i]
#define | SYSHBR(i) gpsi->ahbrSystem[COLOR_##i]
#define | SYSHBRUSH(i) gpsi->ahbrSystem[i]
#define | DESTINATION (DWORD)0x00AA0000
#define | SOURCE (DWORD)0x00CC0000
#define | PATTERN (DWORD)0x00F00000
#define | BI_CHECKBOX 0
#define | BI_RADIOBUTTON 1
#define | BI_3STATE 2
#define | NUM_BUTTON_TYPES 3
#define | NUM_BUTTON_STATES 4
#define | MAX_MB_STRINGS 11
#define | CopyRect CopyRectInl
#define | EqualRect EqualRectInl
#define | SetRectEmpty SetRectEmptyInl
#define | TEXT_FN(fn) fn##A
#define | BYTESTOCHARS(cb) (cb)
#define | CHARSTOBYTES(cch) (cch)
#define | DESKTOPCLASS MAKEINTATOM(0x8001)
#define | DIALOGCLASS MAKEINTATOM(0x8002)
#define | SWITCHWNDCLASS MAKEINTATOM(0x8003)
#define | ICONTITLECLASS MAKEINTATOM(0x8004)
#define | INFOCLASS MAKEINTATOM(0x8005)
#define | TOOLTIPCLASS MAKEINTATOM(0x8006)
#define | GHOSTCLASS MAKEINTATOM(0x8007)
#define | MENUCLASS MAKEINTATOM(0x8000) /* Public Knowledge */
#define | IDSYS_LAYER 0x0000FFF5L
#define | IDSYS_FADE 0x0000FFF6L
#define | IDSYS_WNDTRACKING 0x0000FFF7L
#define | IDSYS_FLASHWND 0x0000FFF8L
#define | IDSYS_MNAUTODISMISS 0x0000FFF9L
#define | IDSYS_MOUSEHOVER 0x0000FFFAL
#define | IDSYS_MNANIMATE 0x0000FFFBL
#define | IDSYS_MNDOWN MFMWFP_DOWNARROW /* 0xFFFFFFFC */
#define | IDSYS_LBSEARCH 0x0000FFFCL
#define | IDSYS_MNUP MFMWFP_UPARROW /* 0xFFFFFFFD */
#define | IDSYS_STANIMATE 0x0000FFFDL
#define | IDSYS_MNSHOW 0x0000FFFEL
#define | IDSYS_SCROLL 0x0000FFFEL
#define | IDSYS_MNHIDE 0x0000FFFFL
#define | IDSYS_CARET 0x0000FFFFL
#define | CODEBIT 0x80
#define | BUTTONCODE 0x80
#define | EDITCODE 0x81
#define | STATICCODE 0x82
#define | LISTBOXCODE 0x83
#define | SCROLLBARCODE 0x84
#define | COMBOBOXCODE 0x85
#define | MDICLIENTCODE 0x86
#define | COMBOLISTBOXCODE 0x87
#define | ICLS_BUTTON 0
#define | ICLS_EDIT 1
#define | ICLS_STATIC 2
#define | ICLS_LISTBOX 3
#define | ICLS_SCROLLBAR 4
#define | ICLS_COMBOBOX 5
#define | ICLS_MDICLIENT 6
#define | ICLS_COMBOLISTBOX 7
#define | ICLS_DDEMLEVENT 8
#define | ICLS_DDEMLMOTHER 9
#define | ICLS_DDEML16BIT 10
#define | ICLS_DDEMLCLIENTA 11
#define | ICLS_DDEMLCLIENTW 12
#define | ICLS_DDEMLSERVERA 13
#define | ICLS_DDEMLSERVERW 14
#define | ICLS_IME 15
#define | ICLS_CTL_MAX 16
#define | ICLS_DESKTOP 16
#define | ICLS_DIALOG 17
#define | ICLS_MENU 18
#define | ICLS_SWITCH 19
#define | ICLS_ICONTITLE 20
#define | ICLS_TOOLTIP 21
#define | ICLS_MAX 22
#define | WINSTA_DIR L"\\Windows\\WindowStations"
#define | WINSTA_SESSION_DIR L"\\Sessions\\xxxxxxxxxxx\\Windows\\WindowStations"
#define | WINSTA_NAME L"Service-0x0000-0000$"
#define | MAX_SESSION_PATH 256
#define | SESSION_ROOT L"\\Sessions"
#define | CALLBACKSTACKLIMIT (KERNEL_PAGE_SIZE / 2)
#define | IS_PTR(p) ((((ULONG_PTR)(p)) & ~MAXUSHORT) != 0)
#define | PTR_TO_ID(p) ((USHORT)(((ULONG_PTR)(p)) & MAXUSHORT))
#define | CVKKEYCACHE 32
#define | CBKEYCACHE (CVKKEYCACHE >> 2)
#define | CVKASYNCKEYCACHE 32
#define | CBASYNCKEYCACHE (CVKASYNCKEYCACHE >> 2)
#define | CI_IN_SYNC_TRANSACTION 0x00000001
#define | CI_PROCESSING_QUEUE 0x00000002
#define | CI_16BIT 0x00000004
#define | CI_INITIALIZED 0x00000008
#define | CI_INTERTHREAD_HOOK 0x00000010
#define | CI_REGISTERCLASSES 0x00000020
#define | CI_INPUTCONTEXT_REINIT 0x00000040
#define | THREAD_CODEPAGE() (GetClientInfo()->CodePage)
#define | WMCR_IR_DBCSCHAR 0x80000000
#define | IS_DBCS_MESSAGE(DbcsChar) (((DWORD)(DbcsChar)) & 0x0000FF00)
#define | MAKE_IR_DBCSCHAR(DbcsChar)
#define | MAKE_WPARAM_DBCSCHAR(DbcsChar)
#define | DBCS_CHARSIZE (2)
#define | IS_DBCS_ENABLED() (TEST_SRVIF(SRVIF_DBCS))
#define | _IS_IME_ENABLED() (TEST_SRVIF(SRVIF_IME))
#define | IS_IME_ENABLED() _IS_IME_ENABLED()
#define | IS_DBCS_HKL() (IS_ANY_DBCS_CODEPAGE(THREAD_CODEPAGE()))
#define | IS_DBCS_INPUT() (IS_DBCS_ENABLED() || IS_DBCS_HKL())
#define | CP_JAPANESE (932)
#define | CP_KOREAN (949)
#define | CP_CHINESE_SIMP (936)
#define | CP_CHINESE_TRAD (950)
#define | IS_DBCS_CODEPAGE(wCodePage)
#define | IS_DBCS_CHARSET(charset)
#define | IS_JPN_1BYTE_KATAKANA(c) ((c) >= 0xa1 && (c) <= 0xdf)
#define | IMM_MAGIC_CALLER_ID (0x19650412)
#define | IS_MIDEAST_ENABLED() (TEST_SRVIF(SRVIF_MIDEAST))
#define | WMCS_EXIT 0x0001
#define | WMCS_QUERYEND 0x0002
#define | WMCS_SHUTDOWN 0x0004
#define | WMCS_CONTEXTLOGOFF 0x0008
#define | WMCS_ENDTASK 0x0010
#define | WMCS_CONSOLE 0x0020
#define | WMCS_NODLGIFHUNG 0x0040
#define | WMCS_NORETRY 0x0080
#define | WMCS_LOGOFF ENDSESSION_LOGOFF /* from winuser.w */
#define | WMCSR_ALLOWSHUTDOWN 1
#define | WMCSR_DONE 2
#define | WMCSR_CANCEL 3
#define | MultDiv(x, y, z) (((INT)(x) * (INT)(y) + (INT)(z) / 2) / (INT)(z))
#define | MFISPOPUP 0x00000001
#define | MFMULTIROW 0x00000002
#define | MFUNDERLINE 0x00000004
#define | MFWINDOWDC 0x00000008 /* Window DC vs Client area DC when drawing*/
#define | MFINACTIVE 0x00000010
#define | MFRTL 0x00000020
#define | MFDESKTOP 0x00000040 /* Set on the desktop menu AND its submenus */
#define | MFSYSMENU 0x00000080 /* Set on desktop menu but NOT on its submenus */
#define | MFAPPSYSMENU 0x00000100 /* Set on (sub)menu we return to the app via GetSystemMenu */
#define | MFLAST 0x00000100
#define | GWLP_INSTANCE_INFO 0
#define | GWLP_PCI 0
#define | GWL_CONVCONTEXT GWLP_PCI + sizeof(PVOID)
#define | GWL_CONVSTATE GWL_CONVCONTEXT + sizeof(CONVCONTEXT)
#define | GWLP_SHINST GWL_CONVSTATE + sizeof(LONG)
#define | GWLP_CHINST GWLP_SHINST + sizeof(HANDLE)
#define | CLST_CONNECTED 0
#define | CLST_SINGLE_INITIALIZING 1
#define | CLST_MULT_INITIALIZING 2
#define | GWLP_PSI 0
#define | GWLP_PSII 0
#define | DF_SHIFT0 0x0000
#define | DF_SHIFT1 0x0001
#define | DF_SHIFT2 0x0002
#define | DF_SHIFT3 0x0003
#define | DF_PATCOPY 0x0000
#define | DF_PATINVERT 0x0004
#define | DF_SHIFTMASK (DF_SHIFT0 | DF_SHIFT1 | DF_SHIFT2 | DF_SHIFT3)
#define | DF_ROPMASK (DF_PATCOPY | DF_PATINVERT)
#define | DF_HBRMASK ~(DF_SHIFTMASK | DF_ROPMASK)
#define | DF_SCROLLBAR (COLOR_SCROLLBAR << 3)
#define | DF_BACKGROUND (COLOR_BACKGROUND << 3)
#define | DF_ACTIVECAPTION (COLOR_ACTIVECAPTION << 3)
#define | DF_INACTIVECAPTION (COLOR_INACTIVECAPTION << 3)
#define | DF_MENU (COLOR_MENU << 3)
#define | DF_WINDOW (COLOR_WINDOW << 3)
#define | DF_WINDOWFRAME (COLOR_WINDOWFRAME << 3)
#define | DF_MENUTEXT (COLOR_MENUTEXT << 3)
#define | DF_WINDOWTEXT (COLOR_WINDOWTEXT << 3)
#define | DF_CAPTIONTEXT (COLOR_CAPTIONTEXT << 3)
#define | DF_ACTIVEBORDER (COLOR_ACTIVEBORDER << 3)
#define | DF_INACTIVEBORDER (COLOR_INACTIVEBORDER << 3)
#define | DF_APPWORKSPACE (COLOR_APPWORKSPACE << 3)
#define | DF_3DSHADOW (COLOR_3DSHADOW << 3)
#define | DF_3DFACE (COLOR_3DFACE << 3)
#define | DF_GRAY (COLOR_MAX << 3)
#define | WS_EX_MDICHILD 0x00000040L
#define | WS_EX_ANSICREATOR 0x80000000L
#define | FW_BOTH 0
#define | FW_16BIT 1
#define | FW_32BIT 2
#define | FIELD_SIZE(type, field) (sizeof(((type *)0)->field))
#define | FLASTKEY 0x80
#define | FNID_START 0x0000029A
#define | FNID_WNDPROCSTART 0x0000029A
#define | FNID_SCROLLBAR 0x0000029A
#define | FNID_ICONTITLE 0x0000029B
#define | FNID_MENU 0x0000029C
#define | FNID_DESKTOP 0x0000029D
#define | FNID_DEFWINDOWPROC 0x0000029E
#define | FNID_WNDPROCEND 0x0000029E
#define | FNID_CONTROLSTART 0x0000029F
#define | FNID_BUTTON 0x0000029F
#define | FNID_COMBOBOX 0x000002A0
#define | FNID_COMBOLISTBOX 0x000002A1
#define | FNID_DIALOG 0x000002A2
#define | FNID_EDIT 0x000002A3
#define | FNID_LISTBOX 0x000002A4
#define | FNID_MDICLIENT 0x000002A5
#define | FNID_STATIC 0x000002A6
#define | FNID_IME 0x000002A7
#define | FNID_CONTROLEND 0x000002A7
#define | FNID_HKINLPCWPEXSTRUCT 0x000002A8
#define | FNID_HKINLPCWPRETEXSTRUCT 0x000002A9
#define | FNID_DEFFRAMEPROC 0x000002AA
#define | FNID_DEFMDICHILDPROC 0x000002AB
#define | FNID_MB_DLGPROC 0x000002AC
#define | FNID_MDIACTIVATEDLGPROC 0x000002AD
#define | FNID_SENDMESSAGE 0x000002AE
#define | FNID_SENDMESSAGEFF 0x000002AF
#define | FNID_SENDMESSAGEEX 0x000002B0
#define | FNID_CALLWINDOWPROC 0x000002B1
#define | FNID_SENDMESSAGEBSM 0x000002B2
#define | FNID_SWITCH 0x000002B3
#define | FNID_TOOLTIP 0x000002B4
#define | FNID_END 0x000002B4
#define | FNID_ARRAY_SIZE 32
#define | FNID_DDE_BIT 0x00002000
#define | FNID_CLEANEDUP_BIT 0x00004000
#define | FNID_DELETED_BIT 0x00008000
#define | FNID_STATUS_BITS (FNID_CLEANEDUP_BIT | FNID_DELETED_BIT)
#define | FNID(s) (gpsi->mpFnidPfn[((DWORD)(s) - FNID_START) & (FNID_ARRAY_SIZE - 1)])
#define | STOCID(s) (gpsi->aStoCidPfn[(DWORD)((s) & ~FNID_STATUS_BITS) - FNID_START])
#define | CBFNID(s) (gpsi->mpFnid_serverCBWndProc[(DWORD)((s) & ~FNID_STATUS_BITS) - FNID_START])
#define | GETFNID(pwnd) ((pwnd)->fnid & ~FNID_STATUS_BITS)
#define | FNID_TO_CLIENT_PFNA_CLIENT FNID_TO_CLIENT_PFNA_KERNEL
#define | FNID_TO_CLIENT_PFNW_CLIENT FNID_TO_CLIENT_PFNW_KERNEL
#define | FNID_TO_CLIENT_PFNWORKER(s) (*(((KERNEL_ULONG_PTR *)&gpsi->apfnClientWorker) + (s - FNID_CONTROLSTART)))
#define | MapKernelClientFnToClientFn(lpfnWndProc) (lpfnWndProc)
#define | FNID_TO_CLIENT_PFNA_KERNEL(s) (*(((KERNEL_ULONG_PTR *)&gpsi->apfnClientA) + (s - FNID_START)))
#define | FNID_TO_CLIENT_PFNW_KERNEL(s) (*(((KERNEL_ULONG_PTR *)&gpsi->apfnClientW) + (s - FNID_START)))
#define | FNID_TO_CLIENT_PFNA FNID_TO_CLIENT_PFNA_KERNEL
#define | FNID_TO_CLIENT_PFNW FNID_TO_CLIENT_PFNW_KERNEL
#define | TYPE_FREE 0
#define | TYPE_WINDOW 1
#define | TYPE_MENU 2
#define | TYPE_CURSOR 3
#define | TYPE_SETWINDOWPOS 4
#define | TYPE_HOOK 5
#define | TYPE_CLIPDATA 6
#define | TYPE_CALLPROC 7
#define | TYPE_ACCELTABLE 8
#define | TYPE_DDEACCESS 9
#define | TYPE_DDECONV 10
#define | TYPE_DDEXACT 11
#define | TYPE_MONITOR 12
#define | TYPE_KBDLAYOUT 13
#define | TYPE_KBDFILE 14
#define | TYPE_WINEVENTHOOK 15
#define | TYPE_TIMER 16
#define | TYPE_INPUTCONTEXT 17
#define | TYPE_CTYPES 18
#define | TYPE_GENERIC 255
#define | DOBI_NORMAL 0
#define | DOBI_PUSHED 1
#define | DOBI_HOT 2
#define | DOBI_INACTIVE 3
#define | DOBI_CHECK 1
#define | DOBI_DOWN 2
#define | DOBI_CHECKDOWN 3
#define | DOBI_CAPON 0
#define | DOBI_CAPOFF 1
#define | DOBI_3STATE 8
#define | DOBI_MBAR OBI_CLOSE_MBAR
#define | OBI_CLOSE 0
#define | OBI_CLOSE_D 1
#define | OBI_CLOSE_H 2
#define | OBI_CLOSE_I 3
#define | OBI_REDUCE 4
#define | OBI_REDUCE_D 5
#define | OBI_REDUCE_H 6
#define | OBI_REDUCE_I 7
#define | OBI_RESTORE 8
#define | OBI_RESTORE_D 9
#define | OBI_RESTORE_H 10
#define | OBI_HELP 11
#define | OBI_HELP_D 12
#define | OBI_HELP_H 13
#define | OBI_ZOOM 14
#define | OBI_ZOOM_D 15
#define | OBI_ZOOM_H 16
#define | OBI_ZOOM_I 17
#define | OBI_CLOSE_MBAR 18
#define | OBI_CLOSE_MBAR_D 19
#define | OBI_CLOSE_MBAR_H 20
#define | OBI_CLOSE_MBAR_I 21
#define | OBI_REDUCE_MBAR 22
#define | OBI_REDUCE_MBAR_D 23
#define | OBI_REDUCE_MBAR_H 24
#define | OBI_REDUCE_MBAR_I 25
#define | OBI_RESTORE_MBAR 26
#define | OBI_RESTORE_MBAR_D 27
#define | OBI_RESTORE_MBAR_H 28
#define | OBI_CAPCACHE1 29
#define | OBI_CAPCACHE1_I 30
#define | OBI_CAPCACHE2 31
#define | OBI_CAPCACHE2_I 32
#define | OBI_CAPCACHE3 33
#define | OBI_CAPCACHE3_I 34
#define | OBI_CAPCACHE4 35
#define | OBI_CAPCACHE4_I 36
#define | OBI_CAPCACHE5 37
#define | OBI_CAPCACHE5_I 38
#define | OBI_CAPBTNS 39
#define | OBI_CAPBTNS_I 40
#define | OBI_CLOSE_PAL 41
#define | OBI_CLOSE_PAL_D 42
#define | OBI_CLOSE_PAL_H 43
#define | OBI_CLOSE_PAL_I 44
#define | OBI_NCGRIP 45
#define | OBI_UPARROW 46
#define | OBI_UPARROW_D 47
#define | OBI_UPARROW_H 48
#define | OBI_UPARROW_I 49
#define | OBI_DNARROW 50
#define | OBI_DNARROW_D 51
#define | OBI_DNARROW_H 52
#define | OBI_DNARROW_I 53
#define | OBI_RGARROW 54
#define | OBI_RGARROW_D 55
#define | OBI_RGARROW_H 56
#define | OBI_RGARROW_I 57
#define | OBI_LFARROW 58
#define | OBI_LFARROW_D 59
#define | OBI_LFARROW_H 60
#define | OBI_LFARROW_I 61
#define | OBI_MENUARROW 62
#define | OBI_MENUCHECK 63
#define | OBI_MENUBULLET 64
#define | OBI_MENUARROWUP 65
#define | OBI_MENUARROWUP_H 66
#define | OBI_MENUARROWUP_I 67
#define | OBI_MENUARROWDOWN 68
#define | OBI_MENUARROWDOWN_H 69
#define | OBI_MENUARROWDOWN_I 70
#define | OBI_RADIOMASK 71
#define | OBI_CHECK 72
#define | OBI_CHECK_C 73
#define | OBI_CHECK_D 74
#define | OBI_CHECK_CD 75
#define | OBI_CHECK_CDI 76
#define | OBI_RADIO 77
#define | OBI_RADIO_C 78
#define | OBI_RADIO_D 79
#define | OBI_RADIO_CD 80
#define | OBI_RADIO_CDI 81
#define | OBI_3STATE 82
#define | OBI_3STATE_C 83
#define | OBI_3STATE_D 84
#define | OBI_3STATE_CD 85
#define | OBI_3STATE_CDI 86
#define | OBI_POPUPFIRST 87
#define | OBI_CLOSE_POPUP 87
#define | OBI_RESTORE_POPUP 88
#define | OBI_ZOOM_POPUP 89
#define | OBI_REDUCE_POPUP 90
#define | OBI_NCGRIP_L 91
#define | OBI_MENUARROW_L 92
#define | OBI_COUNT 93
#define | NCHARS 256
#define | NCTRLS 0x20
#define | PUSIF_PALETTEDISPLAY 0x00000001 /* Is the display palettized? */
#define | PUSIF_SNAPTO 0x00000002 /* Is SnapTo enabled? */
#define | PUSIF_COMBOBOXANIMATION 0x00000004 /* Must match UPBOOLMask(SPI_GETCOMBOBOXANIMATION) */
#define | PUSIF_LISTBOXSMOOTHSCROLLING 0x00000008 /* Must match UPBOOLMask(SPI_GETLISTBOXSMOOTHSCROLLING) */
#define | PUSIF_KEYBOARDCUES 0x00000020 /* Must match UPBOOLMask(SPI_GETKEYBOARDCUES) */
#define | PUSIF_UIEFFECTS 0x80000000 /* Must match UPBOOLMask(SPI_GETUIEFFECTS) */
#define | TEST_PUSIF(f) TEST_FLAG(gpsi->PUSIFlags, f)
#define | TEST_BOOL_PUSIF(f) TEST_BOOL_FLAG(gpsi->PUSIFlags, f)
#define | SET_PUSIF(f) SET_FLAG(gpsi->PUSIFlags, f)
#define | CLEAR_PUSIF(f) CLEAR_FLAG(gpsi->PUSIFlags, f)
#define | SET_OR_CLEAR_PUSIF(f, fSet) SET_OR_CLEAR_FLAG(gpsi->PUSIFlags, f, fSet)
#define | TOGGLE_PUSIF(f) TOGGLE_FLAG(gpsi->PUSIFlags, f)
#define | TEST_EffectPUSIF(f) ((gpsi->PUSIFlags & (f | PUSIF_UIEFFECTS)) == (f | PUSIF_UIEFFECTS))
#define | TEST_EffectInvertPUSIF(f) (TEST_PUSIF(f) || !TEST_PUSIF(PUSIF_UIEFFECTS))
#define | TEST_KbdCuesPUSIF
#define | SRVIF_CHECKED 0x0001
#define | SRVIF_WINEVENTHOOKS 0x0002
#define | SRVIF_DBCS 0x0004
#define | SRVIF_IME 0x0008
#define | SRVIF_MIDEAST 0x0010
#define | TEST_SRVIF(f) TEST_FLAG(gpsi->wSRVIFlags, f)
#define | TEST_BOOL_SRVIF(f) TEST_BOOL_FLAG(gpsi->wSRVIFlags, f)
#define | SET_SRVIF(f) SET_FLAG(gpsi->wSRVIFlags, f)
#define | CLEAR_SRVIF(f) CLEAR_FLAG(gpsi->wSRVIFlags, f)
#define | SET_OR_CLEAR_SRVIF(f, fSet) SET_OR_CLEAR_FLAG(gpsi->wSRVIFlags, f, fSet)
#define | TOGGLE_SRVIF(f) TOGGLE_FLAG(gpsi->wSRVIFlags, f)
#define | FWINABLE() TEST_SRVIF(SRVIF_WINEVENTHOOKS)
#define | GETGPSIMBPSTR(u) (LPWSTR) (gpsi->MBStrings[(u)].szName)
#define | USER_MAJOR_VERSION 0x0005
#define | USER_MINOR_VERSION 0x0000
#define | USERCURRENTVERSION MAKELONG(USER_MINOR_VERSION, USER_MAJOR_VERSION)
#define | SSCF_NOTIFY 0x00000001
#define | SSCF_FORCESOLIDCOLOR 0x00000002
#define | SSCF_SETMAGICCOLORS 0x00000004
#define | SSCF_16COLORS 0x00000008
#define | OCF_THREADOWNED 0x01
#define | OCF_PROCESSOWNED 0x02
#define | OCF_MARKPROCESS 0x04
#define | OCF_USEPOOLQUOTA 0x08
#define | OCF_DESKTOPHEAP 0x10
#define | OCF_USEPOOLIFNODESKTOP 0x20
#define | OCF_SHAREDHEAP 0x40
#define | OCF_VARIABLESIZE 0
#define | HANDLEF_DESTROY 0x01
#define | HANDLEF_INDESTROY 0x02
#define | HANDLEF_MARKED_OK 0x10
#define | HANDLEF_GRANTED 0x20
#define | HANDLEF_POOL 0x40
#define | HANDLEF_VALID 0x7F
#define | HMINDEXBITS 0x0000FFFF
#define | HMUNIQSHIFT 16
#define | HMUNIQBITS 0xFFFF
#define | HMIndexFromHandle(h) ((ULONG)(((ULONG_PTR)(h)) & HMINDEXBITS))
#define | _HMPheFromObject(p) (&gSharedInfo.aheList[HMIndexFromHandle((((PHEAD)p)->h))])
#define | _HMObjectFromHandle(h) ((KERNEL_PVOID)(gSharedInfo.aheList[HMIndexFromHandle(h)].phead))
#define | HMUniqFromHandle(h) ((WORD)((((ULONG_PTR)h) >> HMUNIQSHIFT) & HMUNIQBITS))
#define | HMObjectType(p) (HMPheFromObject(p)->bType)
#define | HMIsMarkDestroy(p) (HMPheFromObject(p)->bFlags & HANDLEF_DESTROY)
#define | HMRevalidateHandle(h) HMValidateHandleNoSecure(h, TYPE_GENERIC)
#define | HMRevalidateCatHandle(h) HMValidateCatHandleNoSecure(h, TYPE_GENERIC)
#define | HMRevalidateHandleNoRip(h) HMValidateHandleNoRip(h, TYPE_GENERIC)
#define | RevalidateHmenu(hmenuX) HMValidateHandleNoRip(hmenuX, TYPE_MENU)
#define | _PtoHq(p) ((HANDLE)(((PHEAD)p)->h))
#define | _PtoH(p) ((HANDLE)((p) == NULL ? NULL : _PtoHq(p)))
#define | _HW(pwnd) ((HWND)_PtoH(pwnd))
#define | _HWCCX(ccxPwnd) ((HWND)_PtoH(ccxPwnd))
#define | _HWq(pwnd) ((HWND)_PtoHq(pwnd))
#define | HMPheFromObject(p) _HMPheFromObject(p)
#define | HMObjectFromHandle(h) _HMObjectFromHandle(h)
#define | HMCatObjectFromHandle(h) _HMObjectFromHandle(h)
#define | PtoH(p) _PtoH(p)
#define | PtoHq(p) _PtoHq(p)
#define | HW(pwnd) _HW(pwnd)
#define | HWCCX(ccxPwnd) _HW(ccxPwnd)
#define | HWq(pwnd) _HWq(pwnd)
#define | _GETPTI(p) (((PTHROBJHEAD)p)->pti)
#define | _GETPDESK(p) (((PDESKOBJHEAD)p)->rpdesk)
#define | _GETPPI(p) (((PPROCMARKHEAD)p)->ppi)
#define | GETPTI(p) _GETPTI(p)
#define | GETPDESK(p) _GETPDESK(p)
#define | GETPPI(p) _GETPPI(p)
#define | GETPWNDPPI(p) (GETPTI(p)->ppi)
#define | CPD_ANSI_TO_UNICODE 0x0001 /* CPD represents ansi to U transition */
#define | CPD_UNICODE_TO_ANSI 0x0002
#define | CPD_TRANSITION_TYPES (CPD_ANSI_TO_UNICODE|CPD_UNICODE_TO_ANSI)
#define | CPD_CLASS 0x0010 /* Get CPD for a class */
#define | CPD_WND 0x0020
#define | CPD_DIALOG 0x0040
#define | CPD_WNDTOCLS 0x0080
#define | CPDHANDLE_HI ((ULONG_PTR)~HMINDEXBITS)
#define | MAKE_CPDHANDLE(h) (HMIndexFromHandle(h) | CPDHANDLE_HI)
#define | ISCPDTAG(x) (((ULONG_PTR)(x) & CPDHANDLE_HI) == CPDHANDLE_HI)
#define | CFVREDRAW 0x0001
#define | CFHREDRAW 0x0002
#define | CFKANJIWINDOW 0x0004
#define | CFDBLCLKS 0x0008
#define | CFSERVERSIDEPROC 0x0010
#define | CFOWNDC 0x0020
#define | CFCLASSDC 0x0040
#define | CFPARENTDC 0x0080
#define | CFNOKEYCVT 0x0101
#define | CFNOCLOSE 0x0102
#define | CFLVB 0x0104
#define | CFSAVEBITS 0x0108
#define | CFOEMCHARS 0x0140
#define | CFIME 0x0201
#define | CFOFFSET (FIELD_OFFSET(CLS, style))
#define | TestCF(hwnd, flag) (*((BYTE *)((PWND)(hwnd))->pcls + CFOFFSET + HIBYTE(flag)) & LOBYTE(flag))
#define | SetCF(hwnd, flag) (*((BYTE *)((PWND)(hwnd))->pcls + CFOFFSET + HIBYTE(flag)) |= LOBYTE(flag))
#define | ClrCF(pcls, flag) (*((BYTE *)((PWND)(hwnd))->pcls + CFOFFSET + HIBYTE(flag)) &= ~LOBYTE(flag))
#define | TestCF2(pcls, flag) (*((BYTE *)(pcls) + CFOFFSET + (int)HIBYTE(flag)) & LOBYTE(flag))
#define | SetCF2(pcls, flag) (*((BYTE *)(pcls) + CFOFFSET + (int)HIBYTE(flag)) |= LOBYTE(flag))
#define | ClrCF2(pcls, flag) (*((BYTE *)(pcls) + CFOFFSET + (int)HIBYTE(flag)) &= ~LOBYTE(flag))
#define | PWCFromPCLS(pcls) ((PWC)((PBYTE)(pcls) + sizeof(CLS) + (pcls)->cbclsExtra))
#define | CSF_SERVERSIDEPROC 0x0001
#define | CSF_ANSIPROC 0x0002
#define | CSF_WOWDEFERDESTROY 0x0004
#define | CSF_SYSTEMCLASS 0x0008
#define | CSF_WOWCLASS 0x0010
#define | CSF_WOWEXTRA 0x0020
#define | CSF_CACHEDSMICON 0x0040
#define | CSF_WIN40COMPAT 0x0080
#define | CSF_VALID (CSF_ANSIPROC | CSF_WIN40COMPAT)
#define | PROPF_INTERNAL 0x0001
#define | PROPF_STRING 0x0002
#define | PROPF_NOPOOL 0x0004
#define | NEEDSPAINT(pwnd) (pwnd->hrgnUpdate != NULL || TestWF(pwnd, WFINTERNALPAINT))
#define | HF_GLOBAL 0x0001
#define | HF_ANSI 0x0002
#define | HF_NEEDHC_SKIP 0x0004
#define | HF_HUNG 0x0008
#define | HF_HOOKFAULTED 0x0010
#define | HF_NOPLAYBACKDELAY 0x0020
#define | HF_WX86KNOWNDLL 0x0040
#define | HF_DESTROYED 0x0080
#define | WHF_FROM_WH(n) (1 << (n + 1))
#define | WHF_MSGFILTER WHF_FROM_WH(WH_MSGFILTER)
#define | WHF_JOURNALRECORD WHF_FROM_WH(WH_JOURNALRECORD)
#define | WHF_JOURNALPLAYBACK WHF_FROM_WH(WH_JOURNALPLAYBACK)
#define | WHF_KEYBOARD WHF_FROM_WH(WH_KEYBOARD)
#define | WHF_GETMESSAGE WHF_FROM_WH(WH_GETMESSAGE)
#define | WHF_CALLWNDPROC WHF_FROM_WH(WH_CALLWNDPROC)
#define | WHF_CALLWNDPROCRET WHF_FROM_WH(WH_CALLWNDPROCRET)
#define | WHF_CBT WHF_FROM_WH(WH_CBT)
#define | WHF_SYSMSGFILTER WHF_FROM_WH(WH_SYSMSGFILTER)
#define | WHF_MOUSE WHF_FROM_WH(WH_MOUSE)
#define | WHF_HARDWARE WHF_FROM_WH(WH_HARDWARE)
#define | WHF_DEBUG WHF_FROM_WH(WH_DEBUG)
#define | WHF_SHELL WHF_FROM_WH(WH_SHELL)
#define | WHF_FOREGROUNDIDLE WHF_FROM_WH(WH_FOREGROUNDIDLE)
#define | MONF_VISIBLE 0x01
#define | MONF_PALETTEDISPLAY 0x02
#define | HDCBITS() gpDispInfo->hdcBits
#define | DTF_NEEDSPALETTECHANGED 0x00000001
#define | DTF_NEEDSREDRAW 0x00000002
#define | CWINHOOKS (WH_MAX - WH_MIN + 1)
#define | CURSOR_ALWAYSDESTROY 0
#define | CURSOR_CALLFROMCLIENT 1
#define | CURSOR_THREADCLEANUP 2
#define | PICON PCURSOR
#define | MSGFLAG_MASK 0xFFFE0000
#define | MSGFLAG_WOW_RESERVED 0x00010000
#define | MSGFLAG_DDE_MID_THUNK 0x80000000
#define | MSGFLAG_DDE_SPECIAL_SEND 0x40000000
#define | MSGFLAG_SPECIAL_THUNK 0x10000000
#define | WIDTHBYTES(i) ((((i) + 31) & ~31) >> 3)
#define | BITMAPWIDTHSIZE(cx, cy, planes, bpp) (WIDTHBYTES((cx * bpp)) * (cy) * (planes))
#define | WFMPRESENT 0x0001
#define | WFVPRESENT 0x0002
#define | WFHPRESENT 0x0004
#define | WFCPRESENT 0x0008
#define | WFFRAMEPRESENTMASK 0x000F
#define | WFSENDSIZEMOVE 0x0010
#define | WFMSGBOX 0x0020
#define | WFFRAMEON 0x0040
#define | WFHASSPB 0x0080
#define | WFNONCPAINT 0x0101
#define | WFSENDERASEBKGND 0x0102
#define | WFERASEBKGND 0x0104
#define | WFSENDNCPAINT 0x0108
#define | WFINTERNALPAINT 0x0110
#define | WFUPDATEDIRTY 0x0120
#define | WFHIDDENPOPUP 0x0140
#define | WFMENUDRAW 0x0180
#define | WFDIALOGWINDOW 0x0201
#define | WFTITLESET 0x0202
#define | WFSERVERSIDEPROC 0x0204
#define | WFANSIPROC 0x0208
#define | WFBEINGACTIVATED 0x0210
#define | WFHASPALETTE 0x0220
#define | WFPAINTNOTPROCESSED 0x0240
#define | WFSYNCPAINTPENDING 0x0280
#define | WFGOTQUERYSUSPENDMSG 0x0301
#define | WFGOTSUSPENDMSG 0x0302
#define | WFTOGGLETOPMOST 0x0304
#define | WFREDRAWIFHUNG 0x0308
#define | WFREDRAWFRAMEIFHUNG 0x0310
#define | WFANYHUNGREDRAW 0x0318
#define | WFANSICREATOR 0x0320
#define | WFREALLYMAXIMIZABLE 0x0340
#define | WFDESTROYED 0x0380
#define | WFWMPAINTSENT 0x0401
#define | WFDONTVALIDATE 0x0402
#define | WFSTARTPAINT 0x0404
#define | WFOLDUI 0x0408
#define | WFCEPRESENT 0x0410
#define | WFBOTTOMMOST 0x0420
#define | WFFULLSCREEN 0x0440
#define | WFINDESTROY 0x0480
#define | WFWIN31COMPAT 0x0501
#define | WFWIN40COMPAT 0x0502
#define | WFWIN50COMPAT 0x0504
#define | WFWINCOMPATMASK 0x0507
#define | WFMAXFAKEREGIONAL 0x0508
#define | WFCLOSEBUTTONDOWN 0x0510
#define | WFZOOMBUTTONDOWN 0x0520
#define | WFREDUCEBUTTONDOWN 0x0540
#define | WFHELPBUTTONDOWN 0x0580
#define | WFLINEUPBUTTONDOWN 0x0601
#define | WFPAGEUPBUTTONDOWN 0x0602
#define | WFPAGEDNBUTTONDOWN 0x0604
#define | WFLINEDNBUTTONDOWN 0x0608
#define | WFSCROLLBUTTONDOWN 0x0610
#define | WFVERTSCROLLTRACK 0x0620
#define | WFALWAYSSENDNCPAINT 0x0640
#define | WFPIXIEHACK 0x0680
#define | WFFULLSCREENBASE 0x0700
#define | WFFULLSCREENMASK 0x0707
#define | WEFTRUNCATEDCAPTION 0x0708
#define | WFNOANIMATE 0x0710
#define | WFSMQUERYDRAGICON 0x0720
#define | WFSHELLHOOKWND 0x0740
#define | WFISINITIALIZED 0x0780
#define | WEFDLGMODALFRAME 0x0801
#define | WEFDRAGOBJECT 0x0802
#define | WEFNOPARENTNOTIFY 0x0804
#define | WEFTOPMOST 0x0808
#define | WEFACCEPTFILES 0x0810
#define | WEFTRANSPARENT 0x0820
#define | WEFMDICHILD 0x0840
#define | WEFTOOLWINDOW 0x0880
#define | WEFWINDOWEDGE 0x0901
#define | WEFCLIENTEDGE 0x0902
#define | WEFEDGEMASK 0x0903
#define | WEFCONTEXTHELP 0x0904
#define | WEFRIGHT 0x0910
#define | WEFRTLREADING 0x0920
#define | WEFLEFTSCROLL 0x0940
#define | WEFCONTROLPARENT 0x0A01
#define | WEFSTATICEDGE 0x0A02
#define | WEFAPPWINDOW 0x0A04
#define | WEFLAYERED 0x0A08
#define | WEFPUIFOCUSHIDDEN 0x0B80
#define | WEFPUIACCELHIDDEN 0x0B40
#define | WEFNOACTIVATE 0x0B08
#define | WFMAXBOX 0x0E01
#define | WFTABSTOP 0x0E01
#define | WFMINBOX 0x0E02
#define | WFGROUP 0x0E02
#define | WFSIZEBOX 0x0E04
#define | WFSYSMENU 0x0E08
#define | WFHSCROLL 0x0E10
#define | WFVSCROLL 0x0E20
#define | WFDLGFRAME 0x0E40
#define | WFTOPLEVEL 0x0E40
#define | WFBORDER 0x0E80
#define | WFBORDERMASK 0x0EC0
#define | WFCAPTION 0x0EC0
#define | WFTILED 0x0F00
#define | WFMAXIMIZED 0x0F01
#define | WFCLIPCHILDREN 0x0F02
#define | WFCLIPSIBLINGS 0x0F04
#define | WFDISABLED 0x0F08
#define | WFVISIBLE 0x0F10
#define | WFMINIMIZED 0x0F20
#define | WFCHILD 0x0F40
#define | WFPOPUP 0x0F80
#define | WFTYPEMASK 0x0FC0
#define | WFICONICPOPUP 0x0FC0
#define | WFICONIC WFMINIMIZED
#define | BFTYPEMASK 0x0C0F
#define | BFRIGHTBUTTON 0x0C20
#define | BFICON 0x0C40
#define | BFBITMAP 0x0C80
#define | BFIMAGEMASK 0x0CC0
#define | BFLEFT 0x0D01
#define | BFRIGHT 0x0D02
#define | BFCENTER 0x0D03
#define | BFHORZMASK 0x0D03
#define | BFTOP 0x0D04
#define | BFBOTTOM 0x0D08
#define | BFVCENTER 0x0D0C
#define | BFVERTMASK 0x0D0C
#define | BFALIGNMASK 0x0D0F
#define | BFPUSHLIKE 0x0D10
#define | BFMULTILINE 0x0D20
#define | BFNOTIFY 0x0D40
#define | BFFLAT 0x0D80
#define | ISBSTEXTOROD(pwnd) (!TestWF(pwnd, BFBITMAP) && !TestWF(pwnd, BFICON))
#define | CBFSIMPLE 0x0C01
#define | CBFDROPDOWN 0x0C02
#define | CBFDROPDOWNLIST 0x0C03
#define | CBFEDITABLE 0x0C01
#define | CBFDROPPABLE 0x0C02
#define | CBFDROPTYPE 0x0C03
#define | CBFOWNERDRAWFIXED 0x0C10
#define | CBFOWNERDRAWVAR 0x0C20
#define | CBFOWNERDRAW 0x0C30
#define | CBFAUTOHSCROLL 0x0C40
#define | CBFOEMCONVERT 0x0C80
#define | CBFSORT 0x0D01
#define | CBFHASSTRINGS 0x0D02
#define | CBFNOINTEGRALHEIGHT 0x0D04
#define | CBFDISABLENOSCROLL 0x0D08
#define | CBFBUTTONUPTRACK 0x0D10
#define | CBFUPPERCASE 0x0D20
#define | CBFLOWERCASE 0x0D40
#define | DFSYSMODAL 0x0C02
#define | DF3DLOOK 0x0C04
#define | DFNOFAILCREATE 0x0C10
#define | DFLOCALEDIT 0x0C20
#define | WFNOIDLEMSG 0x0D01
#define | DFCONTROL 0x0D04
#define | EFMULTILINE 0x0C04
#define | EFUPPERCASE 0x0C08
#define | EFLOWERCASE 0x0C10
#define | EFPASSWORD 0x0C20
#define | EFAUTOVSCROLL 0x0C40
#define | EFAUTOHSCROLL 0x0C80
#define | EFNOHIDESEL 0x0D01
#define | EFCOMBOBOX 0x0D02
#define | EFOEMCONVERT 0x0D04
#define | EFREADONLY 0x0D08
#define | EFWANTRETURN 0x0D10
#define | EFNUMBER 0x0D20
#define | SBFSIZEBOXTOPLEFT 0x0C02
#define | SBFSIZEBOXBOTTOMRIGHT 0x0C04
#define | SBFSIZEBOX 0x0C08
#define | SBFSIZEGRIP 0x0C10
#define | SFTYPEMASK 0x0C1F
#define | SFNOPREFIX 0x0C80
#define | SFNOTIFY 0x0D01
#define | SFCENTERIMAGE 0x0D02
#define | SFRIGHTJUST 0x0D04
#define | SFREALSIZEIMAGE 0x0D08
#define | SFSUNKEN 0x0D10
#define | SFEDITCONTROL 0x0D20
#define | SFELLIPSISMASK 0x0DC0
#define | SFWIDELINESPACING 0x0C20
#define | SYS_ALTERNATE 0x2000
#define | SYS_PREVKEYSTATE 0x4000
#define | STATEOFFSET (FIELD_OFFSET(WND, state))
#define | LOBYTE(w) ((BYTE)((w) & 0x00FF))
#define | TestWF(hwnd, flag) (*(((BYTE *)(hwnd)) + STATEOFFSET + (int)HIBYTE(flag)) & LOBYTE(flag))
#define | SetWF(hwnd, flag) (*(((BYTE *)(hwnd)) + STATEOFFSET + (int)HIBYTE(flag)) |= LOBYTE(flag))
#define | ClrWF(hwnd, flag) (*(((BYTE *)(hwnd)) + STATEOFFSET + (int)HIBYTE(flag)) &= ~LOBYTE(flag))
#define | MaskWF(flag) ((WORD)( (HIBYTE(flag) & 1) ? LOBYTE(flag) << 8 : LOBYTE(flag)))
#define | TestwndChild(hwnd) (TestWF(hwnd, WFTYPEMASK) == LOBYTE(WFCHILD))
#define | TestwndIPopup(hwnd) (TestWF(hwnd, WFTYPEMASK) == LOBYTE(WFICONICPOPUP))
#define | TestwndTiled(hwnd) (TestWF(hwnd, WFTYPEMASK) == LOBYTE(WFTILED))
#define | TestwndNIPopup(hwnd) (TestWF(hwnd, WFTYPEMASK) == LOBYTE(WFPOPUP))
#define | TestwndPopup(hwnd) (TestwndNIPopup(hwnd) || TestwndIPopup(hwnd))
#define | TestwndHI(hwnd) (TestwndTiled(hwnd) || TestwndIPopup(hwnd))
#define | GetChildParent(pwnd) (TestwndChild(pwnd) ? pwnd->spwndParent : (PWND)NULL)
#define | GetWindowCreator(pwnd) (TestwndChild(pwnd) ? pwnd->spwndParent : pwnd->spwndOwner)
#define | TestwndFrameOn(pwnd) (TestWF(pwnd, WFFRAMEON) && (GETPTI(pwnd)->pq == gpqForeground))
#define | GetFullScreen(pwnd) (TestWF(pwnd, WFFULLSCREENMASK))
#define | SetFullScreen(pwnd, state)
#define | FTrueVis(pwnd) (_IsWindowVisible(pwnd))
#define | _IsWindowEnabled(pwnd) (TestWF(pwnd, WFDISABLED) == 0)
#define | _IsIconic(pwnd) (TestWF(pwnd, WFMINIMIZED) != 0)
#define | _IsZoomed(pwnd) (TestWF(pwnd, WFMAXIMIZED) != 0)
#define | SV_UNSET 0x0000
#define | SV_SET 0x0001
#define | SV_CLRFTRUEVIS 0x0002
#define | ID_SYSMENU 0x10
#define | ID_CLOSEMENU 0x20
#define | CHILDSYSMENU ID_CLOSEMENU
#define | ID_DIALOGSYSMENU 0x30
#define | ID_HSCROLLMENU 0x40
#define | ID_VSCROLLMENU 0x50
#define | MSA_OFF 0
#define | MSA_ON 1
#define | MSA_ATTOP 2
#define | MSA_ATBOTTOM 3
#define | ID_HELPMENU 4
#define | MNF_DONTSKIPSEPARATORS 0x0001
#define | LTUPFLAG 0x0001
#define | RTDNFLAG 0x0002
#define | CSPINBACKGROUND 100
#define | CCHTITLEMAX 256
#define | SW_MDIRESTORE 0xCC /* special xxxMinMaximize() command for MDI */
#define | CW2_USEDEFAULT 0x8000
#define | CW_FLAGS_DIFFHMOD 0x80000000
#define | MENUSYSMENU TEXT(' ') /* Space character */
#define | MENUCHILDSYSMENU TEXT('-') /* Hyphen */
#define | MF_ALLSTATE 0x00FF
#define | MF_MAINMENU 0xFFFF
#define | MFMWFP_OFFMENU 0
#define | MFMWFP_MAINMENU 0x0000FFFF
#define | MFMWFP_NOITEM 0xFFFFFFFF
#define | MFMWFP_UPARROW 0xFFFFFFFD /* Warning: Also used to define IDSYS_MNUP */
#define | MFMWFP_DOWNARROW 0xFFFFFFFC /* Warning: Also used to define IDSYS_MNDOWN */
#define | MFMWFP_MINVALID 0xFFFFFFFC
#define | MFMWFP_ALTMENU 0xFFFFFFFB
#define | MFMWFP_FIRSTITEM 0
#define | SetMF(pmenu, flag) ((pmenu)->fFlags |= (flag))
#define | ClearMF(pmenu, flag) ((pmenu)->fFlags &= ~(flag))
#define | TestMF(pmenu, flag) ((pmenu)->fFlags & (flag))
#define | SetMFS(pitem, flag) ((pitem)->fState |= (flag))
#define | TestMFS(pitem, flag) ((pitem)->fState & (flag))
#define | ClearMFS(pitem, flag) ((pitem)->fState &= ~(flag))
#define | SetMFT(pitem, flag) ((pitem)->fType |= (flag))
#define | TestMFT(pitem, flag) ((pitem)->fType & (flag))
#define | ClearMFT(pitem, flag) ((pitem)->fType &= ~(flag))
#define | PDLG(pwnd) (((PDIALOG)pwnd)->pdlg)
#define | DLGF_ANSI 0x01 /* lpfnDlg is an ANSI proc */
#define | GWLP_MDIDATA (FIELD_OFFSET(MDIWND, pmdi) - sizeof(WND))
#define | TIF_INCLEANUP (UINT)0x00000001
#define | TIF_16BIT (UINT)0x00000002
#define | TIF_SYSTEMTHREAD (UINT)0x00000004
#define | TIF_CSRSSTHREAD (UINT)0x00000008
#define | TIF_TRACKRECTVISIBLE (UINT)0x00000010
#define | TIF_ALLOWFOREGROUNDACTIVATE (UINT)0x00000020
#define | TIF_DONTATTACHQUEUE (UINT)0x00000040
#define | TIF_DONTJOURNALATTACH (UINT)0x00000080
#define | TIF_WOW64 (UINT)0x00000100 /* Thread is in a emulated 32bit process */
#define | TIF_INACTIVATEAPPMSG (UINT)0x00000200
#define | TIF_SPINNING (UINT)0x00000400
#define | TIF_PALETTEAWARE (UINT)0x00000800
#define | TIF_SHAREDWOW (UINT)0x00001000
#define | TIF_FIRSTIDLE (UINT)0x00002000
#define | TIF_WAITFORINPUTIDLE (UINT)0x00004000
#define | TIF_MOVESIZETRACKING (UINT)0x00008000
#define | TIF_VDMAPP (UINT)0x00010000
#define | TIF_DOSEMULATOR (UINT)0x00020000
#define | TIF_GLOBALHOOKER (UINT)0x00040000
#define | TIF_DELAYEDEVENT (UINT)0x00080000
#define | TIF_MSGPOSCHANGED (UINT)0x00100000
#define | TIF_IGNOREPLAYBACKDELAY (UINT)0x00400000
#define | TIF_ALLOWOTHERACCOUNTHOOK (UINT)0x00800000
#define | TIF_GUITHREADINITIALIZED (UINT)0x02000000
#define | TIF_DISABLEIME (UINT)0x04000000
#define | TIF_INGETTEXTLENGTH (UINT)0x08000000
#define | TIF_ANSILENGTH (UINT)0x10000000
#define | TIF_DISABLEHOOKS (UINT)0x20000000
#define | TIF_RESTRICTED (UINT)0x40000000
#define | CTIF_SYSQUEUELOCKED (UINT)0x00000001
#define | CTIF_INSENDMESSAGE (UINT)0x00000002
#define | CheckMsgFilter(wMsg, wMsgFilterMin, wMsgFilterMax)
#define | XPixFromXDU(x, cxChar) MultDiv(x, cxChar, 4)
#define | YPixFromYDU(y, cyChar) MultDiv(y, cyChar, 8)
#define | XDUFromXPix(x, cxChar) MultDiv(x, 4, cxChar)
#define | YDUFromYPix(y, cyChar) MultDiv(y, 8, cyChar)
#define | QF_UPDATEKEYSTATE (UINT)0x00001
#define | QF_FMENUSTATUSBREAK (UINT)0x00004
#define | QF_FMENUSTATUS (UINT)0x00008
#define | QF_FF10STATUS (UINT)0x00010
#define | QF_MOUSEMOVED (UINT)0x00020
#define | QF_ACTIVATIONCHANGE (UINT)0x00040
#define | QF_TABSWITCHING (UINT)0x00080
#define | QF_KEYSTATERESET (UINT)0x00100
#define | QF_INDESTROY (UINT)0x00200
#define | QF_LOCKNOREMOVE (UINT)0x00400
#define | QF_FOCUSNULLSINCEACTIVE (UINT)0x00800
#define | QF_DIALOGACTIVE (UINT)0x04000
#define | QF_EVENTDEACTIVATEREMOVED (UINT)0x08000
#define | QF_CAPTURELOCKED 0x00100000
#define | QF_ACTIVEWNDTRACKING 0x00200000
#define | RNDFRM_CORNER 10
#define | RNDFRM_BORDER 3
#define | GRC_SCROLLS 0x0001
#define | GRC_MINWNDS 0x0002
#define | GRC_FULLSCREEN 0x0004
#define | HRGN_EMPTY ((HRGN)0)
#define | HRGN_FULL ((HRGN)1)
#define | HRGN_MONITOR ((HRGN)2)
#define | HRGN_SPECIAL_LAST HRGN_MONITOR
#define | ConnectIfNecessary()
#define | MAX_SEB_STYLES 11 /* number of SEB_* values */
#define | SEB_OK 0 /* Button with "OK". */
#define | SEB_CANCEL 1 /* Button with "Cancel" */
#define | SEB_ABORT 2 /* Button with "&Abort" */
#define | SEB_RETRY 3 /* Button with "&Retry" */
#define | SEB_IGNORE 4 /* Button with "&Ignore" */
#define | SEB_YES 5 /* Button with "&Yes" */
#define | SEB_NO 6 /* Button with "&No" */
#define | SEB_CLOSE 7 /* Button with "&Close" */
#define | SEB_HELP 8 /* Button with "&Help" */
#define | SEB_TRYAGAIN 9 /* Button with "&Try Again" */
#define | SEB_CONTINUE 10 /* Button with "&Continue" */
#define | SEB_DEFBUTTON 0x8000 /* Mask to make this button default */
#define | RTLMENU HMENU
#define | xxxRtlSetMenuInfo NtUserThunkedMenuInfo
#define | xxxRtlSetMenuItemInfo(rtlMenu, uId, pmii) NtUserThunkedMenuItemInfo(rtlMenu, uId, FALSE, FALSE, pmii, NULL)
#define | CH_PREFIX TEXT('&')
#define | CH_ENGLISHPREFIX 0x1E
#define | CH_KANJIPREFIX 0x1F
#define | DT_CHARSETDRAW 1
#define | DT_CHARSETINIT 2
#define | DT_CHARSETDONE 3
#define | DT_GETNEXTWORD 4
#define | CCHELLIPSIS 3
#define | GRECT_CLIENT 0x0001
#define | GRECT_WINDOW 0x0002
#define | GRECT_RECTMASK 0x0003
#define | GRECT_CLIENTCOORDS 0x0010
#define | GRECT_WINDOWCOORDS 0x0020
#define | GRECT_PARENTCOORDS 0x0040
#define | GRECT_COORDMASK 0x0070
#define | TextPointer(h) ((LPWSTR)h)
#define | DO_DROPFILE 0x454C4946L
#define | ISTS() (!!(USER_SHARED_DATA->SuiteMask & (1 << TerminalServer)))
#define | CMSSLEEP 250
#define | CMSHUNGAPPTIMEOUT (5 * 1000)
#define | CMSHUNGTOKILLCOUNT 4
#define | CMSWAITTOKILLTIMEOUT (CMSHUNGTOKILLCOUNT * CMSHUNGAPPTIMEOUT)
#define | CMSAPPSTARTINGTIMEOUT (6 * CMSHUNGAPPTIMEOUT) /* Some setup apps are pretty slow. bug 195832 */
#define | CMS_QANIMATION 165
#define | CMS_FLASHWND 500
#define | CMS_MENUFADE 175
#define | CMS_SELECTIONFADE 350
#define | CMS_TOOLTIP 135
#define | PROCESSTERMINATETIMEOUT (90 * 1000)
#define | TESTSYNCONLYMESSAGE(msg, wParam)

## Typedefs

typedef tagWINDOWSTATION *KPTR_MODIFIER | PWINDOWSTATION
typedef _LOCKRECORD *KPTR_MODIFIER | PLR
typedef _TL *KPTR_MODIFIER | PTL
typedef tagDESKTOP *KPTR_MODIFIER | PDESKTOP
typedef tagTDB *KPTR_MODIFIER | PTDB
typedef tagSVR_INSTANCE_INFO * | PSVR_INSTANCE_INFO
typedef _MOVESIZEDATA * | PMOVESIZEDATA
typedef tagCURSOR *KPTR_MODIFIER | PCURSOR
typedef tagPOPUPMENU *KPTR_MODIFIER | PPOPUPMENU
typedef tagQMSG *KPTR_MODIFIER | PQMSG
typedef tagWND *KPTR_MODIFIER | PWND
typedef _ETHREAD * | PETHREAD
typedef tagDESKTOPINFO *KPTR_MODIFIER | PDESKTOPINFO
typedef tagDISPLAYINFO *KPTR_MODIFIER | PDISPLAYINFO
typedef tagCLIENTTHREADINFO *KPTR_MODIFIER | PCLIENTTHREADINFO
typedef tagDCE *KPTR_MODIFIER | PDCE
typedef tagSPB *KPTR_MODIFIER | PSPB
typedef tagQ *KPTR_MODIFIER | PQ
typedef tagTHREADINFO *KPTR_MODIFIER | PTHREADINFO
typedef tagPROCESSINFO *KPTR_MODIFIER | PPROCESSINFO
typedef tagWOWTHREADINFO * | PWOWTHREADINFO
typedef tagPERUSERDATA * | PPERUSERDATA
typedef tagPERUSERSERVERINFO * | PPERUSERSERVERINFO
typedef tagTERMINAL * | PTERMINAL
typedef _CLIENTINFO * | PCLIENTINFO
typedef tagMENU *KPTR_MODIFIER | PMENU
typedef tagHOOK *KPTR_MODIFIER | PHOOK
typedef _HANDLEENTRY *KPTR_MODIFIER | PHE
typedef tagSERVERINFO *KPTR_MODIFIER | PSERVERINFO
typedef _CALLPROCDATA *KPTR_MODIFIER | PCALLPROCDATA
typedef tagCLS *KPTR_MODIFIER | PCLS
typedef tagMONITOR *KPTR_MODIFIER | PMONITOR
typedef tagMBSTRING | MBSTRING
typedef tagSIZERECT | SIZERECT
typedef tagSIZERECT * | PSIZERECT
typedef tagSIZERECT * | LPSIZERECT
typedef const SIZERECT * | PCSIZERECT
typedef const SIZERECT * | LPCSIZERECT
typedef _CAPTUREBUF | CAPTUREBUF
typedef _CAPTUREBUF * | PCAPTUREBUF
typedef _CALLBACKSTATUS | CALLBACKSTATUS
typedef _CALLBACKSTATUS * | PCALLBACKSTATUS
typedef _LARGE_STRING | LARGE_STRING
typedef _LARGE_STRING * | PLARGE_STRING
typedef _LARGE_ANSI_STRING | LARGE_ANSI_STRING
typedef _LARGE_ANSI_STRING * | PLARGE_ANSI_STRING
typedef _LARGE_UNICODE_STRING | LARGE_UNICODE_STRING
typedef _LARGE_UNICODE_STRING * | PLARGE_UNICODE_STRING
typedef _CTLCOLOR | CTLCOLOR
typedef _CTLCOLOR * | PCTLCOLOR
typedef _DRAWICONEXDATA | DRAWICONEXDATA
typedef _CALLBACKWND | CALLBACKWND
typedef _CALLBACKWND * | PCALLBACKWND
typedef _CLIENTINFO | CLIENTINFO
typedef DWORD | ICH
typedef ICH * | LPICH
typedef _PROPSET | PROPSET
typedef _PROPSET * | PPROPSET
typedef tagEVENT_PACKET | EVENT_PACKET
typedef tagEVENT_PACKET * | PEVENT_PACKET
typedef * | LPPOINT5
typedef * | LPBROADCASTSYSTEMMSGPARAMS
typedef LRESULT(APIENTRY * | WNDPROC_PWND )(PWND, UINT, WPARAM, LPARAM)
typedef LRESULT(APIENTRY * | WNDPROC_PWNDEX )(PWND, UINT, WPARAM, LPARAM, ULONG_PTR)
typedef BOOL(APIENTRY * | WNDENUMPROC_PWND )(PWND, LPARAM)
typedef VOID(APIENTRY * | TIMERPROC_PWND )(PWND, UINT, UINT_PTR, LPARAM)
typedef _PFNCLIENT | PFNCLIENT
typedef _PFNCLIENT * | PPFNCLIENT
typedef _PFNCLIENTWORKER | PFNCLIENTWORKER
typedef _PFNCLIENTWORKER * | PPFNCLIENTWORKER
typedef tagOEMBITMAPINFO | OEMBITMAPINFO
typedef tagOEMBITMAPINFO * | POEMBITMAPINFO
typedef tagPERUSERSERVERINFO | PERUSERSERVERINFO
typedef tagSERVERINFO | SERVERINFO
typedef _WNDMSG | WNDMSG
typedef _WNDMSG * | PWNDMSG
typedef tagSHAREDINFO | SHAREDINFO
typedef tagSHAREDINFO * | PSHAREDINFO
typedef _USERCONNECT | USERCONNECT
typedef _USERCONNECT * | PUSERCONNECT
typedef tagGETCLIPBDATA | GETCLIPBDATA
typedef tagGETCLIPBDATA * | PGETCLIPBDATA
typedef tagSETCLIPBDATA | SETCLIPBDATA
typedef tagSETCLIPBDATA * | PSETCLIPBDATA
typedef void(* | FnDestroyUserObject )(void *)
typedef tagHANDLETYPEINFO | HANDLETYPEINFO
typedef tagHANDLETYPEINFO * | PHANDLETYPEINFO
typedef _HEAD | HEAD
typedef _HEAD * | PHEAD
typedef _THROBJHEAD | THROBJHEAD
typedef _THROBJHEAD * | PTHROBJHEAD
typedef _PROCOBJHEAD | PROCOBJHEAD
typedef _PROCOBJHEAD * | PPROCOBJHEAD
typedef _PROCMARKHEAD | PROCMARKHEAD
typedef _PROCMARKHEAD * | PPROCMARKHEAD
typedef _DESKHEAD | DESKHEAD
typedef _DESKHEAD * | PDESKHEAD
typedef _DESKOBJHEAD | DESKOBJHEAD
typedef _DESKOBJHEAD * | PDESKOBJHEAD
typedef _THRDESKHEAD | THRDESKHEAD
typedef _THRDESKHEAD * | PTHRDESKHEAD
typedef _PROCDESKHEAD | PROCDESKHEAD
typedef _PROCDESKHEAD * | PPROCDESKHEAD
typedef _HANDLEENTRY | HANDLEENTRY
typedef _CALLPROCDATA | CALLPROCDATA
typedef tagCOMMON_WNDCLASS | COMMON_WNDCLASS
typedef tagCLSMENUNAME | CLSMENUNAME
typedef tagCLSMENUNAME * | PCLSMENUNAME
typedef tagCLS | CLS
typedef tagCLS ** | PPCLS
typedef tagSBDATA | SBDATA
typedef tagSBDATA * | PSBDATA
typedef tagSBINFO | SBINFO
typedef tagSBINFO | PSBINFO
typedef tagPROP | PROP
typedef tagPROP * | PPROP
typedef tagPROPLIST | PROPLIST
typedef tagPROPLIST | PPROPLIST
typedef tagWND | WND
typedef tagCBox | CBOX
typedef tagCBox | PCBOX
typedef tagCOMBOWND | COMBOWND
typedef tagCOMBOWND * | PCOMBOWND
typedef _SCROLLPOS | SCROLLPOS
typedef _SCROLLPOS * | PSCROLLPOS
typedef tagLBIV | LBIV
typedef tagLBIV * | PLBIV
typedef tagLBWND | LBWND
typedef tagLBWND * | PLBWND
typedef tagIMC | IMC
typedef tagIMC * | PIMC
typedef tagHOOK | HOOK
typedef tagNAMELIST | NAMELIST
typedef tagNAMELIST * | PNAMELIST
typedef tagMONITOR | MONITOR
typedef tagDISPLAYINFO | DISPLAYINFO
typedef tagDESKTOPINFO | DESKTOPINFO
typedef tagCURSOR_ACON | CURSOR_ACON
typedef CURSOR_COMMON | CURSOR_COMMON
typedef ACON_COMMON | ACON_COMMON
typedef tagCURSOR | CURSOR
typedef tagACON | ACON
typedef tagACON * | PACON
typedef tagCURSORDATA | CURSORDATA
typedef tagCURSORDATA * | PCURSORDATA
typedef tagCURSORFIND | CURSORFIND
typedef tagCURSORFIND * | PCURSORFIND
typedef tagITEM | ITEM
typedef tagITEM | PITEM
typedef tagITEM | LPITEM
typedef tagMENULIST | MENULIST
typedef tagMENULIST | PMENULIST
typedef tagMENU | MENU
typedef tagDLGENUMDATA | DLGENUMDATA
typedef tagDLGENUMDATA * | PDLGENUMDATA
typedef tagSBCALC | SBCALC
typedef tagSBCALC * | PSBCALC
typedef tagSBTRACK | SBTRACK
typedef tagSBTRACK * | PSBTRACK
typedef _DLG | DLG
typedef _DLG | PDLG
typedef _DIALOG | DIALOG
typedef _DIALOG * | PDIALOG
typedef tagMDI | MDI
typedef tagMDI | PMDI
typedef tagMDIWND | MDIWND
typedef tagMDIWND * | PMDIWND
typedef tagCLIENTTHREADINFO | CLIENTTHREADINFO
typedef tagCARET | CARET
typedef tagCARET * | PCARET
typedef tagSBWND | SBWND
typedef tagSBWND * | PSBWND
typedef tagSBWND * | LPSBWND
typedef tagSNDMSGTIMEOUT | SNDMSGTIMEOUT
typedef tagSNDMSGTIMEOUT * | PSNDMSGTIMEOUT
typedef tagBUTN | BUTN
typedef tagBUTN * | PBUTN
typedef tagBUTNWND | BUTNWND
typedef tagBUTNWND * | PBUTNWND
typedef tagIMEUI | IMEUI
typedef tagIMEUI * | PIMEUI
typedef tagIMEWND | IMEWND
typedef tagIMEWND * | PIMEWND
typedef _MSGBOXDATA | MSGBOXDATA
typedef _MSGBOXDATA * | PMSGBOXDATA
typedef _MSGBOXDATA * | LPMSGBOXDATA
typedef void(FAR * | LPFNTEXTDRAW )(HDC, int, int, LPWSTR, int, DWORD)
typedef * | LPDRAWTEXTDATA
typedef LONG(* | FPLPKTABBEDTEXTOUT )(HDC, int, int, LPCWSTR, int, int, CONST INT *, int, BOOL, int, int, int)
typedef void(* | FPLPKPSMTEXTOUT )(HDC, int, int, LPWSTR, int, DWORD)
typedef int(* | FPLPKDRAWTEXTEX )(HDC, int, int, LPCWSTR, int, BOOL, UINT, LPDRAWTEXTDATA, UINT, int)
typedef tagED * | PED
typedef BOOL | LpkEditCreate (PED ped, HWND hWnd)
typedef int | LpkEditIchToXY (PED ped, HDC hDC, PSTR pText, ICH cch, ICH ichPos)
typedef ICH | LpkEditMouseToIch (PED ped, HDC hDC, PSTR pText, ICH cch, INT iX)
typedef ICH | LpkEditCchInWidth (PED ped, HDC hdc, PSTR pText, ICH cch, int width)
typedef INT | LpkEditGetLineWidth (PED ped, HDC hdc, PSTR pText, ICH cch)
typedef void | LpkEditDrawText (PED ped, HDC hdc, PSTR pText, INT cch, INT iMinSel, INT iMaxSel, INT iY)
typedef BOOL | LpkEditHScroll (PED ped, HDC hdc, PSTR pText)
typedef ICH | LpkEditMoveSelection (PED ped, HDC hdc, PSTR pText, ICH ich, BOOL fLeft)
typedef int | LpkEditVerifyText (PED ped, HDC hdc, PSTR pText, ICH ichInsert, PSTR pInsertText, ICH cchInsert)
typedef void | LpkEditNextWord (PED ped, HDC hdc, PSTR pText, ICH ichStart, BOOL fLeft, ICH *pichMin, ICH *pichMax)
typedef void | LpkEditSetMenu (PED ped, HMENU hMenu)
typedef int | LpkEditProcessMenu (PED ped, UINT idMenuItem)
typedef int | LpkEditCreateCaret (PED ped, HDC hdc, INT nWidth, INT nHeight, UINT hkl)
typedef ICH | LpkEditAdjustCaret (PED ped, HDC hdc, PSTR pText, ICH ich)
typedef tagLPKEDITCALLOUT | LPKEDITCALLOUT
typedef tagLPKEDITCALLOUT * | PLPKEDITCALLOUT
typedef _DOCONNECTDATA | DOCONNECTDATA
typedef _DOCONNECTDATA * | PDOCONNECTDATA
typedef _DORECONNECTDATA | DORECONNECTDATA
typedef _DORECONNECTDATA * | PDORECONNECTDATA
typedef tagMSG_TABLE_ENTRY | MSG_TABLE_ENTRY
typedef tagMNDRAGOVERINFO | MNDRAGOVERINFO
typedef tagMNDRAGOVERINFO * | PMNDRAGOVERINFO
typedef tagINTERNALSETHIGHCONTRAST | INTERNALSETHIGHCONTRAST
typedef tagINTERNALSETHIGHCONTRAST * | LPINTERNALSETHIGHCONTRAST

## Enumerations

enum | { TYPE_NORMAL, TYPE_POPUP, TYPE_TCARD }

## Functions

| DECLARE_KHANDLE (HIMC)
| DECLARE_HANDLE (HQ)
void | RECTFromSIZERECT (PRECT prc, PCSIZERECT psrc)
void | SIZERECTFromRECT (PSIZERECT psrc, LPCRECT prc)
__inline void | CopyRectInl (LPRECT prcDest, LPCRECT prcSrc)
__inline DWORD | EqualRectInl (LPCRECT prc1, LPCRECT prc2)
__inline void | SetRectEmptyInl (LPRECT prc)
__inline BOOL | IsEmptyString (PVOID p, ULONG bAnsi)
__inline void | NullTerminateString (PVOID p, ULONG bAnsi)
__inline UINT | StringLength (PVOID p, ULONG bAnsi)
BOOL | User32InitializeImmEntryTable (DWORD dwMagic)
PMONITOR | _MonitorFromPoint (POINT pt, DWORD dwFlags)
PMONITOR | _MonitorFromRect (LPCRECT lprc, DWORD dwFlags)
PMONITOR | _MonitorFromWindow (PWND pwnd, DWORD dwFlags)
WORD | VersionFromWindowFlag (PWND pwnd)
BOOL CALLBACK | EnumPwndDlgChildProc (PWND pwnd, LPARAM lParam)
BOOL | FIsParentDude (PWND pwnd)
UINT | CalcWakeMask (UINT wMsgFilterMin, UINT wMsgFilterMax, UINT fsWakeMaskFilter)
__inline WORD | GetInputBits (PCLIENTTHREADINFO pcti, WORD fsWakeMask, BOOL fAvailable)
LPWSTR | MB_GetString (UINT wBtn)
int | SoftModalMessageBox (LPMSGBOXDATA lpmb)
DWORD | GetContextHelpId (PWND pwnd)
PITEM | MNLookUpItem (PMENU pMenu, UINT wCmd, BOOL fByPosition, PMENU *ppMenuItemIsOn)
BOOL | xxxMNCanClose (PWND pwnd)
PMENU | xxxGetSysMenuHandle (PWND pwnd)
PWND | GetPrevPwnd (PWND pwndList, PWND pwndFind)
BOOL | _RegisterServicesProcess (DWORD dwProcessId)
RTLMENU | xxxLoadSysMenu (UINT uMenuId)
BOOL | _FChildVisible (PWND pwnd)
BOOL | RtlWCSMessageWParamCharToMB (DWORD msg, WPARAM *pWParam)
BOOL | RtlMBMessageWParamCharToWCS (DWORD msg, WPARAM *pWParam)
VOID | RtlInitLargeAnsiString (PLARGE_ANSI_STRING plstr, LPCSTR psz, UINT cchLimit)
VOID | RtlInitLargeUnicodeString (PLARGE_UNICODE_STRING plstr, LPCWSTR psz, UINT cchLimit)
DWORD | RtlGetExpWinVer (HANDLE hmod)
int | DrawTextExWorker (HDC hdc, LPWSTR lpchText, int cchText, LPRECT lprc, UINT dwDTformat, LPDRAWTEXTPARAMS lpDTparams, int iCharset)
LRESULT CALLBACK | fnHkINLPRECT (DWORD nCode, WPARAM wParam, LPRECT lParam, ULONG_PTR xParam, PROC xpfnProc)
LRESULT CALLBACK | fnHkINDWORD (DWORD nCode, WPARAM wParam, LPARAM lParam, ULONG_PTR xParam, PROC xpfnProc, LPDWORD lpFlags)
LRESULT CALLBACK | fnHkINLPMSG (DWORD nCode, WPARAM wParam, LPMSG lParam, ULONG_PTR xParam, PROC xpfnProc, BOOL bAnsi, LPDWORD lpFlags)
LRESULT CALLBACK | fnHkOPTINLPEVENTMSG (DWORD nCode, WPARAM wParam, LPEVENTMSGMSG lParam, ULONG_PTR xParam, PROC xpfnProc)
LRESULT CALLBACK | fnHkINLPDEBUGHOOKSTRUCT (DWORD nCode, WPARAM wParam, LPDEBUGHOOKINFO lParam, ULONG_PTR xParam, PROC xpfnProc)
LRESULT CALLBACK | fnHkINLPMOUSEHOOKSTRUCTEX (DWORD nCode, WPARAM wParam, LPMOUSEHOOKSTRUCTEX lParam, ULONG_PTR xParam, PROC xpfnProc, LPDWORD lpFlags)
LRESULT CALLBACK | fnHkINLPKBDLLHOOKSTRUCT (DWORD nCode, WPARAM wParam, LPKBDLLHOOKSTRUCT lParam, ULONG_PTR xParam, PROC xpfnProc)
LRESULT CALLBACK | fnHkINLPMSLLHOOKSTRUCT (DWORD nCode, WPARAM wParam, LPMSLLHOOKSTRUCT lParam, ULONG_PTR xParam, PROC xpfnProc)
LRESULT CALLBACK | fnHkINLPCBTACTIVATESTRUCT (DWORD nCode, WPARAM wParam, LPCBTACTIVATESTRUCT lParam, ULONG_PTR xParam, PROC xpfnProc)
LRESULT CALLBACK | fnHkINLPCBTCSTRUCT (UINT msg, WPARAM wParam, LPCBT_CREATEWND pcbt, PROC xpfnProc, BOOL bAnsi)
LRESULT CALLBACK | fnHkINLPCBTMDICCSTRUCT (UINT msg, WPARAM wParam, LPCBT_CREATEWND pcbt, PROC xpfnProc, BOOL bAnsi)
ULONG_PTR | GetCPD (PVOID pWndOrCls, DWORD options, ULONG_PTR dwData)
BOOL | TestWindowProcess (PWND pwnd)
DWORD | GetAppCompatFlags (PTHREADINFO pti)
DWORD | GetAppCompatFlags2 (WORD wVer)
DWORD | GetAppImeCompatFlags (PTHREADINFO pti)
PVOID FASTCALL | HMValidateHandle (HANDLE h, BYTE btype)
PVOID FASTCALL | HMValidateCatHandleNoRip (HANDLE h, BYTE btype)
PVOID FASTCALL | HMValidateHandleNoRip (HANDLE h, BYTE btype)
KERNEL_PVOID FASTCALL | HMValidateHandleNoDesktop (HANDLE h, BYTE btype)
PVOID FASTCALL | HMValidateSharedHandle (HANDLE h, BYTE bType)
PVOID FASTCALL | HMValidateCatHandleNoSecure (HANDLE h, BYTE bType)
PVOID FASTCALL | HMValidateCatHandleNoSecureCCX (HANDLE h, BYTE bType, PCLIENTINFO ccxPci)
PVOID FASTCALL | HMValidateHandleNoSecure (HANDLE h, BYTE bType)
ULONG_PTR | MapClientNeuterToClientPfn (PCLS pcls, KERNEL_ULONG_PTR dw, BOOL bAnsi)
ULONG_PTR | MapServerToClientPfn (KERNEL_ULONG_PTR dw, BOOL bAnsi)
BOOL | IsSysFontAndDefaultMode (HDC hdc)
int | GetCharDimensions (HDC hDC, TEXTMETRICW *lpTextMetrics, LPINT lpcy)
int | GetWindowBorders (LONG lStyle, DWORD dwExStyle, BOOL fWindow, BOOL fClient)
PWND | SizeBoxHwnd (PWND pwnd)
VOID | _GetClientRect (PWND pwnd, LPRECT prc)
void | GetRealClientRect (PWND pwnd, LPRECT prc, UINT uFlags, PMONITOR pMonitor)
VOID | _GetWindowRect (PWND pwnd, LPRECT prc)
PWND | _GetLastActivePopup (PWND pwnd)
BOOL | _IsChild (PWND pwndParent, PWND pwnd)
BOOL | _AdjustWindowRectEx (LPRECT lprc, LONG style, BOOL fMenu, DWORD dwExStyle)
BOOL | NeedsWindowEdge (DWORD dwStyle, DWORD dwExStyle, BOOL fNewApp)
VOID | _ClientToScreen (PWND pwnd, PPOINT ppt)
VOID | _ScreenToClient (PWND pwnd, PPOINT ppt)
int | _MapWindowPoints (PWND pwndFrom, PWND pwndTo, LPPOINT lppt, DWORD cpt)
BOOL | _IsWindowVisible (PWND pwnd)
BOOL | _IsDescendant (PWND pwndParent, PWND pwndChild)
BOOL | IsVisible (PWND pwnd)
PWND | _GetWindow (PWND pwnd, UINT cmd)
PWND | _GetParent (PWND pwnd)
int | FindNCHit (PWND pwnd, LONG lPt)
SHORT | _GetKeyState (int vk)
PHOOK | PhkNextValid (PHOOK phk)
void | GetRect (PWND pwnd, LPRECT lprc, UINT uCoords)
PPROP | _FindProp (PWND pwnd, PCWSTR pszKey, BOOL fInternal)
HANDLE | _GetProp (PWND pwnd, PCWSTR pszKey, BOOL fInternal)
BOOL | _HasCaptionIcon (PWND pwnd)
PWND | GetTopLevelWindow (PWND pwnd)
BOOL | _SBGetParms (PWND pwnd, int code, PSBDATA pw, LPSCROLLINFO lpsi)
BOOL | PSMGetTextExtent (HDC hdc, LPCWSTR lpstr, int cch, PSIZE psize)
LONG | GetPrefixCount (LPCWSTR lpstr, int cb, LPWSTR lpstrCopy, int cbCopy)
PMENU | _GetSubMenu (PMENU pMenu, int nPos)
DWORD | _GetMenuDefaultItem (PMENU pMenu, BOOL fByPosition, UINT uFlags)
UINT | _GetMenuState (PMENU pMenu, UINT wID, UINT dwFlags)
BOOL APIENTRY | CopyInflateRect (LPRECT prcDst, CONST RECT *prcSrc, int cx, int cy)
BOOL APIENTRY | CopyOffsetRect (LPRECT prcDst, CONST RECT *prcSrc, int cx, int cy)
DWORD | FindCharPosition (LPWSTR lpString, WCHAR ch)
LPWSTR | TextAlloc (LPCWSTR lpsz)
UINT | TextCopy (PLARGE_UNICODE_STRING pstr, LPWSTR lpstr, UINT size)
DWORD | wcsncpycch (LPWSTR pwsDest, LPCWSTR pwszSrc, DWORD cch)
DWORD | strncpycch (LPSTR pszDest, LPCSTR pszSrc, DWORD cch)
BOOL | DrawFrame (HDC hdc, LPRECT prect, int clFrame, int cmd)
void | DrawPushButton (HDC hdc, LPRECT lprc, UINT state, UINT flags)
BOOL | ClientFrame (HDC hDC, CONST RECT *pRect, HBRUSH hBrush, DWORD patOp)
HBITMAP | OwnerLoadBitmap (HANDLE hInstLoad, LPWSTR lpName, HANDLE hOwner)
PCURSOR | ClassSetSmallIcon (PCLS pcls, PCURSOR pcursor, BOOL fServerCreated)
void | KernelBP (void)

## Variables

typedef | PVWPL
FPLPKTABBEDTEXTOUT | fpLpkTabbedTextOut
FPLPKPSMTEXTOUT | fpLpkPSMTextOut
FPLPKDRAWTEXTEX | fpLpkDrawTextEx
PLPKEDITCALLOUT | fpLpkEditControl
HBRUSH | ghbrWhite
HBRUSH | ghbrBlack
PWND | _GetDesktopWindow (VOID)
PWND | _GetMessageWindow (VOID)
CONST MSG_TABLE_ENTRY | MessageTable []

## Define Documentation

#define _GETPDESK | ( | p |  | ) | (((PDESKOBJHEAD)p)->rpdesk)

| Definition at line 1600 of file inc/user.h.

#define _GETPPI | ( | p |  | ) | (((PPROCMARKHEAD)p)->ppi)

| Definition at line 1601 of file inc/user.h.

#define _GETPTI | ( | p |  | ) | (((PTHROBJHEAD)p)->pti)

| Definition at line 1599 of file inc/user.h.

#define _HMObjectFromHandle | ( | h |  | ) | ((KERNEL_PVOID)(gSharedInfo.aheList[HMIndexFromHandle(h)].phead))

| Definition at line 1542 of file inc/user.h.

#define _HMPheFromObject | ( | p |  | ) | (&gSharedInfo.aheList[HMIndexFromHandle((((PHEAD)p)->h))])

| Definition at line 1541 of file inc/user.h.

#define _HW | ( | pwnd |  | ) | ((HWND)_PtoH(pwnd))

| Definition at line 1559 of file inc/user.h.

#define _HWCCX | ( | ccxPwnd |  | ) | ((HWND)_PtoH(ccxPwnd))

| Definition at line 1560 of file inc/user.h.

#define _HWq | ( | pwnd |  | ) | ((HWND)_PtoHq(pwnd))

| Definition at line 1561 of file inc/user.h.

#define _IS_IME_ENABLED | (

)

(TEST_SRVIF(SRVIF_IME))

| Definition at line 612 of file inc/user.h.

#define _IsIconic | ( | pwnd |  | ) | (TestWF(pwnd, WFMINIMIZED) != 0)

| Definition at line 2720 of file inc/user.h.

#define _IsWindowEnabled | ( | pwnd |  | ) | (TestWF(pwnd, WFDISABLED) == 0)

| Definition at line 2719 of file inc/user.h.

#define _IsZoomed | ( | pwnd |  | ) | (TestWF(pwnd, WFMAXIMIZED) != 0)

| Definition at line 2721 of file inc/user.h.

#define _PtoH | ( | p |  | ) | ((HANDLE)((p) == NULL ? NULL : _PtoHq(p)))

| Definition at line 1558 of file inc/user.h.

#define _PtoHq | ( | p |  | ) | ((HANDLE)(((PHEAD)p)->h))

| Definition at line 1557 of file inc/user.h.

#define BFALIGNMASK 0x0D0F

| Definition at line 2589 of file inc/user.h.

#define BFBITMAP 0x0C80

| Definition at line 2578 of file inc/user.h.

#define BFBOTTOM 0x0D08

| Definition at line 2586 of file inc/user.h.

#define BFCENTER 0x0D03

| Definition at line 2583 of file inc/user.h.

#define BFFLAT 0x0D80

| Definition at line 2594 of file inc/user.h.

#define BFHORZMASK 0x0D03

| Definition at line 2584 of file inc/user.h.

#define BFICON 0x0C40

| Definition at line 2577 of file inc/user.h.

#define BFIMAGEMASK 0x0CC0

| Definition at line 2579 of file inc/user.h.

#define BFLEFT 0x0D01

| Definition at line 2581 of file inc/user.h.

#define BFMULTILINE 0x0D20

| Definition at line 2592 of file inc/user.h.

#define BFNOTIFY 0x0D40

| Definition at line 2593 of file inc/user.h.

#define BFPUSHLIKE 0x0D10

| Definition at line 2591 of file inc/user.h.

#define BFRIGHT 0x0D02

| Definition at line 2582 of file inc/user.h.

#define BFRIGHTBUTTON 0x0C20

| Definition at line 2576 of file inc/user.h.

#define BFTOP 0x0D04

| Definition at line 2585 of file inc/user.h.

#define BFTYPEMASK 0x0C0F

| Definition at line 2574 of file inc/user.h.

#define BFVCENTER 0x0D0C

| Definition at line 2587 of file inc/user.h.

#define BFVERTMASK 0x0D0C

| Definition at line 2588 of file inc/user.h.

#define BI_3STATE 2

| Definition at line 255 of file inc/user.h.

#define BI_CHECKBOX 0

| Definition at line 253 of file inc/user.h.

#define BI_RADIOBUTTON 1

| Definition at line 254 of file inc/user.h.

#define BITMAPWIDTHSIZE | ( | cx,
|  | cy,
|  | planes,
|  | bpp |  | ) | (WIDTHBYTES((cx * bpp)) * (cy) * (planes))

| Definition at line 2351 of file inc/user.h.

#define BUTTONCODE 0x80

| Definition at line 353 of file inc/user.h.

#define BYTESTOCHARS | ( | cb |  | ) | (cb)

| Definition at line 308 of file inc/user.h.

#define CALLBACKSTACKLIMIT (KERNEL_PAGE_SIZE / 2)

| Definition at line 418 of file inc/user.h.

#define CBASYNCKEYCACHE (CVKASYNCKEYCACHE >> 2)

| Definition at line 514 of file inc/user.h.

#define CBFAUTOHSCROLL 0x0C40

| Definition at line 2611 of file inc/user.h.

#define CBFBUTTONUPTRACK 0x0D10

| Definition at line 2617 of file inc/user.h.

#define CBFDISABLENOSCROLL 0x0D08

| Definition at line 2616 of file inc/user.h.

#define CBFDROPDOWN 0x0C02

| Definition at line 2600 of file inc/user.h.

#define CBFDROPDOWNLIST 0x0C03

| Definition at line 2601 of file inc/user.h.

#define CBFDROPPABLE 0x0C02

| Definition at line 2604 of file inc/user.h.

#define CBFDROPTYPE 0x0C03

| Definition at line 2605 of file inc/user.h.

#define CBFEDITABLE 0x0C01

| Definition at line 2603 of file inc/user.h.

#define CBFHASSTRINGS 0x0D02

| Definition at line 2614 of file inc/user.h.

#define CBFLOWERCASE 0x0D40

| Definition at line 2620 of file inc/user.h.

#define CBFNID | ( | s |  | ) | (gpsi->mpFnid_serverCBWndProc[(DWORD)((s) & ~FNID_STATUS_BITS) - FNID_START])

| Definition at line 900 of file inc/user.h.

#define CBFNOINTEGRALHEIGHT 0x0D04

| Definition at line 2615 of file inc/user.h.

#define CBFOEMCONVERT 0x0C80

| Definition at line 2612 of file inc/user.h.

#define CBFOWNERDRAW 0x0C30

| Definition at line 2609 of file inc/user.h.

#define CBFOWNERDRAWFIXED 0x0C10

| Definition at line 2607 of file inc/user.h.

#define CBFOWNERDRAWVAR 0x0C20

| Definition at line 2608 of file inc/user.h.

#define CBFSIMPLE 0x0C01

| Definition at line 2599 of file inc/user.h.

#define CBFSORT 0x0D01

| Definition at line 2613 of file inc/user.h.

#define CBFUPPERCASE 0x0D20

| Definition at line 2619 of file inc/user.h.

#define CBKEYCACHE (CVKKEYCACHE >> 2)

| Definition at line 511 of file inc/user.h.

#define CCHELLIPSIS 3

| Definition at line 3349 of file inc/user.h.

#define CCHTITLEMAX 256

| Definition at line 2886 of file inc/user.h.

#define CFCLASSDC 0x0040

| Definition at line 1670 of file inc/user.h.

#define CFDBLCLKS 0x0008

| Definition at line 1667 of file inc/user.h.

#define CFHREDRAW 0x0002

| Definition at line 1665 of file inc/user.h.

#define CFIME 0x0201

| Definition at line 1677 of file inc/user.h.

#define CFKANJIWINDOW 0x0004

| Definition at line 1666 of file inc/user.h.

#define CFLVB 0x0104

| Definition at line 1674 of file inc/user.h.

#define CFNOCLOSE 0x0102

| Definition at line 1673 of file inc/user.h.

#define CFNOKEYCVT 0x0101

| Definition at line 1672 of file inc/user.h.

#define CFOEMCHARS 0x0140

| Definition at line 1676 of file inc/user.h.

#define CFOFFSET (FIELD_OFFSET(CLS, style))

| Definition at line 1682 of file inc/user.h.

#define CFOWNDC 0x0020

| Definition at line 1669 of file inc/user.h.

#define CFPARENTDC 0x0080

| Definition at line 1671 of file inc/user.h.

#define CFSAVEBITS 0x0108

| Definition at line 1675 of file inc/user.h.

#define CFSERVERSIDEPROC 0x0010

| Definition at line 1668 of file inc/user.h.

#define CFVREDRAW 0x0001

| Definition at line 1664 of file inc/user.h.

#define CH_ENGLISHPREFIX 0x1E

| Definition at line 3291 of file inc/user.h.

#define CH_KANJIPREFIX 0x1F

| Definition at line 3292 of file inc/user.h.

#define CH_PREFIX TEXT('&')

| Definition at line 3285 of file inc/user.h.

#define CHARSTOBYTES | ( | cch |  | ) | (cch)

| Definition at line 309 of file inc/user.h.

#define CheckMsgFilter | ( | wMsg,
|  | wMsgFilterMin,
|  | wMsgFilterMax |  | ) |

Value:

    (   ((wMsgFilterMin) == 0 && (wMsgFilterMax) == 0xFFFFFFFF)            \
         || (  ((wMsgFilterMin) > (wMsgFilterMax))                             \
             ? (((wMsg) <  (wMsgFilterMax)) || ((wMsg) >  (wMsgFilterMin)))    \
             : (((wMsg) >= (wMsgFilterMin)) && ((wMsg) <= (wMsgFilterMax)))))

Definition at line 3054 of file inc/user.h.

#define CHILDSYSMENU ID_CLOSEMENU

| Definition at line 2734 of file inc/user.h.

#define CI_16BIT 0x00000004

| Definition at line 566 of file inc/user.h.

#define CI_IN_SYNC_TRANSACTION 0x00000001

| Definition at line 564 of file inc/user.h.

#define CI_INITIALIZED 0x00000008

| Definition at line 567 of file inc/user.h.

#define CI_INPUTCONTEXT_REINIT 0x00000040

| Definition at line 570 of file inc/user.h. Referenced by ImmActivateLayout(), xxxCreateWindowEx(), and xxxImmActivateThreadsLayout().

#define CI_INTERTHREAD_HOOK 0x00000010

| Definition at line 568 of file inc/user.h.

#define CI_PROCESSING_QUEUE 0x00000002

| Definition at line 565 of file inc/user.h.

#define CI_REGISTERCLASSES 0x00000020

| Definition at line 569 of file inc/user.h.

#define CLEAR_PUSIF | ( | f |  | ) | CLEAR_FLAG(gpsi->PUSIFlags, f)

| Definition at line 1162 of file inc/user.h.

#define CLEAR_SRVIF | ( | f |  | ) | CLEAR_FLAG(gpsi->wSRVIFlags, f)

| Definition at line 1260 of file inc/user.h.

#define ClearMF | ( | pmenu,
|  | flag |  | ) | ((pmenu)->fFlags &= ~(flag))

| Definition at line 2926 of file inc/user.h.

#define ClearMFS | ( | pitem,
|  | flag |  | ) | ((pitem)->fState &= ~(flag))

| Definition at line 2931 of file inc/user.h.

#define ClearMFT | ( | pitem,
|  | flag |  | ) | ((pitem)->fType &= ~(flag))

| Definition at line 2935 of file inc/user.h.

#define ClrCF | ( | pcls,
|  | flag |  | ) | (*((BYTE *)((PWND)(hwnd))->pcls + CFOFFSET + HIBYTE(flag)) &= ~LOBYTE(flag))

| Definition at line 1686 of file inc/user.h.

#define ClrCF2 | ( | pcls,
|  | flag |  | ) | (*((BYTE *)(pcls) + CFOFFSET + (int)HIBYTE(flag)) &= ~LOBYTE(flag))

| Definition at line 1690 of file inc/user.h.

#define ClrWF | ( | hwnd,
|  | flag |  | ) | (*(((BYTE *)(hwnd)) + STATEOFFSET + (int)HIBYTE(flag)) &= ~LOBYTE(flag))

| Definition at line 2697 of file inc/user.h.

#define CLST_CONNECTED 0

| Definition at line 730 of file inc/user.h.

#define CLST_MULT_INITIALIZING 2

| Definition at line 732 of file inc/user.h.

#define CLST_SINGLE_INITIALIZING 1

| Definition at line 731 of file inc/user.h.

#define CMS_FLASHWND 500

| Definition at line 3655 of file inc/user.h.

#define CMS_MENUFADE 175

| Definition at line 3656 of file inc/user.h. Referenced by xxxMenuWindowProc().

#define CMS_QANIMATION 165

| Definition at line 3654 of file inc/user.h.

#define CMS_SELECTIONFADE 350

| Definition at line 3657 of file inc/user.h. Referenced by MNFadeSelection().

#define CMS_TOOLTIP 135

| Definition at line 3658 of file inc/user.h. Referenced by TooltipAnimate(), and xxxTooltipWndProc().

#define CMSAPPSTARTINGTIMEOUT (6 * CMSHUNGAPPTIMEOUT) /* Some setup apps are pretty slow. bug 195832 */

| Definition at line 3653 of file inc/user.h.

#define CMSHUNGAPPTIMEOUT (5 * 1000)

| Definition at line 3650 of file inc/user.h.

#define CMSHUNGTOKILLCOUNT 4

| Definition at line 3651 of file inc/user.h.

#define CMSSLEEP 250

| Definition at line 3649 of file inc/user.h.

#define CMSWAITTOKILLTIMEOUT (CMSHUNGTOKILLCOUNT * CMSHUNGAPPTIMEOUT)

| Definition at line 3652 of file inc/user.h.

#define CODEBIT 0x80

| Definition at line 352 of file inc/user.h.

#define COMBOBOXCODE 0x85

| Definition at line 358 of file inc/user.h.

#define COMBOLISTBOXCODE 0x87

| Definition at line 360 of file inc/user.h.

#define ConnectIfNecessary | (

)

Value:

    { \
        if ((NtCurrentTebShared()->Win32ThreadInfo == NULL) \
                && !NtUserGetThreadState(UserThreadConnect)) { \
            return 0; \
        } \
    }

Definition at line 3173 of file inc/user.h.

Referenced by _GetDesktopWindow(), AdjustWindowRect(), AdjustWindowRectEx(), CallNextHookEx(), GetAppCompatFlags(), GetAppCompatFlags2(), GetProgmanWindow(), GetShellWindow(), GetSystemMetrics(), GetTaskmanWindow(), InternalCreateDialog(), LoadIcoCur(), LookupIconIdFromDirectoryEx(), PtiCurrent(), and SoftModalMessageBox().

#define CopyRect CopyRectInl

| Definition at line 269 of file inc/user.h.

#define CP_CHINESE_SIMP (936)

| Definition at line 625 of file inc/user.h.

#define CP_CHINESE_TRAD (950)

| Definition at line 626 of file inc/user.h.

#define CP_JAPANESE (932)

| Definition at line 623 of file inc/user.h. Referenced by IsDbcsExemptionForHighAnsi().

#define CP_KOREAN (949)

| Definition at line 624 of file inc/user.h.

#define CPD_ANSI_TO_UNICODE 0x0001 /* CPD represents ansi to U transition */

| Definition at line 1638 of file inc/user.h.

#define CPD_CLASS 0x0010 /* Get CPD for a class */

| Definition at line 1642 of file inc/user.h.

#define CPD_DIALOG 0x0040

| Definition at line 1644 of file inc/user.h.

#define CPD_TRANSITION_TYPES (CPD_ANSI_TO_UNICODE|CPD_UNICODE_TO_ANSI)

| Definition at line 1640 of file inc/user.h.

#define CPD_UNICODE_TO_ANSI 0x0002

| Definition at line 1639 of file inc/user.h.

#define CPD_WND 0x0020

| Definition at line 1643 of file inc/user.h.

#define CPD_WNDTOCLS 0x0080

| Definition at line 1645 of file inc/user.h.

#define CPDHANDLE_HI ((ULONG_PTR)~HMINDEXBITS)

| Definition at line 1647 of file inc/user.h.

#define CSF_ANSIPROC 0x0002

| Definition at line 1765 of file inc/user.h.

#define CSF_CACHEDSMICON 0x0040

| Definition at line 1770 of file inc/user.h. Referenced by DestroyClassSmIcon(), xxxCreateClassSmIcon(), and xxxSetClassIcon().

#define CSF_SERVERSIDEPROC 0x0001

| Definition at line 1764 of file inc/user.h.

#define CSF_SYSTEMCLASS 0x0008

| Definition at line 1767 of file inc/user.h.

#define CSF_VALID (CSF_ANSIPROC | CSF_WIN40COMPAT)

| Definition at line 1772 of file inc/user.h. Referenced by NtUserRegisterClassExWOW().

#define CSF_WIN40COMPAT 0x0080

| Definition at line 1771 of file inc/user.h. Referenced by InternalRegisterClassEx(), and LW_RegisterWindows().

#define CSF_WOWCLASS 0x0010

| Definition at line 1768 of file inc/user.h.

#define CSF_WOWDEFERDESTROY 0x0004

| Definition at line 1766 of file inc/user.h.

#define CSF_WOWEXTRA 0x0020

| Definition at line 1769 of file inc/user.h.

#define CSPINBACKGROUND 100

| Definition at line 2884 of file inc/user.h.

#define CTIF_INSENDMESSAGE (UINT)0x00000002

| Definition at line 3048 of file inc/user.h. Referenced by InSendMessage(), InSendMessageEx(), and xxxReceiveMessage().

#define CTIF_SYSQUEUELOCKED (UINT)0x00000001

| Definition at line 3047 of file inc/user.h.

#define CURSOR_ALWAYSDESTROY 0

| Definition at line 2269 of file inc/user.h.

#define CURSOR_CALLFROMCLIENT 1

| Definition at line 2270 of file inc/user.h.

#define CURSOR_THREADCLEANUP 2

| Definition at line 2271 of file inc/user.h.

#define CVKASYNCKEYCACHE 32

| Definition at line 513 of file inc/user.h.

#define CVKKEYCACHE 32

| Definition at line 510 of file inc/user.h.

#define CW2_USEDEFAULT 0x8000

| Definition at line 2894 of file inc/user.h.

#define CW_FLAGS_DIFFHMOD 0x80000000

| Definition at line 2895 of file inc/user.h.

#define CWINHOOKS (WH_MAX - WH_MIN + 1)

| Definition at line 2231 of file inc/user.h.

#define DBCS_CHARSIZE (2)

| Definition at line 609 of file inc/user.h.

#define DbgPrint UserDbgPrint

| Definition at line 172 of file inc/user.h.

#define DESKTOPCLASS MAKEINTATOM(0x8001)

| Definition at line 315 of file inc/user.h.

#define DESTINATION (DWORD)0x00AA0000

| Definition at line 246 of file inc/user.h.

#define DF3DLOOK 0x0C04

| Definition at line 2624 of file inc/user.h.

#define DF_3DFACE (COLOR_3DFACE << 3)

| Definition at line 770 of file inc/user.h.

#define DF_3DSHADOW (COLOR_3DSHADOW << 3)

| Definition at line 769 of file inc/user.h.

#define DF_ACTIVEBORDER (COLOR_ACTIVEBORDER << 3)

| Definition at line 766 of file inc/user.h.

#define DF_ACTIVECAPTION (COLOR_ACTIVECAPTION << 3)

| Definition at line 758 of file inc/user.h.

#define DF_APPWORKSPACE (COLOR_APPWORKSPACE << 3)

| Definition at line 768 of file inc/user.h.

#define DF_BACKGROUND (COLOR_BACKGROUND << 3)

| Definition at line 757 of file inc/user.h.

#define DF_CAPTIONTEXT (COLOR_CAPTIONTEXT << 3)

| Definition at line 765 of file inc/user.h.

#define DF_GRAY (COLOR_MAX << 3)

| Definition at line 771 of file inc/user.h.

#define DF_HBRMASK ~(DF_SHIFTMASK | DF_ROPMASK)

| Definition at line 754 of file inc/user.h.

#define DF_INACTIVEBORDER (COLOR_INACTIVEBORDER << 3)

| Definition at line 767 of file inc/user.h.

#define DF_INACTIVECAPTION (COLOR_INACTIVECAPTION << 3)

| Definition at line 759 of file inc/user.h.

#define DF_MENU (COLOR_MENU << 3)

| Definition at line 760 of file inc/user.h.

#define DF_MENUTEXT (COLOR_MENUTEXT << 3)

| Definition at line 763 of file inc/user.h.

#define DF_PATCOPY 0x0000

| Definition at line 750 of file inc/user.h.

#define DF_PATINVERT 0x0004

| Definition at line 751 of file inc/user.h.

#define DF_ROPMASK (DF_PATCOPY | DF_PATINVERT)

| Definition at line 753 of file inc/user.h.

#define DF_SCROLLBAR (COLOR_SCROLLBAR << 3)

| Definition at line 756 of file inc/user.h.

#define DF_SHIFT0 0x0000

| Definition at line 746 of file inc/user.h.

#define DF_SHIFT1 0x0001

| Definition at line 747 of file inc/user.h.

#define DF_SHIFT2 0x0002

| Definition at line 748 of file inc/user.h.

#define DF_SHIFT3 0x0003

| Definition at line 749 of file inc/user.h.

#define DF_SHIFTMASK (DF_SHIFT0 | DF_SHIFT1 | DF_SHIFT2 | DF_SHIFT3)

| Definition at line 752 of file inc/user.h.

#define DF_WINDOW (COLOR_WINDOW << 3)

| Definition at line 761 of file inc/user.h.

#define DF_WINDOWFRAME (COLOR_WINDOWFRAME << 3)

| Definition at line 762 of file inc/user.h.

#define DF_WINDOWTEXT (COLOR_WINDOWTEXT << 3)

| Definition at line 764 of file inc/user.h.

#define DFCONTROL 0x0D04

| Definition at line 2628 of file inc/user.h.

#define DFLOCALEDIT 0x0C20

| Definition at line 2626 of file inc/user.h.

#define DFNOFAILCREATE 0x0C10

| Definition at line 2625 of file inc/user.h.

#define DFSYSMODAL 0x0C02

| Definition at line 2623 of file inc/user.h.

#define DIALOGCLASS MAKEINTATOM(0x8002)

| Definition at line 316 of file inc/user.h.

#define DLGF_ANSI 0x01 /* lpfnDlg is an ANSI proc */

| Definition at line 2974 of file inc/user.h.

#define DO_DROPFILE 0x454C4946L

| Definition at line 3598 of file inc/user.h.

#define DOBI_3STATE 8

| Definition at line 1043 of file inc/user.h.

#define DOBI_CAPOFF 1

| Definition at line 1040 of file inc/user.h.

#define DOBI_CAPON 0

| Definition at line 1039 of file inc/user.h.

#define DOBI_CHECK 1

| Definition at line 1035 of file inc/user.h.

#define DOBI_CHECKDOWN 3

| Definition at line 1037 of file inc/user.h.

#define DOBI_DOWN 2

| Definition at line 1036 of file inc/user.h.

#define DOBI_HOT 2

| Definition at line 1032 of file inc/user.h.

#define DOBI_INACTIVE 3

| Definition at line 1033 of file inc/user.h.

#define DOBI_MBAR OBI_CLOSE_MBAR

| Definition at line 1044 of file inc/user.h.

#define DOBI_NORMAL 0

| Definition at line 1030 of file inc/user.h.

#define DOBI_PUSHED 1

| Definition at line 1031 of file inc/user.h.

#define DT_CHARSETDONE 3

| Definition at line 3313 of file inc/user.h.

#define DT_CHARSETDRAW 1

| Definition at line 3311 of file inc/user.h.

#define DT_CHARSETINIT 2

| Definition at line 3312 of file inc/user.h.

#define DT_GETNEXTWORD 4

| Definition at line 3314 of file inc/user.h.

#define DTF_NEEDSPALETTECHANGED 0x00000001

| Definition at line 2228 of file inc/user.h.

#define DTF_NEEDSREDRAW 0x00000002

| Definition at line 2229 of file inc/user.h.

#define EDITCODE 0x81

| Definition at line 354 of file inc/user.h.

#define EFAUTOHSCROLL 0x0C80

| Definition at line 2636 of file inc/user.h.

#define EFAUTOVSCROLL 0x0C40

| Definition at line 2635 of file inc/user.h.

#define EFCOMBOBOX 0x0D02

| Definition at line 2638 of file inc/user.h.

#define EFLOWERCASE 0x0C10

| Definition at line 2633 of file inc/user.h.

#define EFMULTILINE 0x0C04

| Definition at line 2631 of file inc/user.h.

#define EFNOHIDESEL 0x0D01

| Definition at line 2637 of file inc/user.h.

#define EFNUMBER 0x0D20

| Definition at line 2642 of file inc/user.h.

#define EFOEMCONVERT 0x0D04

| Definition at line 2639 of file inc/user.h.

#define EFPASSWORD 0x0C20

| Definition at line 2634 of file inc/user.h.

#define EFREADONLY 0x0D08

| Definition at line 2640 of file inc/user.h.

#define EFUPPERCASE 0x0C08

| Definition at line 2632 of file inc/user.h.

#define EFWANTRETURN 0x0D10

| Definition at line 2641 of file inc/user.h.

#define EqualRect EqualRectInl

| Definition at line 270 of file inc/user.h.

#define FASTCALL

| Definition at line 114 of file inc/user.h.

#define FIELD_SIZE | ( | type,
|  | field |  | ) | (sizeof(((type *)0)->field))

| Definition at line 791 of file inc/user.h.

#define FLASTKEY 0x80

| Definition at line 793 of file inc/user.h.

#define FNID | ( | s |  | ) | (gpsi->mpFnidPfn[((DWORD)(s) - FNID_START) & (FNID_ARRAY_SIZE - 1)])

| Definition at line 898 of file inc/user.h.

#define FNID_ARRAY_SIZE 32

| Definition at line 887 of file inc/user.h.

#define FNID_BUTTON 0x0000029F

| Definition at line 851 of file inc/user.h.

#define FNID_CALLWINDOWPROC 0x000002B1

| Definition at line 873 of file inc/user.h.

#define FNID_CLEANEDUP_BIT 0x00004000

| Definition at line 894 of file inc/user.h.

#define FNID_COMBOBOX 0x000002A0

| Definition at line 852 of file inc/user.h.

#define FNID_COMBOLISTBOX 0x000002A1

| Definition at line 853 of file inc/user.h.

#define FNID_CONTROLEND 0x000002A7

| Definition at line 861 of file inc/user.h.

#define FNID_CONTROLSTART 0x0000029F

| Definition at line 849 of file inc/user.h.

#define FNID_DDE_BIT 0x00002000

| Definition at line 893 of file inc/user.h.

#define FNID_DEFFRAMEPROC 0x000002AA

| Definition at line 865 of file inc/user.h.

#define FNID_DEFMDICHILDPROC 0x000002AB

| Definition at line 866 of file inc/user.h.

#define FNID_DEFWINDOWPROC 0x0000029E

| Definition at line 846 of file inc/user.h.

#define FNID_DELETED_BIT 0x00008000

| Definition at line 895 of file inc/user.h.

#define FNID_DESKTOP 0x0000029D

| Definition at line 845 of file inc/user.h.

#define FNID_DIALOG 0x000002A2

| Definition at line 854 of file inc/user.h.

#define FNID_EDIT 0x000002A3

| Definition at line 855 of file inc/user.h.

#define FNID_END 0x000002B4

| Definition at line 877 of file inc/user.h.

#define FNID_HKINLPCWPEXSTRUCT 0x000002A8

| Definition at line 863 of file inc/user.h.

#define FNID_HKINLPCWPRETEXSTRUCT 0x000002A9

| Definition at line 864 of file inc/user.h.

#define FNID_ICONTITLE 0x0000029B

| Definition at line 843 of file inc/user.h.

#define FNID_IME 0x000002A7

| Definition at line 860 of file inc/user.h.

#define FNID_LISTBOX 0x000002A4

| Definition at line 856 of file inc/user.h.

#define FNID_MB_DLGPROC 0x000002AC

| Definition at line 867 of file inc/user.h.

#define FNID_MDIACTIVATEDLGPROC 0x000002AD

| Definition at line 868 of file inc/user.h.

#define FNID_MDICLIENT 0x000002A5

| Definition at line 857 of file inc/user.h.

#define FNID_MENU 0x0000029C

| Definition at line 844 of file inc/user.h.

#define FNID_SCROLLBAR 0x0000029A

| Definition at line 842 of file inc/user.h.

#define FNID_SENDMESSAGE 0x000002AE

| Definition at line 869 of file inc/user.h.

#define FNID_SENDMESSAGEBSM 0x000002B2

| Definition at line 874 of file inc/user.h.

#define FNID_SENDMESSAGEEX 0x000002B0

| Definition at line 872 of file inc/user.h.

#define FNID_SENDMESSAGEFF 0x000002AF

| Definition at line 871 of file inc/user.h.

#define FNID_START 0x0000029A

| Definition at line 839 of file inc/user.h.

#define FNID_STATIC 0x000002A6

| Definition at line 858 of file inc/user.h.

#define FNID_STATUS_BITS (FNID_CLEANEDUP_BIT | FNID_DELETED_BIT)

| Definition at line 896 of file inc/user.h.

#define FNID_SWITCH 0x000002B3

| Definition at line 875 of file inc/user.h.

#define FNID_TO_CLIENT_PFNA FNID_TO_CLIENT_PFNA_KERNEL

| Definition at line 983 of file inc/user.h.

#define FNID_TO_CLIENT_PFNA_CLIENT FNID_TO_CLIENT_PFNA_KERNEL

| Definition at line 972 of file inc/user.h. Referenced by MapClientNeuterToClientPfn(), and MapServerToClientPfn().

#define FNID_TO_CLIENT_PFNA_KERNEL | ( | s |  | ) | (*(((KERNEL_ULONG_PTR *)&gpsi->apfnClientA) + (s - FNID_START)))

| Definition at line 980 of file inc/user.h. Referenced by MapClientNeuterToClientPfn(), and SendMessageWorker().

#define FNID_TO_CLIENT_PFNW FNID_TO_CLIENT_PFNW_KERNEL

| Definition at line 984 of file inc/user.h.

#define FNID_TO_CLIENT_PFNW_CLIENT FNID_TO_CLIENT_PFNW_KERNEL

| Definition at line 973 of file inc/user.h. Referenced by MapClientNeuterToClientPfn(), and MapServerToClientPfn().

#define FNID_TO_CLIENT_PFNW_KERNEL | ( | s |  | ) | (*(((KERNEL_ULONG_PTR *)&gpsi->apfnClientW) + (s - FNID_START)))

| Definition at line 981 of file inc/user.h. Referenced by MapClientNeuterToClientPfn(), and SendMessageWorker().

#define FNID_TO_CLIENT_PFNWORKER | ( | s |  | ) | (*(((KERNEL_ULONG_PTR *)&gpsi->apfnClientWorker) + (s - FNID_CONTROLSTART)))

| Definition at line 974 of file inc/user.h.

#define FNID_TOOLTIP 0x000002B4

| Definition at line 876 of file inc/user.h.

#define FNID_WNDPROCEND 0x0000029E

| Definition at line 848 of file inc/user.h.

#define FNID_WNDPROCSTART 0x0000029A

| Definition at line 840 of file inc/user.h.

#define FTrueVis | ( | pwnd |  | ) | (_IsWindowVisible(pwnd))

| Definition at line 2718 of file inc/user.h.

#define FW_16BIT 1

| Definition at line 785 of file inc/user.h. Referenced by _FindWindowEx(), and WOWFindWindow().

#define FW_32BIT 2

| Definition at line 786 of file inc/user.h. Referenced by _FindWindowEx(), and FindWinHelpWindow().

#define FW_BOTH 0

| Definition at line 784 of file inc/user.h. Referenced by _FindWindowEx(), FindWindow(), and FindWindowEx().

#define FWINABLE | (

)

TEST_SRVIF(SRVIF_WINEVENTHOOKS)

| Definition at line 1337 of file inc/user.h.

#define GET_X_LPARAM | ( | lp |  | ) | ((int)(short)LOWORD(lp))

| Definition at line 210 of file inc/user.h.

#define GET_Y_LPARAM | ( | lp |  | ) | ((int)(short)HIWORD(lp))

| Definition at line 214 of file inc/user.h.

#define GetChildParent | ( | pwnd |  | ) | (TestwndChild(pwnd) ? pwnd->spwndParent : (PWND)NULL)

| Definition at line 2708 of file inc/user.h.

#define GetClientInfo | (

)

((PCLIENTINFO)((NtCurrentTebShared())->Win32ClientInfo))

| Definition at line 221 of file inc/user.h.

#define GETFNID | ( | pwnd |  | ) | ((pwnd)->fnid & ~FNID_STATUS_BITS)

| Definition at line 901 of file inc/user.h.

#define GetFullScreen | ( | pwnd |  | ) | (TestWF(pwnd, WFFULLSCREENMASK))

| Definition at line 2713 of file inc/user.h.

#define GETGPSIMBPSTR | ( | u |  | ) | (LPWSTR) (gpsi->MBStrings[(u)].szName)

| Definition at line 1341 of file inc/user.h.

#define GETPDESK | ( | p |  | ) | _GETPDESK(p)

| Definition at line 1625 of file inc/user.h.

#define GETPPI | ( | p |  | ) | _GETPPI(p)

| Definition at line 1626 of file inc/user.h.

#define GETPTI | ( | p |  | ) | _GETPTI(p)

| Definition at line 1624 of file inc/user.h.

#define GETPWNDPPI | ( | p |  | ) | (GETPTI(p)->ppi)

| Definition at line 1630 of file inc/user.h.

#define GetWindowCreator | ( | pwnd |  | ) | (TestwndChild(pwnd) ? pwnd->spwndParent : pwnd->spwndOwner)

| Definition at line 2709 of file inc/user.h.

#define GHOSTCLASS MAKEINTATOM(0x8007)

| Definition at line 321 of file inc/user.h.

#define GRC_FULLSCREEN 0x0004

| Definition at line 3138 of file inc/user.h.

#define GRC_MINWNDS 0x0002

| Definition at line 3137 of file inc/user.h.

#define GRC_SCROLLS 0x0001

| Definition at line 3136 of file inc/user.h.

#define GRECT_CLIENT 0x0001

| Definition at line 3548 of file inc/user.h.

#define GRECT_CLIENTCOORDS 0x0010

| Definition at line 3552 of file inc/user.h.

#define GRECT_COORDMASK 0x0070

| Definition at line 3555 of file inc/user.h.

#define GRECT_PARENTCOORDS 0x0040

| Definition at line 3554 of file inc/user.h.

#define GRECT_RECTMASK 0x0003

| Definition at line 3550 of file inc/user.h.

#define GRECT_WINDOW 0x0002

| Definition at line 3549 of file inc/user.h.

#define GRECT_WINDOWCOORDS 0x0020

| Definition at line 3553 of file inc/user.h.

#define GWL_CONVCONTEXT GWLP_PCI + sizeof(PVOID)

| Definition at line 725 of file inc/user.h.

#define GWL_CONVSTATE GWL_CONVCONTEXT + sizeof(CONVCONTEXT)

| Definition at line 726 of file inc/user.h.

#define GWLP_CHINST GWLP_SHINST + sizeof(HANDLE)

| Definition at line 728 of file inc/user.h.

#define GWLP_INSTANCE_INFO 0

| Definition at line 719 of file inc/user.h.

#define GWLP_MDIDATA (FIELD_OFFSET(MDIWND, pmdi) - sizeof(WND))

| Definition at line 2996 of file inc/user.h. Referenced by MDIClientWndProcWorker(), and xxxSetWindowLongPtr().

#define GWLP_PCI 0

| Definition at line 724 of file inc/user.h.

#define GWLP_PSI 0

| Definition at line 736 of file inc/user.h.

#define GWLP_PSII 0

| Definition at line 740 of file inc/user.h.

#define GWLP_SHINST GWL_CONVSTATE + sizeof(LONG)

| Definition at line 727 of file inc/user.h.

#define HANDLEF_DESTROY 0x01

| Definition at line 1496 of file inc/user.h.

#define HANDLEF_GRANTED 0x20

| Definition at line 1499 of file inc/user.h.

#define HANDLEF_INDESTROY 0x02

| Definition at line 1497 of file inc/user.h.

#define HANDLEF_MARKED_OK 0x10

| Definition at line 1498 of file inc/user.h.

#define HANDLEF_POOL 0x40

| Definition at line 1500 of file inc/user.h. Referenced by HMFreeObject(), and xxxCreateWindowStation().

#define HANDLEF_VALID 0x7F

| Definition at line 1501 of file inc/user.h.

#define HDCBITS | (

)

gpDispInfo->hdcBits

| Definition at line 2226 of file inc/user.h.

#define HEVENT_REMOVEME ((HANDLE)IntToPtr( 0xFFFFFFFF ))

| Definition at line 225 of file inc/user.h.

#define HF_ANSI 0x0002

| Definition at line 2096 of file inc/user.h.

#define HF_DESTROYED 0x0080

| Definition at line 2102 of file inc/user.h.

#define HF_GLOBAL 0x0001

| Definition at line 2095 of file inc/user.h.

#define HF_HOOKFAULTED 0x0010

| Definition at line 2099 of file inc/user.h.

#define HF_HUNG 0x0008

| Definition at line 2098 of file inc/user.h.

#define HF_NEEDHC_SKIP 0x0004

| Definition at line 2097 of file inc/user.h.

#define HF_NOPLAYBACKDELAY 0x0020

| Definition at line 2100 of file inc/user.h.

#define HF_WX86KNOWNDLL 0x0040

| Definition at line 2101 of file inc/user.h.

#define HISHORT | ( | l |  | ) | ((short)HIWORD(l))

| Definition at line 207 of file inc/user.h. Referenced by MoveRect(), SizeRect(), xxxMoveSize(), xxxMS_TrackMove(), and xxxTM_MoveDragRect().

#define HMCatObjectFromHandle | ( | h |  | ) | _HMObjectFromHandle(h)

| Definition at line 1587 of file inc/user.h.

#define HMINDEXBITS 0x0000FFFF

| Definition at line 1531 of file inc/user.h.

#define HMIndexFromHandle | ( | h |  | ) | ((ULONG)(((ULONG_PTR)(h)) & HMINDEXBITS))

| Definition at line 1540 of file inc/user.h.

#define HMIsMarkDestroy | ( | p |  | ) | (HMPheFromObject(p)->bFlags & HANDLEF_DESTROY)

| Definition at line 1546 of file inc/user.h.

#define HMObjectFromHandle | ( | h |  | ) | _HMObjectFromHandle(h)

| Definition at line 1586 of file inc/user.h.

#define HMObjectType | ( | p |  | ) | (HMPheFromObject(p)->bType)

| Definition at line 1544 of file inc/user.h.

#define HMPheFromObject | ( | p |  | ) | _HMPheFromObject(p)

| Definition at line 1585 of file inc/user.h.

#define HMRevalidateCatHandle | ( | h |  | ) | HMValidateCatHandleNoSecure(h, TYPE_GENERIC)

| Definition at line 1552 of file inc/user.h. Referenced by xxxCalcValidRects().

#define HMRevalidateHandle | ( | h |  | ) | HMValidateHandleNoSecure(h, TYPE_GENERIC)

| Definition at line 1551 of file inc/user.h.

#define HMRevalidateHandleNoRip | ( | h |  | ) | HMValidateHandleNoRip(h, TYPE_GENERIC)

| Definition at line 1554 of file inc/user.h.

#define HMUNIQBITS 0xFFFF

| Definition at line 1533 of file inc/user.h.

#define HMUniqFromHandle | ( | h |  | ) | ((WORD)((((ULONG_PTR)h) >> HMUNIQSHIFT) & HMUNIQBITS))

| Definition at line 1543 of file inc/user.h.

#define HMUNIQSHIFT 16

| Definition at line 1532 of file inc/user.h.

#define HRGN_EMPTY ((HRGN)0)

| Definition at line 3156 of file inc/user.h.

#define HRGN_FULL ((HRGN)1)

| Definition at line 3157 of file inc/user.h.

#define HRGN_MONITOR ((HRGN)2)

| Definition at line 3158 of file inc/user.h.

#define HRGN_SPECIAL_LAST HRGN_MONITOR

| Definition at line 3159 of file inc/user.h.

#define HW | ( | pwnd |  | ) | _HW(pwnd)

| Definition at line 1590 of file inc/user.h.

#define HWCCX | ( | ccxPwnd |  | ) | _HW(ccxPwnd)

| Definition at line 1591 of file inc/user.h. Referenced by _GetComboBoxInfo().

#define HWq | ( | pwnd |  | ) | _HWq(pwnd)

| Definition at line 1592 of file inc/user.h.

#define ICLS_BUTTON 0

| Definition at line 368 of file inc/user.h.

#define ICLS_COMBOBOX 5

| Definition at line 373 of file inc/user.h.

#define ICLS_COMBOLISTBOX 7

| Definition at line 376 of file inc/user.h.

#define ICLS_CTL_MAX 16

| Definition at line 386 of file inc/user.h.

#define ICLS_DDEML16BIT 10

| Definition at line 379 of file inc/user.h.

#define ICLS_DDEMLCLIENTA 11

| Definition at line 380 of file inc/user.h.

#define ICLS_DDEMLCLIENTW 12

| Definition at line 381 of file inc/user.h.

#define ICLS_DDEMLEVENT 8

| Definition at line 377 of file inc/user.h.

#define ICLS_DDEMLMOTHER 9

| Definition at line 378 of file inc/user.h.

#define ICLS_DDEMLSERVERA 13

| Definition at line 382 of file inc/user.h.

#define ICLS_DDEMLSERVERW 14

| Definition at line 383 of file inc/user.h.

#define ICLS_DESKTOP 16

| Definition at line 389 of file inc/user.h.

#define ICLS_DIALOG 17

| Definition at line 390 of file inc/user.h.

#define ICLS_EDIT 1

| Definition at line 369 of file inc/user.h.

#define ICLS_ICONTITLE 20

| Definition at line 393 of file inc/user.h.

#define ICLS_IME 15

| Definition at line 384 of file inc/user.h.

#define ICLS_LISTBOX 3

| Definition at line 371 of file inc/user.h.

#define ICLS_MAX 22

| Definition at line 395 of file inc/user.h.

#define ICLS_MDICLIENT 6

| Definition at line 375 of file inc/user.h.

#define ICLS_MENU 18

| Definition at line 391 of file inc/user.h.

#define ICLS_SCROLLBAR 4

| Definition at line 372 of file inc/user.h.

#define ICLS_STATIC 2

| Definition at line 370 of file inc/user.h.

#define ICLS_SWITCH 19

| Definition at line 392 of file inc/user.h.

#define ICLS_TOOLTIP 21

| Definition at line 394 of file inc/user.h.

#define ICON_PROP_NAME L"SysIC"

| Definition at line 164 of file inc/user.h.

#define ICONTITLECLASS MAKEINTATOM(0x8004)

| Definition at line 318 of file inc/user.h.

#define ID_CLOSEMENU 0x20

| Definition at line 2733 of file inc/user.h.

#define ID_DIALOGSYSMENU 0x30

| Definition at line 2735 of file inc/user.h.

#define ID_HELPMENU 4

| Definition at line 2814 of file inc/user.h.

#define ID_HSCROLLMENU 0x40

| Definition at line 2736 of file inc/user.h.

#define ID_SYSMENU 0x10

| Definition at line 2732 of file inc/user.h.

#define ID_VSCROLLMENU 0x50

| Definition at line 2737 of file inc/user.h.

#define IDSYS_CARET 0x0000FFFFL

| Definition at line 341 of file inc/user.h.

#define IDSYS_FADE 0x0000FFF6L

| Definition at line 328 of file inc/user.h. Referenced by StartFade(), StopFade(), and xxxSystemTimerProc().

#define IDSYS_FLASHWND 0x0000FFF8L

| Definition at line 330 of file inc/user.h.

#define IDSYS_LAYER 0x0000FFF5L

| Definition at line 327 of file inc/user.h. Referenced by DecrementRedirectedCount(), IncrementRedirectedCount(), and xxxSystemTimerProc().

#define IDSYS_LBSEARCH 0x0000FFFCL

| Definition at line 335 of file inc/user.h.

#define IDSYS_MNANIMATE 0x0000FFFBL

| Definition at line 333 of file inc/user.h.

#define IDSYS_MNAUTODISMISS 0x0000FFF9L

| Definition at line 331 of file inc/user.h.

#define IDSYS_MNDOWN MFMWFP_DOWNARROW /* 0xFFFFFFFC */

| Definition at line 334 of file inc/user.h.

#define IDSYS_MNHIDE 0x0000FFFFL

| Definition at line 340 of file inc/user.h.

#define IDSYS_MNSHOW 0x0000FFFEL

| Definition at line 338 of file inc/user.h.

#define IDSYS_MNUP MFMWFP_UPARROW /* 0xFFFFFFFD */

| Definition at line 336 of file inc/user.h.

#define IDSYS_MOUSEHOVER 0x0000FFFAL

| Definition at line 332 of file inc/user.h.

#define IDSYS_SCROLL 0x0000FFFEL

| Definition at line 339 of file inc/user.h.

#define IDSYS_STANIMATE 0x0000FFFDL

| Definition at line 337 of file inc/user.h.

#define IDSYS_WNDTRACKING 0x0000FFF7L

| Definition at line 329 of file inc/user.h.

#define IMM_MAGIC_CALLER_ID (0x19650412)

| Definition at line 644 of file inc/user.h.

#define INFOCLASS MAKEINTATOM(0x8005)

| Definition at line 319 of file inc/user.h.

#define IS_DBCS_CHARSET | ( | charset |  | ) |

Value:

    ((charset) == SHIFTJIS_CHARSET || \
                 (charset) == HANGEUL_CHARSET || \
                 (charset) == CHINESEBIG5_CHARSET || \
                 (charset) == GB2312_CHARSET)

Definition at line 634 of file inc/user.h.

#define IS_DBCS_CODEPAGE | ( | wCodePage |  | ) |

Value:

    ((wCodePage) == CP_JAPANESE || \
                 (wCodePage) == CP_KOREAN || \
                 (wCodePage) == CP_CHINESE_TRAD || \
                 (wCodePage) == CP_CHINESE_SIMP)

Definition at line 628 of file inc/user.h.

Referenced by xxxInternalToUnicode().

#define IS_DBCS_ENABLED | (

)

(TEST_SRVIF(SRVIF_DBCS))

| Definition at line 611 of file inc/user.h.

#define IS_DBCS_HKL | (

)

(IS_ANY_DBCS_CODEPAGE(THREAD_CODEPAGE()))

| Definition at line 619 of file inc/user.h.

#define IS_DBCS_INPUT | (

)

(IS_DBCS_ENABLED() || IS_DBCS_HKL())

| Definition at line 620 of file inc/user.h.

#define IS_DBCS_MESSAGE | ( | DbcsChar |  | ) | (((DWORD)(DbcsChar)) & 0x0000FF00)

| Definition at line 592 of file inc/user.h.

#define IS_IME_ENABLED | (

)

_IS_IME_ENABLED()

| Definition at line 616 of file inc/user.h.

#define IS_JPN_1BYTE_KATAKANA | ( | c |  | ) | ((c) >= 0xa1 && (c) <= 0xdf)

| Definition at line 640 of file inc/user.h. Referenced by IsDbcsExemptionForHighAnsi().

#define IS_MIDEAST_ENABLED | (

)

(TEST_SRVIF(SRVIF_MIDEAST))

| Definition at line 648 of file inc/user.h.

#define IS_PTR | ( | p |  | ) | ((((ULONG_PTR)(p)) & ~MAXUSHORT) != 0)

| Definition at line 441 of file inc/user.h.

#define ISBSTEXTOROD | ( | pwnd |  | ) | (!TestWF(pwnd, BFBITMAP) && !TestWF(pwnd, BFICON))

| Definition at line 2596 of file inc/user.h. Referenced by ButtonWndProcWorker().

#define ISCPDTAG | ( | x |  | ) | (((ULONG_PTR)(x) & CPDHANDLE_HI) == CPDHANDLE_HI)

| Definition at line 1649 of file inc/user.h.

#define ISTS | (

)

(!!(USER_SHARED_DATA->SuiteMask & (1 << TerminalServer)))

| Definition at line 3600 of file inc/user.h. Referenced by _EndTask(), ChangeForegroundKeyboardTable(), CommonCreateWindowStation(), DecVisWindows(), DestroyProcessesObjects(), HardErrorHandler(), IncVisWindows(), MarkThreadsObjects(), NtUserCtxDisplayIOCtl(), NtUserRemoteConnect(), NtUserRemoteRedrawRectangle(), NtUserRemoteRedrawScreen(), NtUserRemoteStopScreenUpdates(), ReadLayoutFile(), RegisterPerUserKeyboardIndicators(), RemoteLogoff(), RemoteNtSecurity(), RemotePassthruDisable(), RemoteShadowCleanup(), RemoteShadowStart(), RemoteThinwireStats(), ServiceMessageBox(), StartDeviceRead(), ThreadShutdownNotify(), UserClientDllInitialize(), UserClientShutdown(), UserHardErrorEx(), UserInitialize(), UserServerDllInitialization(), xxxButtonEvent(), xxxDesktopThread(), xxxHardErrorControl(), xxxMakeWindowForegroundWithState(), xxxRemoteDisconnect(), xxxRemotePassthruEnable(), xxxRemoteReconnect(), xxxRemoteShadowSetup(), xxxRemoteShadowStop(), and ZombieCursor().

#define LISTBOXCODE 0x83

| Definition at line 356 of file inc/user.h.

#define LOBYTE | ( | w |  | ) | ((BYTE)((w) & 0x00FF))

| Definition at line 2693 of file inc/user.h.

#define LOSHORT | ( | l |  | ) | ((short)LOWORD(l))

| Definition at line 206 of file inc/user.h. Referenced by MoveRect(), SizeRect(), xxxMoveSize(), xxxMS_TrackMove(), and xxxTM_MoveDragRect().

#define LTUPFLAG 0x0001

| Definition at line 2841 of file inc/user.h.

#define MAKE_CPDHANDLE | ( | h |  | ) | (HMIndexFromHandle(h) | CPDHANDLE_HI)

| Definition at line 1648 of file inc/user.h.

#define MAKE_IR_DBCSCHAR | ( | DbcsChar |  | ) |

Value:

    (IS_DBCS_MESSAGE((DbcsChar)) ?                                     \
                (MAKEWPARAM(MAKEWORD(HIBYTE((DbcsChar)),LOBYTE((DbcsChar))),0)) : \
                ((WPARAM)((DbcsChar) & 0x00FF))                                   \
            )

Definition at line 597 of file inc/user.h.

#define MAKE_WPARAM_DBCSCHAR | ( | DbcsChar |  | ) |

Value:

    (IS_DBCS_MESSAGE((DbcsChar)) ?                                     \
                (MAKEWPARAM(MAKEWORD(HIBYTE((DbcsChar)),LOBYTE((DbcsChar))),0)) : \
                ((WPARAM)((DbcsChar) & 0x00FF))                                   \
            )

Definition at line 603 of file inc/user.h.

#define MapKernelClientFnToClientFn | ( | lpfnWndProc |  | ) | (lpfnWndProc)

| Definition at line 976 of file inc/user.h. Referenced by DispatchMessageWorker(), GetWindowData(), and SendMessageWorker().

#define MaskWF | ( | flag |  | ) | ((WORD)( (HIBYTE(flag) & 1) ? LOBYTE(flag) << 8 : LOBYTE(flag)))

| Definition at line 2698 of file inc/user.h.

#define MAX_MB_STRINGS 11

| Definition at line 263 of file inc/user.h.

#define MAX_SEB_STYLES 11 /* number of SEB_* values */

| Definition at line 3227 of file inc/user.h.

#define MAX_SESSION_PATH 256

| Definition at line 403 of file inc/user.h.

#define MDICLIENTCODE 0x86

| Definition at line 359 of file inc/user.h.

#define MENUCHILDSYSMENU TEXT('-') /* Hyphen */

| Definition at line 2908 of file inc/user.h.

#define MENUCLASS MAKEINTATOM(0x8000) /* Public Knowledge */

| Definition at line 322 of file inc/user.h.

#define MENUSYSMENU TEXT(' ') /* Space character */

| Definition at line 2907 of file inc/user.h.

#define MF_ALLSTATE 0x00FF

| Definition at line 2910 of file inc/user.h.

#define MF_MAINMENU 0xFFFF

| Definition at line 2911 of file inc/user.h.

#define MFAPPSYSMENU 0x00000100 /* Set on (sub)menu we return to the app via GetSystemMenu */

| Definition at line 701 of file inc/user.h. Referenced by xxxEnableMenuItem(), and xxxGetSystemMenu().

#define MFDESKTOP 0x00000040 /* Set on the desktop menu AND its submenus */

| Definition at line 699 of file inc/user.h.

#define MFINACTIVE 0x00000010

| Definition at line 697 of file inc/user.h.

#define MFISPOPUP 0x00000001

| Definition at line 693 of file inc/user.h.

#define MFLAST 0x00000100

| Definition at line 702 of file inc/user.h.

#define MFMULTIROW 0x00000002

| Definition at line 694 of file inc/user.h.

#define MFMWFP_ALTMENU 0xFFFFFFFB

| Definition at line 2918 of file inc/user.h.

#define MFMWFP_DOWNARROW 0xFFFFFFFC /* Warning: Also used to define IDSYS_MNDOWN */

| Definition at line 2916 of file inc/user.h.

#define MFMWFP_FIRSTITEM 0

| Definition at line 2919 of file inc/user.h.

#define MFMWFP_MAINMENU 0x0000FFFF

| Definition at line 2913 of file inc/user.h.

#define MFMWFP_MINVALID 0xFFFFFFFC

| Definition at line 2917 of file inc/user.h.

#define MFMWFP_NOITEM 0xFFFFFFFF

| Definition at line 2914 of file inc/user.h.

#define MFMWFP_OFFMENU 0

| Definition at line 2912 of file inc/user.h.

#define MFMWFP_UPARROW 0xFFFFFFFD /* Warning: Also used to define IDSYS_MNUP */

| Definition at line 2915 of file inc/user.h.

#define MFRTL 0x00000020

| Definition at line 698 of file inc/user.h.

#define MFSYSMENU 0x00000080 /* Set on desktop menu but NOT on its submenus */

| Definition at line 700 of file inc/user.h.

#define MFUNDERLINE 0x00000004

| Definition at line 695 of file inc/user.h.

#define MFWINDOWDC 0x00000008 /* Window DC vs Client area DC when drawing*/

| Definition at line 696 of file inc/user.h.

#define MNF_DONTSKIPSEPARATORS 0x0001

| Definition at line 2833 of file inc/user.h.

#define MONF_PALETTEDISPLAY 0x02

| Definition at line 2143 of file inc/user.h.

#define MONF_VISIBLE 0x01

| Definition at line 2142 of file inc/user.h.

#define MSA_ATBOTTOM 3

| Definition at line 2780 of file inc/user.h.

#define MSA_ATTOP 2

| Definition at line 2779 of file inc/user.h.

#define MSA_OFF 0

| Definition at line 2777 of file inc/user.h.

#define MSA_ON 1

| Definition at line 2778 of file inc/user.h.

#define MSGFLAG_DDE_MID_THUNK 0x80000000

| Definition at line 2344 of file inc/user.h.

#define MSGFLAG_DDE_SPECIAL_SEND 0x40000000

| Definition at line 2345 of file inc/user.h.

#define MSGFLAG_MASK 0xFFFE0000

| Definition at line 2342 of file inc/user.h.

#define MSGFLAG_SPECIAL_THUNK 0x10000000

| Definition at line 2346 of file inc/user.h.

#define MSGFLAG_WOW_RESERVED 0x00010000

| Definition at line 2343 of file inc/user.h.

#define MultDiv | ( | x,
|  | y,
|  | z |  | ) | (((INT)(x) * (INT)(y) + (INT)(z) / 2) / (INT)(z))

| Definition at line 674 of file inc/user.h.

#define NCHARS 256

| Definition at line 1148 of file inc/user.h.

#define NCTRLS 0x20

| Definition at line 1149 of file inc/user.h.

#define NEEDSPAINT | ( | pwnd |  | ) | (pwnd->hrgnUpdate != NULL || TestWF(pwnd, WFINTERNALPAINT))

| Definition at line 1862 of file inc/user.h.

#define NUM_BUTTON_STATES 4

| Definition at line 258 of file inc/user.h.

#define NUM_BUTTON_TYPES 3

| Definition at line 257 of file inc/user.h.

#define OBI_3STATE 82

| Definition at line 1128 of file inc/user.h.

#define OBI_3STATE_C 83

| Definition at line 1129 of file inc/user.h.

#define OBI_3STATE_CD 85

| Definition at line 1131 of file inc/user.h.

#define OBI_3STATE_CDI 86

| Definition at line 1132 of file inc/user.h.

#define OBI_3STATE_D 84

| Definition at line 1130 of file inc/user.h.

#define OBI_CAPBTNS 39

| Definition at line 1085 of file inc/user.h.

#define OBI_CAPBTNS_I 40

| Definition at line 1086 of file inc/user.h.

#define OBI_CAPCACHE1 29

| Definition at line 1075 of file inc/user.h.

#define OBI_CAPCACHE1_I 30

| Definition at line 1076 of file inc/user.h.

#define OBI_CAPCACHE2 31

| Definition at line 1077 of file inc/user.h.

#define OBI_CAPCACHE2_I 32

| Definition at line 1078 of file inc/user.h.

#define OBI_CAPCACHE3 33

| Definition at line 1079 of file inc/user.h.

#define OBI_CAPCACHE3_I 34

| Definition at line 1080 of file inc/user.h.

#define OBI_CAPCACHE4 35

| Definition at line 1081 of file inc/user.h.

#define OBI_CAPCACHE4_I 36

| Definition at line 1082 of file inc/user.h.

#define OBI_CAPCACHE5 37

| Definition at line 1083 of file inc/user.h.

#define OBI_CAPCACHE5_I 38

| Definition at line 1084 of file inc/user.h.

#define OBI_CHECK 72

| Definition at line 1118 of file inc/user.h.

#define OBI_CHECK_C 73

| Definition at line 1119 of file inc/user.h.

#define OBI_CHECK_CD 75

| Definition at line 1121 of file inc/user.h.

#define OBI_CHECK_CDI 76

| Definition at line 1122 of file inc/user.h.

#define OBI_CHECK_D 74

| Definition at line 1120 of file inc/user.h.

#define OBI_CLOSE 0

| Definition at line 1046 of file inc/user.h.

#define OBI_CLOSE_D 1

| Definition at line 1047 of file inc/user.h.

#define OBI_CLOSE_H 2

| Definition at line 1048 of file inc/user.h.

#define OBI_CLOSE_I 3

| Definition at line 1049 of file inc/user.h.

#define OBI_CLOSE_MBAR 18

| Definition at line 1064 of file inc/user.h.

#define OBI_CLOSE_MBAR_D 19

| Definition at line 1065 of file inc/user.h.

#define OBI_CLOSE_MBAR_H 20

| Definition at line 1066 of file inc/user.h.

#define OBI_CLOSE_MBAR_I 21

| Definition at line 1067 of file inc/user.h.

#define OBI_CLOSE_PAL 41

| Definition at line 1087 of file inc/user.h.

#define OBI_CLOSE_PAL_D 42

| Definition at line 1088 of file inc/user.h.

#define OBI_CLOSE_PAL_H 43

| Definition at line 1089 of file inc/user.h.

#define OBI_CLOSE_PAL_I 44

| Definition at line 1090 of file inc/user.h.

#define OBI_CLOSE_POPUP 87

| Definition at line 1134 of file inc/user.h.

#define OBI_COUNT 93

| Definition at line 1140 of file inc/user.h.

#define OBI_DNARROW 50

| Definition at line 1096 of file inc/user.h.

#define OBI_DNARROW_D 51

| Definition at line 1097 of file inc/user.h.

#define OBI_DNARROW_H 52

| Definition at line 1098 of file inc/user.h.

#define OBI_DNARROW_I 53

| Definition at line 1099 of file inc/user.h.

#define OBI_HELP 11

| Definition at line 1057 of file inc/user.h.

#define OBI_HELP_D 12

| Definition at line 1058 of file inc/user.h.

#define OBI_HELP_H 13

| Definition at line 1059 of file inc/user.h.

#define OBI_LFARROW 58

| Definition at line 1104 of file inc/user.h.

#define OBI_LFARROW_D 59

| Definition at line 1105 of file inc/user.h.

#define OBI_LFARROW_H 60

| Definition at line 1106 of file inc/user.h.

#define OBI_LFARROW_I 61

| Definition at line 1107 of file inc/user.h.

#define OBI_MENUARROW 62

| Definition at line 1108 of file inc/user.h.

#define OBI_MENUARROW_L 92

| Definition at line 1139 of file inc/user.h.

#define OBI_MENUARROWDOWN 68

| Definition at line 1114 of file inc/user.h.

#define OBI_MENUARROWDOWN_H 69

| Definition at line 1115 of file inc/user.h.

#define OBI_MENUARROWDOWN_I 70

| Definition at line 1116 of file inc/user.h.

#define OBI_MENUARROWUP 65

| Definition at line 1111 of file inc/user.h.

#define OBI_MENUARROWUP_H 66

| Definition at line 1112 of file inc/user.h.

#define OBI_MENUARROWUP_I 67

| Definition at line 1113 of file inc/user.h.

#define OBI_MENUBULLET 64

| Definition at line 1110 of file inc/user.h.

#define OBI_MENUCHECK 63

| Definition at line 1109 of file inc/user.h.

#define OBI_NCGRIP 45

| Definition at line 1091 of file inc/user.h.

#define OBI_NCGRIP_L 91

| Definition at line 1138 of file inc/user.h.

#define OBI_POPUPFIRST 87

| Definition at line 1133 of file inc/user.h.

#define OBI_RADIO 77

| Definition at line 1123 of file inc/user.h.

#define OBI_RADIO_C 78

| Definition at line 1124 of file inc/user.h.

#define OBI_RADIO_CD 80

| Definition at line 1126 of file inc/user.h.

#define OBI_RADIO_CDI 81

| Definition at line 1127 of file inc/user.h.

#define OBI_RADIO_D 79

| Definition at line 1125 of file inc/user.h.

#define OBI_RADIOMASK 71

| Definition at line 1117 of file inc/user.h.

#define OBI_REDUCE 4

| Definition at line 1050 of file inc/user.h.

#define OBI_REDUCE_D 5

| Definition at line 1051 of file inc/user.h.

#define OBI_REDUCE_H 6

| Definition at line 1052 of file inc/user.h.

#define OBI_REDUCE_I 7

| Definition at line 1053 of file inc/user.h.

#define OBI_REDUCE_MBAR 22

| Definition at line 1068 of file inc/user.h.

#define OBI_REDUCE_MBAR_D 23

| Definition at line 1069 of file inc/user.h.

#define OBI_REDUCE_MBAR_H 24

| Definition at line 1070 of file inc/user.h.

#define OBI_REDUCE_MBAR_I 25

| Definition at line 1071 of file inc/user.h.

#define OBI_REDUCE_POPUP 90

| Definition at line 1137 of file inc/user.h.

#define OBI_RESTORE 8

| Definition at line 1054 of file inc/user.h.

#define OBI_RESTORE_D 9

| Definition at line 1055 of file inc/user.h.

#define OBI_RESTORE_H 10

| Definition at line 1056 of file inc/user.h.

#define OBI_RESTORE_MBAR 26

| Definition at line 1072 of file inc/user.h.

#define OBI_RESTORE_MBAR_D 27

| Definition at line 1073 of file inc/user.h.

#define OBI_RESTORE_MBAR_H 28

| Definition at line 1074 of file inc/user.h.

#define OBI_RESTORE_POPUP 88

| Definition at line 1135 of file inc/user.h.

#define OBI_RGARROW 54

| Definition at line 1100 of file inc/user.h.

#define OBI_RGARROW_D 55

| Definition at line 1101 of file inc/user.h.

#define OBI_RGARROW_H 56

| Definition at line 1102 of file inc/user.h.

#define OBI_RGARROW_I 57

| Definition at line 1103 of file inc/user.h.

#define OBI_UPARROW 46

| Definition at line 1092 of file inc/user.h.

#define OBI_UPARROW_D 47

| Definition at line 1093 of file inc/user.h.

#define OBI_UPARROW_H 48

| Definition at line 1094 of file inc/user.h.

#define OBI_UPARROW_I 49

| Definition at line 1095 of file inc/user.h.

#define OBI_ZOOM 14

| Definition at line 1060 of file inc/user.h.

#define OBI_ZOOM_D 15

| Definition at line 1061 of file inc/user.h.

#define OBI_ZOOM_H 16

| Definition at line 1062 of file inc/user.h.

#define OBI_ZOOM_I 17

| Definition at line 1063 of file inc/user.h.

#define OBI_ZOOM_POPUP 89

| Definition at line 1136 of file inc/user.h.

#define OCF_DESKTOPHEAP 0x10

| Definition at line 1414 of file inc/user.h.

#define OCF_MARKPROCESS 0x04

| Definition at line 1412 of file inc/user.h.

#define OCF_PROCESSOWNED 0x02

| Definition at line 1411 of file inc/user.h.

#define OCF_SHAREDHEAP 0x40

| Definition at line 1416 of file inc/user.h.

#define OCF_THREADOWNED 0x01

| Definition at line 1410 of file inc/user.h.

#define OCF_USEPOOLIFNODESKTOP 0x20

| Definition at line 1415 of file inc/user.h.

#define OCF_USEPOOLQUOTA 0x08

| Definition at line 1413 of file inc/user.h.

#define OCF_VARIABLESIZE 0

| Definition at line 1420 of file inc/user.h.

#define PATTERN (DWORD)0x00F00000

| Definition at line 248 of file inc/user.h.

#define PDLG | ( | pwnd |  | ) | (((PDIALOG)pwnd)->pdlg)

| Definition at line 2969 of file inc/user.h.

#define PICON PCURSOR

| Definition at line 2318 of file inc/user.h. Referenced by DrawIconCallBack(), NtUserGetIconInfo(), xxxPaintIconsInSwitchWindow(), and xxxRealDrawMenuItem().

#define PROCESSTERMINATETIMEOUT (90 * 1000)

| Definition at line 3659 of file inc/user.h. Referenced by GetTimeouts().

#define PROPF_INTERNAL 0x0001

| Definition at line 1804 of file inc/user.h.

#define PROPF_NOPOOL 0x0004

| Definition at line 1806 of file inc/user.h.

#define PROPF_STRING 0x0002

| Definition at line 1805 of file inc/user.h.

#define PtoH | ( | p |  | ) | _PtoH(p)

| Definition at line 1588 of file inc/user.h.

#define PtoHq | ( | p |  | ) | _PtoHq(p)

| Definition at line 1589 of file inc/user.h.

#define PTR_TO_ID | ( | p |  | ) | ((USHORT)(((ULONG_PTR)(p)) & MAXUSHORT))

| Definition at line 442 of file inc/user.h.

#define PUSIF_COMBOBOXANIMATION 0x00000004 /* Must match UPBOOLMask(SPI_GETCOMBOBOXANIMATION) */

| Definition at line 1153 of file inc/user.h.

#define PUSIF_KEYBOARDCUES 0x00000020 /* Must match UPBOOLMask(SPI_GETKEYBOARDCUES) */

| Definition at line 1155 of file inc/user.h.

#define PUSIF_LISTBOXSMOOTHSCROLLING 0x00000008 /* Must match UPBOOLMask(SPI_GETLISTBOXSMOOTHSCROLLING) */

| Definition at line 1154 of file inc/user.h.

#define PUSIF_PALETTEDISPLAY 0x00000001 /* Is the display palettized? */

| Definition at line 1151 of file inc/user.h.

#define PUSIF_SNAPTO 0x00000002 /* Is SnapTo enabled? */

| Definition at line 1152 of file inc/user.h.

#define PUSIF_UIEFFECTS 0x80000000 /* Must match UPBOOLMask(SPI_GETUIEFFECTS) */

| Definition at line 1157 of file inc/user.h.

#define PWCFromPCLS | ( | pcls |  | ) | ((PWC)((PBYTE)(pcls) + sizeof(CLS) + (pcls)->cbclsExtra))

| Definition at line 1692 of file inc/user.h.

#define QF_ACTIVATIONCHANGE (UINT)0x00040

| Definition at line 3102 of file inc/user.h.

#define QF_ACTIVEWNDTRACKING 0x00200000

| Definition at line 3125 of file inc/user.h.

#define QF_CAPTURELOCKED 0x00100000

| Definition at line 3124 of file inc/user.h.

#define QF_DIALOGACTIVE (UINT)0x04000

| Definition at line 3121 of file inc/user.h.

#define QF_EVENTDEACTIVATEREMOVED (UINT)0x08000

| Definition at line 3122 of file inc/user.h.

#define QF_FF10STATUS (UINT)0x00010

| Definition at line 3100 of file inc/user.h.

#define QF_FMENUSTATUS (UINT)0x00008

| Definition at line 3099 of file inc/user.h.

#define QF_FMENUSTATUSBREAK (UINT)0x00004

| Definition at line 3098 of file inc/user.h.

#define QF_FOCUSNULLSINCEACTIVE (UINT)0x00800

| Definition at line 3120 of file inc/user.h.

#define QF_INDESTROY (UINT)0x00200

| Definition at line 3118 of file inc/user.h.

#define QF_KEYSTATERESET (UINT)0x00100

| Definition at line 3117 of file inc/user.h.

#define QF_LOCKNOREMOVE (UINT)0x00400

| Definition at line 3119 of file inc/user.h.

#define QF_MOUSEMOVED (UINT)0x00020

| Definition at line 3101 of file inc/user.h.

#define QF_TABSWITCHING (UINT)0x00080

| Definition at line 3111 of file inc/user.h.

#define QF_UPDATEKEYSTATE (UINT)0x00001

| Definition at line 3096 of file inc/user.h.

#define RevalidateHmenu | ( | hmenuX |  | ) | HMValidateHandleNoRip(hmenuX, TYPE_MENU)

| Definition at line 1555 of file inc/user.h.

#define RNDFRM_BORDER 3

| Definition at line 3131 of file inc/user.h.

#define RNDFRM_CORNER 10

| Definition at line 3130 of file inc/user.h.

#define RTDNFLAG 0x0002

| Definition at line 2842 of file inc/user.h.

#define RTLMENU HMENU

| Definition at line 3275 of file inc/user.h.

#define SBFSIZEBOX 0x0C08

| Definition at line 2647 of file inc/user.h.

#define SBFSIZEBOXBOTTOMRIGHT 0x0C04

| Definition at line 2646 of file inc/user.h.

#define SBFSIZEBOXTOPLEFT 0x0C02

| Definition at line 2645 of file inc/user.h.

#define SBFSIZEGRIP 0x0C10

| Definition at line 2648 of file inc/user.h.

#define SCROLLBARCODE 0x84

| Definition at line 357 of file inc/user.h.

#define SEB_ABORT 2 /* Button with "&Abort" */

| Definition at line 3235 of file inc/user.h.

#define SEB_CANCEL 1 /* Button with "Cancel" */

| Definition at line 3234 of file inc/user.h.

#define SEB_CLOSE 7 /* Button with "&Close" */

| Definition at line 3240 of file inc/user.h.

#define SEB_CONTINUE 10 /* Button with "&Continue" */

| Definition at line 3243 of file inc/user.h.

#define SEB_DEFBUTTON 0x8000 /* Mask to make this button default */

| Definition at line 3245 of file inc/user.h.

#define SEB_HELP 8 /* Button with "&Help" */

| Definition at line 3241 of file inc/user.h.

#define SEB_IGNORE 4 /* Button with "&Ignore" */

| Definition at line 3237 of file inc/user.h.

#define SEB_NO 6 /* Button with "&No" */

| Definition at line 3239 of file inc/user.h.

#define SEB_OK 0 /* Button with "OK". */

| Definition at line 3233 of file inc/user.h.

#define SEB_RETRY 3 /* Button with "&Retry" */

| Definition at line 3236 of file inc/user.h.

#define SEB_TRYAGAIN 9 /* Button with "&Try Again" */

| Definition at line 3242 of file inc/user.h.

#define SEB_YES 5 /* Button with "&Yes" */

| Definition at line 3238 of file inc/user.h.

#define SESSION_ROOT L"\\Sessions"

| Definition at line 404 of file inc/user.h.

#define SET_OR_CLEAR_PUSIF | ( | f,
|  | fSet |  | ) | SET_OR_CLEAR_FLAG(gpsi->PUSIFlags, f, fSet)

| Definition at line 1163 of file inc/user.h.

#define SET_OR_CLEAR_SRVIF | ( | f,
|  | fSet |  | ) | SET_OR_CLEAR_FLAG(gpsi->wSRVIFlags, f, fSet)

| Definition at line 1261 of file inc/user.h.

#define SET_PUSIF | ( | f |  | ) | SET_FLAG(gpsi->PUSIFlags, f)

| Definition at line 1161 of file inc/user.h.

#define SET_SRVIF | ( | f |  | ) | SET_FLAG(gpsi->wSRVIFlags, f)

| Definition at line 1259 of file inc/user.h.

#define SetCF | ( | hwnd,
|  | flag |  | ) | (*((BYTE *)((PWND)(hwnd))->pcls + CFOFFSET + HIBYTE(flag)) |= LOBYTE(flag))

| Definition at line 1685 of file inc/user.h.

#define SetCF2 | ( | pcls,
|  | flag |  | ) | (*((BYTE *)(pcls) + CFOFFSET + (int)HIBYTE(flag)) |= LOBYTE(flag))

| Definition at line 1689 of file inc/user.h.

#define SetFullScreen | ( | pwnd,
|  | state |  | ) |

Value:

    (ClrWF(pwnd, WFFULLSCREENMASK), \
                                        SetWF(pwnd, WFFULLSCREENBASE | (state & WFFULLSCREENMASK)))

Definition at line 2714 of file inc/user.h.

#define SetMF | ( | pmenu,
|  | flag |  | ) | ((pmenu)->fFlags |= (flag))

| Definition at line 2925 of file inc/user.h.

#define SetMFS | ( | pitem,
|  | flag |  | ) | ((pitem)->fState |= (flag))

| Definition at line 2929 of file inc/user.h.

#define SetMFT | ( | pitem,
|  | flag |  | ) | ((pitem)->fType |= (flag))

| Definition at line 2933 of file inc/user.h.

#define SetRectEmpty SetRectEmptyInl

| Definition at line 271 of file inc/user.h.

#define SetWF | ( | hwnd,
|  | flag |  | ) | (*(((BYTE *)(hwnd)) + STATEOFFSET + (int)HIBYTE(flag)) |= LOBYTE(flag))

| Definition at line 2696 of file inc/user.h.

#define SFCENTERIMAGE 0x0D02

| Definition at line 2654 of file inc/user.h.

#define SFEDITCONTROL 0x0D20

| Definition at line 2658 of file inc/user.h.

#define SFELLIPSISMASK 0x0DC0

| Definition at line 2659 of file inc/user.h.

#define SFNOPREFIX 0x0C80

| Definition at line 2652 of file inc/user.h.

#define SFNOTIFY 0x0D01

| Definition at line 2653 of file inc/user.h.

#define SFREALSIZEIMAGE 0x0D08

| Definition at line 2656 of file inc/user.h.

#define SFRIGHTJUST 0x0D04

| Definition at line 2655 of file inc/user.h.

#define SFSUNKEN 0x0D10

| Definition at line 2657 of file inc/user.h.

#define SFTYPEMASK 0x0C1F

| Definition at line 2651 of file inc/user.h.

#define SFWIDELINESPACING 0x0C20

| Definition at line 2660 of file inc/user.h.

#define SOURCE (DWORD)0x00CC0000

| Definition at line 247 of file inc/user.h.

#define SRVIF_CHECKED 0x0001

| Definition at line 1251 of file inc/user.h.

#define SRVIF_DBCS 0x0004

| Definition at line 1253 of file inc/user.h.

#define SRVIF_IME 0x0008

| Definition at line 1254 of file inc/user.h.

#define SRVIF_MIDEAST 0x0010

| Definition at line 1255 of file inc/user.h.

#define SRVIF_WINEVENTHOOKS 0x0002

| Definition at line 1252 of file inc/user.h.

#define SSCF_16COLORS 0x00000008

| Definition at line 1379 of file inc/user.h. Referenced by SetSysColor(), and xxxSetSysColors().

#define SSCF_FORCESOLIDCOLOR 0x00000002

| Definition at line 1377 of file inc/user.h.

#define SSCF_NOTIFY 0x00000001

| Definition at line 1376 of file inc/user.h.

#define SSCF_SETMAGICCOLORS 0x00000004

| Definition at line 1378 of file inc/user.h.

#define STATEOFFSET (FIELD_OFFSET(WND, state))

| Definition at line 2682 of file inc/user.h.

#define STATICCODE 0x82

| Definition at line 355 of file inc/user.h.

#define STOCID | ( | s |  | ) | (gpsi->aStoCidPfn[(DWORD)((s) & ~FNID_STATUS_BITS) - FNID_START])

| Definition at line 899 of file inc/user.h.

#define SV_CLRFTRUEVIS 0x0002

| Definition at line 2727 of file inc/user.h.

#define SV_SET 0x0001

| Definition at line 2726 of file inc/user.h.

#define SV_UNSET 0x0000

| Definition at line 2725 of file inc/user.h.

#define SW_MDIRESTORE 0xCC /* special xxxMinMaximize() command for MDI */

| Definition at line 2888 of file inc/user.h.

#define SWITCHWNDCLASS MAKEINTATOM(0x8003)

| Definition at line 317 of file inc/user.h.

#define SYS_ALTERNATE 0x2000

| Definition at line 2666 of file inc/user.h.

#define SYS_PREVKEYSTATE 0x4000

| Definition at line 2667 of file inc/user.h.

#define SYSHBR | ( | i |  | ) | gpsi->ahbrSystem[COLOR_##i]

| Definition at line 235 of file inc/user.h.

#define SYSHBRUSH | ( | i |  | ) | gpsi->ahbrSystem[i]

| Definition at line 236 of file inc/user.h. Referenced by CleanupGDI(), DefWindowProcWorker(), DestroyClassBrush(), DrawFrame(), FillRect(), GetSysColorBrush(), SetSysColor(), xxxDefWindowProc(), xxxDrawCaptionBar(), xxxDrawMenuItem(), xxxDWP_EraseBkgnd(), and xxxRedrawHungWindow().

#define SYSMET | ( | i |  | ) | ((int)gpsi->aiSysMet[SM_##i])

| Definition at line 231 of file inc/user.h.

#define SYSMETRTL | ( | i |  | ) | ((int)gpsi->aiSysMet[SM_##i])

| Definition at line 232 of file inc/user.h.

#define SYSRGB | ( | i |  | ) | gpsi->argbSystem[COLOR_##i]

| Definition at line 233 of file inc/user.h.

#define SYSRGBRTL | ( | i |  | ) | gpsi->argbSystem[COLOR_##i]

| Definition at line 234 of file inc/user.h.

#define TEST_BOOL_PUSIF | ( | f |  | ) | TEST_BOOL_FLAG(gpsi->PUSIFlags, f)

| Definition at line 1160 of file inc/user.h.

#define TEST_BOOL_SRVIF | ( | f |  | ) | TEST_BOOL_FLAG(gpsi->wSRVIFlags, f)

| Definition at line 1258 of file inc/user.h.

#define TEST_EffectInvertPUSIF | ( | f |  | ) | (TEST_PUSIF(f) || !TEST_PUSIF(PUSIF_UIEFFECTS))

| Definition at line 1172 of file inc/user.h.

#define TEST_EffectPUSIF | ( | f |  | ) | ((gpsi->PUSIFlags & (f | PUSIF_UIEFFECTS)) == (f | PUSIF_UIEFFECTS))

| Definition at line 1166 of file inc/user.h. Referenced by LBGetScrollFlags(), and xxxCBShowListBoxWindow().

#define TEST_KbdCuesPUSIF

Value:

    (!gpsi->bKeyboardPref                         \
                            && !TEST_EffectInvertPUSIF(PUSIF_KEYBOARDCUES)  \
                            && !(GetAppCompatFlags2(VER40) & GACF2_KCOFF))

Definition at line 1174 of file inc/user.h.

Referenced by DefWindowProcWorker(), InternalCreateDialog(), IsDialogMessageW(), and xxxDefWindowProc().

#define TEST_PUSIF | ( | f |  | ) | TEST_FLAG(gpsi->PUSIFlags, f)

| Definition at line 1159 of file inc/user.h.

#define TEST_SRVIF | ( | f |  | ) | TEST_FLAG(gpsi->wSRVIFlags, f)

| Definition at line 1257 of file inc/user.h.

#define TestCF | ( | hwnd,
|  | flag |  | ) | (*((BYTE *)((PWND)(hwnd))->pcls + CFOFFSET + HIBYTE(flag)) & LOBYTE(flag))

| Definition at line 1684 of file inc/user.h.

#define TestCF2 | ( | pcls,
|  | flag |  | ) | (*((BYTE *)(pcls) + CFOFFSET + (int)HIBYTE(flag)) & LOBYTE(flag))

| Definition at line 1688 of file inc/user.h.

#define TestMF | ( | pmenu,
|  | flag |  | ) | ((pmenu)->fFlags & (flag))

| Definition at line 2927 of file inc/user.h.

#define TestMFS | ( | pitem,
|  | flag |  | ) | ((pitem)->fState & (flag))

| Definition at line 2930 of file inc/user.h.

#define TestMFT | ( | pitem,
|  | flag |  | ) | ((pitem)->fType & (flag))

| Definition at line 2934 of file inc/user.h.

#define TESTSYNCONLYMESSAGE | ( | msg,
|  | wParam |  | ) |

Value:

    (((msg) < WM_USER) ?       \
            (   (MessageTable[msg].bSyncOnlyMessage) ||                 \
                (((msg) == WM_DEVICECHANGE) && ((wParam) & 0x8000))) :  \
            0)

Definition at line 3674 of file inc/user.h.

#define TestWF | ( | hwnd,
|  | flag |  | ) | (*(((BYTE *)(hwnd)) + STATEOFFSET + (int)HIBYTE(flag)) & LOBYTE(flag))

| Definition at line 2695 of file inc/user.h.

#define TestwndChild | ( | hwnd |  | ) | (TestWF(hwnd, WFTYPEMASK) == LOBYTE(WFCHILD))

| Definition at line 2701 of file inc/user.h.

#define TestwndFrameOn | ( | pwnd |  | ) | (TestWF(pwnd, WFFRAMEON) && (GETPTI(pwnd)->pq == gpqForeground))

| Definition at line 2711 of file inc/user.h.

#define TestwndHI | ( | hwnd |  | ) | (TestwndTiled(hwnd) || TestwndIPopup(hwnd))

| Definition at line 2706 of file inc/user.h.

#define TestwndIPopup | ( | hwnd |  | ) | (TestWF(hwnd, WFTYPEMASK) == LOBYTE(WFICONICPOPUP))

| Definition at line 2702 of file inc/user.h.

#define TestwndNIPopup | ( | hwnd |  | ) | (TestWF(hwnd, WFTYPEMASK) == LOBYTE(WFPOPUP))

| Definition at line 2704 of file inc/user.h.

#define TestwndPopup | ( | hwnd |  | ) | (TestwndNIPopup(hwnd) || TestwndIPopup(hwnd))

| Definition at line 2705 of file inc/user.h.

#define TestwndTiled | ( | hwnd |  | ) | (TestWF(hwnd, WFTYPEMASK) == LOBYTE(WFTILED))

| Definition at line 2703 of file inc/user.h.

#define TEXT_FN | ( | fn |  | ) | fn##A

| Definition at line 301 of file inc/user.h.

#define TextPointer | ( | h |  | ) | ((LPWSTR)h)

| Definition at line 3582 of file inc/user.h.

#define THREAD_CODEPAGE | (

)

(GetClientInfo()->CodePage)

| Definition at line 580 of file inc/user.h.

#define TIF_16BIT (UINT)0x00000002

| Definition at line 2999 of file inc/user.h.

#define TIF_ALLOWFOREGROUNDACTIVATE (UINT)0x00000020

| Definition at line 3003 of file inc/user.h.

#define TIF_ALLOWOTHERACCOUNTHOOK (UINT)0x00800000

| Definition at line 3021 of file inc/user.h.

#define TIF_ANSILENGTH (UINT)0x10000000

| Definition at line 3025 of file inc/user.h.

#define TIF_CSRSSTHREAD (UINT)0x00000008

| Definition at line 3001 of file inc/user.h.

#define TIF_DELAYEDEVENT (UINT)0x00080000

| Definition at line 3017 of file inc/user.h.

#define TIF_DISABLEHOOKS (UINT)0x20000000

| Definition at line 3027 of file inc/user.h.

#define TIF_DISABLEIME (UINT)0x04000000

| Definition at line 3023 of file inc/user.h.

#define TIF_DONTATTACHQUEUE (UINT)0x00000040

| Definition at line 3004 of file inc/user.h.

#define TIF_DONTJOURNALATTACH (UINT)0x00000080

| Definition at line 3005 of file inc/user.h.

#define TIF_DOSEMULATOR (UINT)0x00020000

| Definition at line 3015 of file inc/user.h.

#define TIF_FIRSTIDLE (UINT)0x00002000

| Definition at line 3011 of file inc/user.h.

#define TIF_GLOBALHOOKER (UINT)0x00040000

| Definition at line 3016 of file inc/user.h.

#define TIF_GUITHREADINITIALIZED (UINT)0x02000000

| Definition at line 3022 of file inc/user.h.

#define TIF_IGNOREPLAYBACKDELAY (UINT)0x00400000

| Definition at line 3020 of file inc/user.h.

#define TIF_INACTIVATEAPPMSG (UINT)0x00000200

| Definition at line 3007 of file inc/user.h.

#define TIF_INCLEANUP (UINT)0x00000001

| Definition at line 2998 of file inc/user.h.

#define TIF_INGETTEXTLENGTH (UINT)0x08000000

| Definition at line 3024 of file inc/user.h.

#define TIF_MOVESIZETRACKING (UINT)0x00008000

| Definition at line 3013 of file inc/user.h.

#define TIF_MSGPOSCHANGED (UINT)0x00100000

| Definition at line 3018 of file inc/user.h. Referenced by xxxReadPostMessage(), and xxxScanSysQueue().

#define TIF_PALETTEAWARE (UINT)0x00000800

| Definition at line 3009 of file inc/user.h.

#define TIF_RESTRICTED (UINT)0x40000000

| Definition at line 3029 of file inc/user.h.

#define TIF_SHAREDWOW (UINT)0x00001000

| Definition at line 3010 of file inc/user.h.

#define TIF_SPINNING (UINT)0x00000400

| Definition at line 3008 of file inc/user.h.

#define TIF_SYSTEMTHREAD (UINT)0x00000004

| Definition at line 3000 of file inc/user.h.

#define TIF_TRACKRECTVISIBLE (UINT)0x00000010

| Definition at line 3002 of file inc/user.h.

#define TIF_VDMAPP (UINT)0x00010000

| Definition at line 3014 of file inc/user.h.

#define TIF_WAITFORINPUTIDLE (UINT)0x00004000

| Definition at line 3012 of file inc/user.h.

#define TIF_WOW64 (UINT)0x00000100 /* Thread is in a emulated 32bit process */

| Definition at line 3006 of file inc/user.h. Referenced by xxxCallHook2(), xxxCreateThreadInfo(), and xxxProcessNotifyWinEvent().

#define TOGGLE_PUSIF | ( | f |  | ) | TOGGLE_FLAG(gpsi->PUSIFlags, f)

| Definition at line 1164 of file inc/user.h.

#define TOGGLE_SRVIF | ( | f |  | ) | TOGGLE_FLAG(gpsi->wSRVIFlags, f)

| Definition at line 1262 of file inc/user.h.

#define TOOLTIPCLASS MAKEINTATOM(0x8006)

| Definition at line 320 of file inc/user.h.

#define TYPE_ACCELTABLE 8

| Definition at line 1000 of file inc/user.h.

#define TYPE_CALLPROC 7

| Definition at line 999 of file inc/user.h.

#define TYPE_CLIPDATA 6

| Definition at line 998 of file inc/user.h.

#define TYPE_CTYPES 18

| Definition at line 1011 of file inc/user.h.

#define TYPE_CURSOR 3

| Definition at line 995 of file inc/user.h.

#define TYPE_DDEACCESS 9

| Definition at line 1001 of file inc/user.h.

#define TYPE_DDECONV 10

| Definition at line 1002 of file inc/user.h.

#define TYPE_DDEXACT 11

| Definition at line 1003 of file inc/user.h.

#define TYPE_FREE 0

| Definition at line 992 of file inc/user.h.

#define TYPE_GENERIC 255

| Definition at line 1013 of file inc/user.h.

#define TYPE_HOOK 5

| Definition at line 997 of file inc/user.h.

#define TYPE_INPUTCONTEXT 17

| Definition at line 1009 of file inc/user.h.

#define TYPE_KBDFILE 14

| Definition at line 1006 of file inc/user.h.

#define TYPE_KBDLAYOUT 13

| Definition at line 1005 of file inc/user.h.

#define TYPE_MENU 2

| Definition at line 994 of file inc/user.h.

#define TYPE_MONITOR 12

| Definition at line 1004 of file inc/user.h.

#define TYPE_SETWINDOWPOS 4

| Definition at line 996 of file inc/user.h.

#define TYPE_TIMER 16

| Definition at line 1008 of file inc/user.h.

#define TYPE_WINDOW 1

| Definition at line 993 of file inc/user.h.

#define TYPE_WINEVENTHOOK 15

| Definition at line 1007 of file inc/user.h.

#define USER_MAJOR_VERSION 0x0005

| Definition at line 1368 of file inc/user.h.

#define USER_MINOR_VERSION 0x0000

| Definition at line 1369 of file inc/user.h.

#define USERCURRENTVERSION MAKELONG(USER_MINOR_VERSION, USER_MAJOR_VERSION)

| Definition at line 1371 of file inc/user.h.

#define UTCHAR UCHAR

| Definition at line 121 of file inc/user.h.

#define WEFACCEPTFILES 0x0810

| Definition at line 2490 of file inc/user.h.

#define WEFAPPWINDOW 0x0A04

| Definition at line 2508 of file inc/user.h.

#define WEFCLIENTEDGE 0x0902

| Definition at line 2495 of file inc/user.h.

#define WEFCONTEXTHELP 0x0904

| Definition at line 2497 of file inc/user.h.

#define WEFCONTROLPARENT 0x0A01

| Definition at line 2506 of file inc/user.h.

#define WEFDLGMODALFRAME 0x0801

| Definition at line 2486 of file inc/user.h.

#define WEFDRAGOBJECT 0x0802

| Definition at line 2487 of file inc/user.h.

#define WEFEDGEMASK 0x0903

| Definition at line 2496 of file inc/user.h.

#define WEFLAYERED 0x0A08

| Definition at line 2509 of file inc/user.h. Referenced by _ChildWindowFromPointEx(), _SetLayeredWindowAttributes(), _UpdateLayeredWindow(), DeleteFadeSprite(), GetLayeredWindow(), LayerHitTest(), LinkWindow(), OffsetChildren(), SpeedHitTest(), TrackLayeredZorder(), UnsetLayeredWindow(), UpdateLayeredSprite(), UserRemoveRedirectionBitmap(), xxxFreeWindow(), xxxSetLayeredWindow(), xxxWindowHitTest2(), and zzzChangeStates().

#define WEFLEFTSCROLL 0x0940

| Definition at line 2503 of file inc/user.h.

#define WEFMDICHILD 0x0840

| Definition at line 2492 of file inc/user.h.

#define WEFNOACTIVATE 0x0B08

| Definition at line 2534 of file inc/user.h. Referenced by _GetNextQueueWindow(), _IsTaskWindow(), FAllowForegroundActivate(), IsTrayWindow(), NextTopWindow(), xxxActivateOnMinimize(), and xxxButtonEvent().

#define WEFNOPARENTNOTIFY 0x0804

| Definition at line 2488 of file inc/user.h.

#define WEFPUIACCELHIDDEN 0x0B40

| Definition at line 2524 of file inc/user.h. Referenced by BNMultiDraw(), DefWindowProcWorker(), IsDialogMessageW(), StaticCallback(), xxxBNDrawText(), xxxBNOwnerDraw(), xxxCBInternalUpdateEditWindow(), xxxDefWindowProc(), xxxLBoxDrawItem(), and xxxStaticPaint().

#define WEFPUIFOCUSHIDDEN 0x0B80

| Definition at line 2523 of file inc/user.h. Referenced by DefWindowProcWorker(), IsDialogMessageW(), xxxBNDrawText(), xxxBNOwnerDraw(), xxxCBInternalUpdateEditWindow(), xxxDefWindowProc(), xxxLBoxDrawItem(), and xxxLBSetCaret().

#define WEFRIGHT 0x0910

| Definition at line 2501 of file inc/user.h.

#define WEFRTLREADING 0x0920

| Definition at line 2502 of file inc/user.h.

#define WEFSTATICEDGE 0x0A02

| Definition at line 2507 of file inc/user.h.

#define WEFTOOLWINDOW 0x0880

| Definition at line 2493 of file inc/user.h.

#define WEFTOPMOST 0x0808

| Definition at line 2489 of file inc/user.h.

#define WEFTRANSPARENT 0x0820

| Definition at line 2491 of file inc/user.h.

#define WEFTRUNCATEDCAPTION 0x0708

| Definition at line 2470 of file inc/user.h. Referenced by IsTooltipHittest(), xxxDrawCaptionBar(), and xxxShowTooltip().

#define WEFWINDOWEDGE 0x0901

| Definition at line 2494 of file inc/user.h.

#define WFALWAYSSENDNCPAINT 0x0640

| Definition at line 2462 of file inc/user.h.

#define WFANSICREATOR 0x0320

| Definition at line 2427 of file inc/user.h.

#define WFANSIPROC 0x0208

| Definition at line 2411 of file inc/user.h.

#define WFANYHUNGREDRAW 0x0318

| Definition at line 2425 of file inc/user.h.

#define WFBEINGACTIVATED 0x0210

| Definition at line 2412 of file inc/user.h.

#define WFBORDER 0x0E80

| Definition at line 2549 of file inc/user.h.

#define WFBORDERMASK 0x0EC0

| Definition at line 2550 of file inc/user.h.

#define WFBOTTOMMOST 0x0420

| Definition at line 2435 of file inc/user.h.

#define WFCAPTION 0x0EC0

| Definition at line 2551 of file inc/user.h.

#define WFCEPRESENT 0x0410

| Definition at line 2434 of file inc/user.h.

#define WFCHILD 0x0F40

| Definition at line 2560 of file inc/user.h.

#define WFCLIPCHILDREN 0x0F02

| Definition at line 2555 of file inc/user.h.

#define WFCLIPSIBLINGS 0x0F04

| Definition at line 2556 of file inc/user.h.

#define WFCLOSEBUTTONDOWN 0x0510

| Definition at line 2451 of file inc/user.h.

#define WFCPRESENT 0x0008

| Definition at line 2387 of file inc/user.h.

#define WFDESTROYED 0x0380

| Definition at line 2429 of file inc/user.h.

#define WFDIALOGWINDOW 0x0201

| Definition at line 2407 of file inc/user.h.

#define WFDISABLED 0x0F08

| Definition at line 2557 of file inc/user.h.

#define WFDLGFRAME 0x0E40

| Definition at line 2547 of file inc/user.h.

#define WFDONTVALIDATE 0x0402

| Definition at line 2431 of file inc/user.h.

#define WFERASEBKGND 0x0104

| Definition at line 2396 of file inc/user.h.

#define WFFRAMEON 0x0040

| Definition at line 2392 of file inc/user.h.

#define WFFRAMEPRESENTMASK 0x000F

| Definition at line 2388 of file inc/user.h.

#define WFFULLSCREEN 0x0440

| Definition at line 2436 of file inc/user.h.

#define WFFULLSCREENBASE 0x0700

| Definition at line 2468 of file inc/user.h.

#define WFFULLSCREENMASK 0x0707

| Definition at line 2469 of file inc/user.h.

#define WFGOTQUERYSUSPENDMSG 0x0301

| Definition at line 2416 of file inc/user.h.

#define WFGOTSUSPENDMSG 0x0302

| Definition at line 2417 of file inc/user.h.

#define WFGROUP 0x0E02

| Definition at line 2542 of file inc/user.h.

#define WFHASPALETTE 0x0220

| Definition at line 2413 of file inc/user.h.

#define WFHASSPB 0x0080

| Definition at line 2393 of file inc/user.h.

#define WFHELPBUTTONDOWN 0x0580

| Definition at line 2454 of file inc/user.h.

#define WFHIDDENPOPUP 0x0140

| Definition at line 2400 of file inc/user.h.

#define WFHPRESENT 0x0004

| Definition at line 2386 of file inc/user.h.

#define WFHSCROLL 0x0E10

| Definition at line 2545 of file inc/user.h.

#define WFICONIC WFMINIMIZED

| Definition at line 2564 of file inc/user.h.

#define WFICONICPOPUP 0x0FC0

| Definition at line 2563 of file inc/user.h.

#define WFINDESTROY 0x0480

| Definition at line 2437 of file inc/user.h.

#define WFINTERNALPAINT 0x0110

| Definition at line 2398 of file inc/user.h.

#define WFISINITIALIZED 0x0780

| Definition at line 2475 of file inc/user.h. Referenced by xxxCreateWindowEx().

#define WFLINEDNBUTTONDOWN 0x0608

| Definition at line 2458 of file inc/user.h.

#define WFLINEUPBUTTONDOWN 0x0601

| Definition at line 2455 of file inc/user.h.

#define WFMAXBOX 0x0E01

| Definition at line 2539 of file inc/user.h.

#define WFMAXFAKEREGIONAL 0x0508

| Definition at line 2448 of file inc/user.h.

#define WFMAXIMIZED 0x0F01

| Definition at line 2554 of file inc/user.h.

#define WFMENUDRAW 0x0180

| Definition at line 2401 of file inc/user.h.

#define WFMINBOX 0x0E02

| Definition at line 2541 of file inc/user.h.

#define WFMINIMIZED 0x0F20

| Definition at line 2559 of file inc/user.h.

#define WFMPRESENT 0x0001

| Definition at line 2384 of file inc/user.h.

#define WFMSGBOX 0x0020

| Definition at line 2391 of file inc/user.h.

#define WFNOANIMATE 0x0710

| Definition at line 2472 of file inc/user.h.

#define WFNOIDLEMSG 0x0D01

| Definition at line 2627 of file inc/user.h.

#define WFNONCPAINT 0x0101

| Definition at line 2394 of file inc/user.h.

#define WFOLDUI 0x0408

| Definition at line 2433 of file inc/user.h.

#define WFPAGEDNBUTTONDOWN 0x0604

| Definition at line 2457 of file inc/user.h.

#define WFPAGEUPBUTTONDOWN 0x0602

| Definition at line 2456 of file inc/user.h.

#define WFPAINTNOTPROCESSED 0x0240

| Definition at line 2414 of file inc/user.h.

#define WFPIXIEHACK 0x0680

| Definition at line 2463 of file inc/user.h.

#define WFPOPUP 0x0F80

| Definition at line 2561 of file inc/user.h.

#define WFREALLYMAXIMIZABLE 0x0340

| Definition at line 2428 of file inc/user.h.

#define WFREDRAWFRAMEIFHUNG 0x0310

| Definition at line 2424 of file inc/user.h.

#define WFREDRAWIFHUNG 0x0308

| Definition at line 2423 of file inc/user.h.

#define WFREDUCEBUTTONDOWN 0x0540

| Definition at line 2453 of file inc/user.h.

#define WFSCROLLBUTTONDOWN 0x0610

| Definition at line 2459 of file inc/user.h.

#define WFSENDERASEBKGND 0x0102

| Definition at line 2395 of file inc/user.h.

#define WFSENDNCPAINT 0x0108

| Definition at line 2397 of file inc/user.h.

#define WFSENDSIZEMOVE 0x0010

| Definition at line 2390 of file inc/user.h.

#define WFSERVERSIDEPROC 0x0204

| Definition at line 2410 of file inc/user.h.

#define WFSHELLHOOKWND 0x0740

| Definition at line 2474 of file inc/user.h.

#define WFSIZEBOX 0x0E04

| Definition at line 2543 of file inc/user.h.

#define WFSMQUERYDRAGICON 0x0720

| Definition at line 2473 of file inc/user.h.

#define WFSTARTPAINT 0x0404

| Definition at line 2432 of file inc/user.h.

#define WFSYNCPAINTPENDING 0x0280

| Definition at line 2415 of file inc/user.h.

#define WFSYSMENU 0x0E08

| Definition at line 2544 of file inc/user.h.

#define WFTABSTOP 0x0E01

| Definition at line 2540 of file inc/user.h.

#define WFTILED 0x0F00

| Definition at line 2553 of file inc/user.h.

#define WFTITLESET 0x0202

| Definition at line 2409 of file inc/user.h.

#define WFTOGGLETOPMOST 0x0304

| Definition at line 2418 of file inc/user.h.

#define WFTOPLEVEL 0x0E40

| Definition at line 2548 of file inc/user.h.

#define WFTYPEMASK 0x0FC0

| Definition at line 2562 of file inc/user.h.

#define WFUPDATEDIRTY 0x0120

| Definition at line 2399 of file inc/user.h.

#define WFVERTSCROLLTRACK 0x0620

| Definition at line 2460 of file inc/user.h.

#define WFVISIBLE 0x0F10

| Definition at line 2558 of file inc/user.h.

#define WFVPRESENT 0x0002

| Definition at line 2385 of file inc/user.h.

#define WFVSCROLL 0x0E20

| Definition at line 2546 of file inc/user.h.

#define WFWIN31COMPAT 0x0501

| Definition at line 2443 of file inc/user.h.

#define WFWIN40COMPAT 0x0502

| Definition at line 2444 of file inc/user.h.

#define WFWIN50COMPAT 0x0504

| Definition at line 2445 of file inc/user.h.

#define WFWINCOMPATMASK 0x0507

| Definition at line 2446 of file inc/user.h.

#define WFWMPAINTSENT 0x0401

| Definition at line 2430 of file inc/user.h.

#define WFZOOMBUTTONDOWN 0x0520

| Definition at line 2452 of file inc/user.h.

#define WHF_CALLWNDPROC WHF_FROM_WH(WH_CALLWNDPROC)

| Definition at line 2123 of file inc/user.h.

#define WHF_CALLWNDPROCRET WHF_FROM_WH(WH_CALLWNDPROCRET)

| Definition at line 2124 of file inc/user.h.

#define WHF_CBT WHF_FROM_WH(WH_CBT)

| Definition at line 2125 of file inc/user.h.

#define WHF_DEBUG WHF_FROM_WH(WH_DEBUG)

| Definition at line 2129 of file inc/user.h.

#define WHF_FOREGROUNDIDLE WHF_FROM_WH(WH_FOREGROUNDIDLE)

| Definition at line 2131 of file inc/user.h.

#define WHF_FROM_WH | ( | n |  | ) | (1 << (n + 1))

| Definition at line 2113 of file inc/user.h.

#define WHF_GETMESSAGE WHF_FROM_WH(WH_GETMESSAGE)

| Definition at line 2122 of file inc/user.h.

#define WHF_HARDWARE WHF_FROM_WH(WH_HARDWARE)

| Definition at line 2128 of file inc/user.h.

#define WHF_JOURNALPLAYBACK WHF_FROM_WH(WH_JOURNALPLAYBACK)

| Definition at line 2120 of file inc/user.h.

#define WHF_JOURNALRECORD WHF_FROM_WH(WH_JOURNALRECORD)

| Definition at line 2119 of file inc/user.h.

#define WHF_KEYBOARD WHF_FROM_WH(WH_KEYBOARD)

| Definition at line 2121 of file inc/user.h.

#define WHF_MOUSE WHF_FROM_WH(WH_MOUSE)

| Definition at line 2127 of file inc/user.h.

#define WHF_MSGFILTER WHF_FROM_WH(WH_MSGFILTER)

| Definition at line 2118 of file inc/user.h.

#define WHF_SHELL WHF_FROM_WH(WH_SHELL)

| Definition at line 2130 of file inc/user.h.

#define WHF_SYSMSGFILTER WHF_FROM_WH(WH_SYSMSGFILTER)

| Definition at line 2126 of file inc/user.h.

#define WIDTHBYTES | ( | i |  | ) | ((((i) + 31) & ~31) >> 3)

| Definition at line 2348 of file inc/user.h.

#define WINSTA_DIR L"\\Windows\\WindowStations"

| Definition at line 400 of file inc/user.h.

#define WINSTA_NAME L"Service-0x0000-0000$"

| Definition at line 402 of file inc/user.h.

#define WINSTA_SESSION_DIR L"\\Sessions\\xxxxxxxxxxx\\Windows\\WindowStations"

| Definition at line 401 of file inc/user.h.

#define WMCR_IR_DBCSCHAR 0x80000000

| Definition at line 588 of file inc/user.h.

#define WMCS_CONSOLE 0x0020

| Definition at line 658 of file inc/user.h.

#define WMCS_CONTEXTLOGOFF 0x0008

| Definition at line 656 of file inc/user.h.

#define WMCS_ENDTASK 0x0010

| Definition at line 657 of file inc/user.h.

#define WMCS_EXIT 0x0001

| Definition at line 653 of file inc/user.h.

#define WMCS_LOGOFF ENDSESSION_LOGOFF /* from winuser.w */

| Definition at line 661 of file inc/user.h.

#define WMCS_NODLGIFHUNG 0x0040

| Definition at line 659 of file inc/user.h.

#define WMCS_NORETRY 0x0080

| Definition at line 660 of file inc/user.h.

#define WMCS_QUERYEND 0x0002

| Definition at line 654 of file inc/user.h.

#define WMCS_SHUTDOWN 0x0004

| Definition at line 655 of file inc/user.h.

#define WMCSR_ALLOWSHUTDOWN 1

| Definition at line 666 of file inc/user.h.

#define WMCSR_CANCEL 3

| Definition at line 668 of file inc/user.h.

#define WMCSR_DONE 2

| Definition at line 667 of file inc/user.h.

#define WS_EX_ANSICREATOR 0x80000000L

| Definition at line 779 of file inc/user.h.

#define WS_EX_MDICHILD 0x00000040L

| Definition at line 778 of file inc/user.h.

#define XDUFromXPix | ( | x,
|  | cxChar |  | ) | MultDiv(x, 4, cxChar)

| Definition at line 3089 of file inc/user.h.

#define XPixFromXDU | ( | x,
|  | cxChar |  | ) | MultDiv(x, cxChar, 4)

| Definition at line 3087 of file inc/user.h.

#define xxxRtlSetMenuInfo NtUserThunkedMenuInfo

| Definition at line 3276 of file inc/user.h.

#define xxxRtlSetMenuItemInfo | ( | rtlMenu,
|  | uId,
|  | pmii |  | ) | NtUserThunkedMenuItemInfo(rtlMenu, uId, FALSE, FALSE, pmii, NULL)

| Definition at line 3277 of file inc/user.h.

#define YDUFromYPix | ( | y,
|  | cyChar |  | ) | MultDiv(y, 8, cyChar)

| Definition at line 3090 of file inc/user.h.

#define YPixFromYDU | ( | y,
|  | cyChar |  | ) | MultDiv(y, cyChar, 8)

| Definition at line 3088 of file inc/user.h.

## Typedef Documentation

typedef struct tagACON ACON

| Referenced by _CreateEmptyCursorObject(), _SetCursorIconData(), and zzzSetSystemImage().

typedef struct ACON_COMMON ACON_COMMON

typedef struct tagBUTN BUTN

typedef struct tagBUTNWND BUTNWND

typedef struct _CALLBACKSTATUS CALLBACKSTATUS

typedef struct _CALLBACKWND CALLBACKWND

typedef struct _CALLPROCDATA CALLPROCDATA

typedef struct _CAPTUREBUF CAPTUREBUF

typedef struct tagCARET CARET

typedef struct tagCBox CBOX

typedef struct _CLIENTINFO CLIENTINFO

typedef struct tagCLIENTTHREADINFO CLIENTTHREADINFO

typedef struct tagCLS CLS

typedef struct tagCLSMENUNAME CLSMENUNAME

typedef struct tagCOMBOWND COMBOWND

typedef struct tagCOMMON_WNDCLASS COMMON_WNDCLASS

typedef struct _CTLCOLOR CTLCOLOR

typedef struct tagCURSOR CURSOR

| Referenced by _SetCursorIconData(), and zzzSetSystemImage().

typedef struct tagCURSOR_ACON CURSOR_ACON

typedef struct CURSOR_COMMON CURSOR_COMMON

typedef struct tagCURSORDATA CURSORDATA

typedef struct tagCURSORFIND CURSORFIND

typedef struct _DESKHEAD DESKHEAD

typedef struct _DESKOBJHEAD DESKOBJHEAD

typedef struct tagDESKTOPINFO DESKTOPINFO

typedef struct _DIALOG DIALOG

typedef struct tagDISPLAYINFO DISPLAYINFO

typedef struct _DLG DLG

typedef struct tagDLGENUMDATA DLGENUMDATA

typedef struct _DOCONNECTDATA DOCONNECTDATA

typedef struct _DORECONNECTDATA DORECONNECTDATA

typedef struct _DRAWICONEXDATA DRAWICONEXDATA

typedef struct tagEVENT_PACKET EVENT_PACKET

typedef void(* FnDestroyUserObject)(void *)

| Definition at line 1429 of file inc/user.h.

typedef int(* FPLPKDRAWTEXTEX)(HDC, int, int, LPCWSTR, int, BOOL, UINT, LPDRAWTEXTDATA, UINT, int)

| Definition at line 3341 of file inc/user.h.

typedef void(* FPLPKPSMTEXTOUT)(HDC, int, int, LPWSTR, int, DWORD)

| Definition at line 3338 of file inc/user.h.

typedef LONG(* FPLPKTABBEDTEXTOUT)(HDC, int, int, LPCWSTR, int, int, CONST INT *, int, BOOL, int, int, int)

| Definition at line 3335 of file inc/user.h.

typedef struct tagGETCLIPBDATA GETCLIPBDATA

typedef struct _HANDLEENTRY HANDLEENTRY

typedef struct tagHANDLETYPEINFO HANDLETYPEINFO

typedef struct _HEAD HEAD

typedef struct tagHOOK HOOK

typedef DWORD ICH

| Definition at line 676 of file inc/user.h.

typedef struct tagIMC IMC

typedef struct tagIMEUI IMEUI

typedef struct tagIMEWND IMEWND

typedef struct tagINTERNALSETHIGHCONTRAST INTERNALSETHIGHCONTRAST

| Referenced by NtUserSystemParametersInfo(), and SystemParametersInfo().

typedef struct tagITEM ITEM

typedef struct _LARGE_ANSI_STRING LARGE_ANSI_STRING

typedef struct _LARGE_STRING LARGE_STRING

typedef struct _LARGE_UNICODE_STRING LARGE_UNICODE_STRING

typedef struct tagLBIV LBIV

typedef struct tagLBWND LBWND

typedef * LPBROADCASTSYSTEMMSGPARAMS

typedef const SIZERECT* LPCSIZERECT

| Definition at line 196 of file inc/user.h.

typedef * LPDRAWTEXTDATA

typedef void(FAR * LPFNTEXTDRAW)(HDC, int, int, LPWSTR, int, DWORD)

| Definition at line 3316 of file inc/user.h.

typedef ICH* LPICH

| Definition at line 677 of file inc/user.h.

typedef struct tagINTERNALSETHIGHCONTRAST * LPINTERNALSETHIGHCONTRAST

| Referenced by xxxSystemParametersInfo().

typedef struct tagITEM LPITEM

typedef ICH LpkEditAdjustCaret(PED ped, HDC hdc, PSTR pText, ICH ich)

| Definition at line 3400 of file inc/user.h.

typedef struct tagLPKEDITCALLOUT LPKEDITCALLOUT

typedef ICH LpkEditCchInWidth(PED ped, HDC hdc, PSTR pText, ICH cch, int width)

| Definition at line 3380 of file inc/user.h.

typedef BOOL LpkEditCreate(PED ped, HWND hWnd)

| Definition at line 3374 of file inc/user.h.

typedef int LpkEditCreateCaret(PED ped, HDC hdc, INT nWidth, INT nHeight, UINT hkl)

| Definition at line 3398 of file inc/user.h.

typedef void LpkEditDrawText(PED ped, HDC hdc, PSTR pText, INT cch, INT iMinSel, INT iMaxSel, INT iY)

| Definition at line 3384 of file inc/user.h.

typedef INT LpkEditGetLineWidth(PED ped, HDC hdc, PSTR pText, ICH cch)

| Definition at line 3382 of file inc/user.h.

typedef BOOL LpkEditHScroll(PED ped, HDC hdc, PSTR pText)

| Definition at line 3386 of file inc/user.h.

typedef int LpkEditIchToXY(PED ped, HDC hDC, PSTR pText, ICH cch, ICH ichPos)

| Definition at line 3376 of file inc/user.h.

typedef ICH LpkEditMouseToIch(PED ped, HDC hDC, PSTR pText, ICH cch, INT iX)

| Definition at line 3378 of file inc/user.h.

typedef ICH LpkEditMoveSelection(PED ped, HDC hdc, PSTR pText, ICH ich, BOOL fLeft)

| Definition at line 3388 of file inc/user.h.

typedef void LpkEditNextWord(PED ped, HDC hdc, PSTR pText, ICH ichStart, BOOL fLeft, ICH *pichMin, ICH *pichMax)

| Definition at line 3392 of file inc/user.h.

typedef int LpkEditProcessMenu(PED ped, UINT idMenuItem)

| Definition at line 3396 of file inc/user.h.

typedef void LpkEditSetMenu(PED ped, HMENU hMenu)

| Definition at line 3394 of file inc/user.h.

typedef int LpkEditVerifyText(PED ped, HDC hdc, PSTR pText, ICH ichInsert, PSTR pInsertText, ICH cchInsert)

| Definition at line 3390 of file inc/user.h.

typedef struct _MSGBOXDATA * LPMSGBOXDATA

typedef * LPPOINT5

typedef struct tagSBWND * LPSBWND

typedef struct tagSIZERECT * LPSIZERECT

typedef struct tagMBSTRING MBSTRING

typedef struct tagMDI MDI

| Referenced by MDIClientWndProcWorker().

typedef struct tagMDIWND MDIWND

| Referenced by RW_RegisterControls().

typedef struct tagMENU MENU

typedef struct tagMENULIST MENULIST

| Referenced by xxxSetLPITEMInfo().

typedef struct tagMNDRAGOVERINFO MNDRAGOVERINFO

typedef struct tagMONITOR MONITOR

typedef struct tagMSG_TABLE_ENTRY MSG_TABLE_ENTRY

typedef struct _MSGBOXDATA MSGBOXDATA

typedef struct tagNAMELIST NAMELIST

typedef struct tagOEMBITMAPINFO OEMBITMAPINFO

typedef struct tagACON * PACON

| Referenced by DestroyAniIcon().

typedef struct tagBUTN * PBUTN

typedef struct tagBUTNWND * PBUTNWND

typedef struct _CALLBACKSTATUS * PCALLBACKSTATUS

typedef struct _CALLBACKWND * PCALLBACKWND

typedef struct _CALLPROCDATA* KPTR_MODIFIER PCALLPROCDATA

| Definition at line 156 of file inc/user.h.

typedef struct _CAPTUREBUF * PCAPTUREBUF

typedef struct tagCARET * PCARET

typedef struct tagCBox PCBOX

typedef struct _CLIENTINFO * PCLIENTINFO

| Definition at line 151 of file inc/user.h.

typedef struct tagCLIENTTHREADINFO* KPTR_MODIFIER PCLIENTTHREADINFO

| Definition at line 141 of file inc/user.h.

typedef struct tagCLS* KPTR_MODIFIER PCLS

| Definition at line 157 of file inc/user.h.

typedef struct tagCLSMENUNAME * PCLSMENUNAME

typedef struct tagCOMBOWND * PCOMBOWND

typedef const SIZERECT* PCSIZERECT

| Definition at line 195 of file inc/user.h.

typedef struct _CTLCOLOR * PCTLCOLOR

typedef struct tagCURSOR* KPTR_MODIFIER PCURSOR

| Definition at line 134 of file inc/user.h.

typedef struct tagCURSORDATA * PCURSORDATA

typedef struct tagCURSORFIND * PCURSORFIND

typedef struct tagDCE* KPTR_MODIFIER PDCE

| Definition at line 142 of file inc/user.h.

typedef struct _DESKHEAD * PDESKHEAD

typedef struct _DESKOBJHEAD * PDESKOBJHEAD

typedef struct tagDESKTOP* KPTR_MODIFIER PDESKTOP

| Definition at line 130 of file inc/user.h.

typedef struct tagDESKTOPINFO* KPTR_MODIFIER PDESKTOPINFO

| Definition at line 139 of file inc/user.h.

typedef struct _DIALOG * PDIALOG

typedef struct tagDISPLAYINFO* KPTR_MODIFIER PDISPLAYINFO

| Definition at line 140 of file inc/user.h.

typedef struct _DLG PDLG

typedef struct tagDLGENUMDATA * PDLGENUMDATA

typedef struct _DOCONNECTDATA * PDOCONNECTDATA

typedef struct _DORECONNECTDATA * PDORECONNECTDATA

typedef struct tagED* PED

| Definition at line 3372 of file inc/user.h.

typedef struct tagPERUSERSERVERINFO PERUSERSERVERINFO

typedef struct _ETHREAD* PETHREAD

| Definition at line 138 of file inc/user.h.

typedef struct tagEVENT_PACKET * PEVENT_PACKET

typedef struct _PFNCLIENT PFNCLIENT

typedef struct _PFNCLIENTWORKER PFNCLIENTWORKER

typedef struct tagGETCLIPBDATA * PGETCLIPBDATA

typedef struct tagHANDLETYPEINFO * PHANDLETYPEINFO

typedef struct _HANDLEENTRY* KPTR_MODIFIER PHE

| Definition at line 154 of file inc/user.h.

typedef struct _HEAD * PHEAD

typedef struct tagHOOK* KPTR_MODIFIER PHOOK

| Definition at line 153 of file inc/user.h.

typedef struct tagIMC * PIMC

typedef struct tagIMEUI * PIMEUI

typedef struct tagIMEWND * PIMEWND

typedef struct tagITEM PITEM

typedef struct _LARGE_ANSI_STRING * PLARGE_ANSI_STRING

typedef struct _LARGE_STRING * PLARGE_STRING

typedef struct _LARGE_UNICODE_STRING * PLARGE_UNICODE_STRING

typedef struct tagLBIV * PLBIV

typedef struct tagLBWND * PLBWND

typedef struct tagLPKEDITCALLOUT * PLPKEDITCALLOUT

typedef struct _LOCKRECORD* KPTR_MODIFIER PLR

| Definition at line 128 of file inc/user.h.

typedef struct tagMDI PMDI

| Referenced by MakeMenuItem().

typedef struct tagMDIWND * PMDIWND

| Referenced by MakeMenuItem().

typedef struct tagMENU PMENU

| Definition at line 152 of file inc/user.h.

typedef struct tagMENULIST PMENULIST

| Referenced by UnlockSubMenu().

typedef struct tagMNDRAGOVERINFO * PMNDRAGOVERINFO

typedef struct tagMONITOR* KPTR_MODIFIER PMONITOR

| Definition at line 158 of file inc/user.h.

typedef struct _MOVESIZEDATA* PMOVESIZEDATA

| Definition at line 133 of file inc/user.h.

typedef struct _MSGBOXDATA * PMSGBOXDATA

typedef struct tagNAMELIST * PNAMELIST

typedef struct tagOEMBITMAPINFO * POEMBITMAPINFO

typedef struct tagCLS ** PPCLS

typedef struct tagPERUSERDATA* PPERUSERDATA

| Definition at line 148 of file inc/user.h.

typedef struct tagPERUSERSERVERINFO * PPERUSERSERVERINFO

| Definition at line 149 of file inc/user.h.

typedef struct _PFNCLIENT * PPFNCLIENT

typedef struct _PFNCLIENTWORKER * PPFNCLIENTWORKER

typedef struct tagPOPUPMENU* KPTR_MODIFIER PPOPUPMENU

| Definition at line 135 of file inc/user.h.

typedef struct _PROCDESKHEAD * PPROCDESKHEAD

typedef struct tagPROCESSINFO* KPTR_MODIFIER PPROCESSINFO

| Definition at line 146 of file inc/user.h.

typedef struct _PROCMARKHEAD * PPROCMARKHEAD

typedef struct _PROCOBJHEAD * PPROCOBJHEAD

typedef struct tagPROP * PPROP

typedef struct tagPROPLIST PPROPLIST

typedef struct _PROPSET * PPROPSET

typedef struct tagQ* KPTR_MODIFIER PQ

| Definition at line 144 of file inc/user.h.

typedef struct tagQMSG* KPTR_MODIFIER PQMSG

| Definition at line 136 of file inc/user.h.

typedef struct _PROCDESKHEAD PROCDESKHEAD

typedef struct _PROCMARKHEAD PROCMARKHEAD

typedef struct _PROCOBJHEAD PROCOBJHEAD

typedef struct tagPROP PROP

typedef struct tagPROPLIST PROPLIST

typedef struct _PROPSET PROPSET

typedef struct tagSBCALC * PSBCALC

typedef struct tagSBDATA * PSBDATA

typedef struct tagSBINFO PSBINFO

typedef struct tagSBTRACK * PSBTRACK

typedef struct tagSBWND * PSBWND

typedef struct _SCROLLPOS * PSCROLLPOS

typedef struct tagSERVERINFO* KPTR_MODIFIER PSERVERINFO

| Definition at line 155 of file inc/user.h.

typedef struct tagSETCLIPBDATA * PSETCLIPBDATA

typedef struct tagSHAREDINFO * PSHAREDINFO

typedef struct tagSIZERECT * PSIZERECT

typedef struct tagSNDMSGTIMEOUT * PSNDMSGTIMEOUT

typedef struct tagSPB* KPTR_MODIFIER PSPB

| Definition at line 143 of file inc/user.h.

typedef struct tagSVR_INSTANCE_INFO* PSVR_INSTANCE_INFO

| Definition at line 132 of file inc/user.h.

typedef struct tagTDB* KPTR_MODIFIER PTDB

| Definition at line 131 of file inc/user.h.

typedef struct tagTERMINAL* PTERMINAL

| Definition at line 150 of file inc/user.h.

typedef struct _THRDESKHEAD * PTHRDESKHEAD

typedef struct tagTHREADINFO* KPTR_MODIFIER PTHREADINFO

| Definition at line 145 of file inc/user.h.

typedef struct _THROBJHEAD * PTHROBJHEAD

typedef struct _TL* KPTR_MODIFIER PTL

| Definition at line 129 of file inc/user.h.

typedef struct _USERCONNECT * PUSERCONNECT

typedef struct tagWINDOWSTATION* KPTR_MODIFIER PWINDOWSTATION

| Definition at line 127 of file inc/user.h.

typedef struct tagWND* KPTR_MODIFIER PWND

| Definition at line 137 of file inc/user.h.

typedef struct _WNDMSG * PWNDMSG

typedef struct tagWOWTHREADINFO* PWOWTHREADINFO

| Definition at line 147 of file inc/user.h.

typedef struct tagSBCALC SBCALC

typedef struct tagSBDATA SBDATA

typedef struct tagSBINFO SBINFO

typedef struct tagSBTRACK SBTRACK

typedef struct tagSBWND SBWND

typedef struct _SCROLLPOS SCROLLPOS

typedef struct tagSERVERINFO SERVERINFO

typedef struct tagSETCLIPBDATA SETCLIPBDATA

typedef struct tagSHAREDINFO SHAREDINFO

typedef struct tagSIZERECT SIZERECT

typedef struct tagSNDMSGTIMEOUT SNDMSGTIMEOUT

typedef struct _THRDESKHEAD THRDESKHEAD

typedef struct _THROBJHEAD THROBJHEAD

typedef VOID(APIENTRY * TIMERPROC_PWND)(PWND, UINT, UINT_PTR, LPARAM)

| Definition at line 911 of file inc/user.h.

typedef struct _USERCONNECT USERCONNECT

typedef struct tagWND WND

typedef BOOL(APIENTRY * WNDENUMPROC_PWND)(PWND, LPARAM)

| Definition at line 910 of file inc/user.h.

typedef struct _WNDMSG WNDMSG

typedef LRESULT(APIENTRY * WNDPROC_PWND)(PWND, UINT, WPARAM, LPARAM)

| Definition at line 904 of file inc/user.h.

typedef LRESULT(APIENTRY * WNDPROC_PWNDEX)(PWND, UINT, WPARAM, LPARAM, ULONG_PTR)

| Definition at line 905 of file inc/user.h.

## Enumeration Type Documentation

anonymous enum

Enumeration values:

  TYPE_NORMAL |
  TYPE_POPUP |
  TYPE_TCARD |

Definition at line 2817 of file inc/user.h.

    02817      {
    02818         TYPE_NORMAL,
    02819         TYPE_POPUP,
    02820         TYPE_TCARD
    02821 };

## Function Documentation

BOOL _AdjustWindowRectEx | ( | LPRECT | lprc,
|  | LONG | style,
|  | BOOL | fMenu,
|  | DWORD | dwExStyle
| ) |

Definition at line 604 of file winmgrc.c.

References BOOL, GETAPPVER, GetWindowBorders(), InflateRect(), NeedsWindowEdge(), SYSMET, TRUE, and VER40.

Referenced by AdjustWindowRect(), AdjustWindowRectEx(), ChildMinMaxInfo(), InternalCreateDialog(), MDIClientWndProcWorker(), and xxxSetStaticImage().

    00609 {
    00610     //
    00611     // Here we add on the appropriate 3D borders for old and new apps.
    00612     //
    00613     // Rules:
    00614     //   (1) Do nothing for windows that have 3D border styles.
    00615     //   (2) If the window has a dlgframe border (has a caption or is a
    00616     //          a dialog), then add on the window edge style.
    00617     //   (3) We NEVER add on the CLIENT STYLE.  New apps can create
    00618     //          it if they want.  This is because it screws up alignment
    00619     //          when the app doesn't know about it.
    00620     //
    00621
    00622     if (NeedsWindowEdge(style, dwExStyle, GETAPPVER() >= VER40))
    00623         dwExStyle |= WS_EX_WINDOWEDGE;
    00624     else
    00625         dwExStyle &= ~WS_EX_WINDOWEDGE;
    00626
    00627     //
    00628     // Space for a menu bar
    00629     //
    00630     if (fMenu)
    00631         lprc->top -= SYSMET(CYMENU);
    00632
    00633     //
    00634     // Space for a caption bar
    00635     //
    00636     if ((HIWORD(style) & HIWORD(WS_CAPTION)) == HIWORD(WS_CAPTION)) {
    00637         lprc->top -= (dwExStyle & WS_EX_TOOLWINDOW) ? SYSMET(CYSMCAPTION) : SYSMET(CYCAPTION);
    00638     }
    00639
    00640     //
    00641     // Space for borders (window AND client)
    00642     //
    00643     {
    00644         int cBorders;
    00645
    00646         //
    00647         // Window AND Client borders
    00648         //
    00649
    00650         if (cBorders = GetWindowBorders(style, dwExStyle, TRUE, TRUE))
    00651             InflateRect(lprc, cBorders*SYSMET(CXBORDER), cBorders*SYSMET(CYBORDER));
    00652     }
    00653
    00654     return TRUE;
    00655 }

VOID _ClientToScreen | ( | PWND | pwnd,
|  | PPOINT | ppt
| ) |

Definition at line 893 of file rtl/wow.c.

References FNID_DESKTOP, GETFNID, tagWND::rcClient, TestWF, and VOID().

Referenced by ClientToScreen(), ComboBoxWndProcWorker(), ReaderMouseMove(), xxxQueryDropObject(), xxxSBWndProc(), xxxTrackInitSize(), and xxxTrackMouse().

    00896 {
    00897     /*
    00898      * Client and screen coordinates are the same for the
    00899      * desktop window.
    00900      */
    00901     if (GETFNID(pwnd) != FNID_DESKTOP) {
    00902 #ifdef USE_MIRRORING
    00903         if (TestWF(pwnd, WEFLAYOUTRTL)) {
    00904             ppt->x  = pwnd->rcClient.right - ppt->x;
    00905         } else
    00906 #endif
    00907         {
    00908             ppt->x += pwnd->rcClient.left;
    00909         }
    00910         ppt->y += pwnd->rcClient.top;
    00911     }
    00912 }

BOOL _FChildVisible | ( | PWND | pwnd | ) |

Definition at line 294 of file rtl/winmgr.c.

References BOOL, FALSE, NULL, REBASEPWND, TestWF, TestwndChild, TRUE, and WFVISIBLE.

Referenced by FChildVisible(), xxxCalcValidRects(), xxxSBWndProc(), and xxxShowWindow().

    00296 {
    00297     while (TestwndChild(pwnd)) {
    00298         pwnd = REBASEPWND(pwnd, spwndParent);
    00299         if (pwnd == NULL)
    00300             break;
    00301         if (!TestWF(pwnd, WFVISIBLE))
    00302             return FALSE;
    00303     }
    00304
    00305     return TRUE;
    00306 }

PPROP _FindProp | ( | PWND | pwnd,
|  | PCWSTR | pszKey,
|  | BOOL | fInternal
| ) |

Definition at line 46 of file rtl/winprop.c.

References tagPROPLIST::aprop, tagPROP::atomKey, tagPROP::fs, tagPROPLIST::iFirstFree, MapPropertyKey(), NULL, PROPF_INTERNAL, REBASE, and UINT.

Referenced by _GetProp(), InternalRemoveProp(), and InternalSetProp().

    00050 {
    00051     UINT i;
    00052     PPROPLIST ppropList;
    00053     PPROP pprop;
    00054     ATOM atomKey;
    00055
    00056     /*
    00057      * Make sure we have a property list.
    00058      */
    00059     ppropList = REBASE(pwnd, ppropList);
    00060     if (ppropList == NULL)
    00061         return NULL;
    00062
    00063     /*
    00064      * Call to the appropriate routine to verify the key name.
    00065      */
    00066     atomKey = MapPropertyKey(pszKey);
    00067     if (atomKey == 0)
    00068         return NULL;
    00069
    00070     /*
    00071      * Now we've got the atom, search the list for a property with the
    00072      * same atom/name.  Make sure to only return internal properties if
    00073      * the fInternal flag is set.  Do the same for external properties.
    00074      */
    00075     pprop = ppropList->aprop;
    00076     for (i = ppropList->iFirstFree; i > 0; i--) {
    00077         if (pprop->atomKey == atomKey) {
    00078             if (fInternal) {
    00079                 if (pprop->fs & PROPF_INTERNAL)
    00080                     return pprop;
    00081             } else {
    00082                 if (!(pprop->fs & PROPF_INTERNAL))
    00083                     return pprop;
    00084             }
    00085         }
    00086         pprop++;
    00087     }
    00088
    00089     /*
    00090      * Property not found, too bad.
    00091      */
    00092     return NULL;
    00093 }

VOID _GetClientRect | ( | PWND | pwnd,
|  | LPRECT | prc
| ) |

Definition at line 924 of file rtl/wow.c.

References FNID_DESKTOP, GETFNID, OffsetRect(), tagWND::rcClient, SYSMETRTL, TestWF, VOID(), WFMINIMIZED, and WFWIN40COMPAT.

Referenced by BNCalcRect(), ButtonWndProcWorker(), ChopText(), CItemInWindow(), CItemInWindowVarOwnerDraw(), DefWindowProcWorker(), ECInvalidateClient(), ECSetEditClip(), ECSize(), EditWndProc(), GetClientRect(), ISelFromPt(), LBCalcItemRowsAndColumns(), LBCalcVarITopScrollAmt(), LBGetItemRect(), LBInitDC(), LBPage(), LBSetCItemFullMax(), ListBoxWndProcWorker(), MLPaint(), MLScroll(), SLPaint(), StaticWndProcWorker(), xxxBNDrawText(), xxxBNOwnerDraw(), xxxBNPaint(), xxxDrawButton(), xxxInitSendValidateMinMaxInfo(), xxxLBoxCtlHScroll(), xxxLBPaint(), xxxLBSize(), xxxMNUpdateShownMenu(), xxxNewITopEx(), xxxPaintSwitchWindow(), xxxStaticPaint(), and xxxTrackMouse().

    00927 {
    00928     /*
    00929      * If this is a 3.1 app, and it's minimized, then we need to return
    00930      * a rectangle other than the real-client-rect.  This is necessary since
    00931      * there is no client-rect-size in Win4.0.  Apps such as PackRat 1.0
    00932      * will GPF if returned a empty-rect.
    00933      */
    00934     if (TestWF(pwnd, WFMINIMIZED) && !TestWF(pwnd, WFWIN40COMPAT)) {
    00935         prc->left   = 0;
    00936         prc->top    = 0;
    00937         prc->right  = SYSMETRTL(CXMINIMIZED);
    00938         prc->bottom = SYSMETRTL(CYMINIMIZED);
    00939
    00940     } else {
    00941
    00942         if (GETFNID(pwnd) != FNID_DESKTOP) {
    00943             *prc = pwnd->rcClient;
    00944             OffsetRect(prc, -pwnd->rcClient.left, -pwnd->rcClient.top);
    00945         } else {
    00946             /*
    00947              * For compatibility, return the rect of the primary
    00948              * monitor for the desktop window.
    00949              */
    00950             prc->left = prc->top = 0;
    00951             prc->right = SYSMETRTL(CXSCREEN);
    00952             prc->bottom = SYSMETRTL(CYSCREEN);
    00953         }
    00954     }
    00955 }

SHORT _GetKeyState | ( | int | vk | ) |

Definition at line 27 of file keyboard.c.

References CVKKEYSTATE, tagTHREADINFO::pq, PtiCurrentShared, SHORT, TestKeyStateDown, TestKeyStateToggle, and UINT.

Referenced by InitSwitchWndInfo(), MNCheckButtonDownState(), NtUserGetKeyState(), xxxDefWindowProc(), xxxIsDragging(), xxxMNLoop(), xxxMNStartMenu(), xxxMS_TrackMove(), xxxOldNextWindow(), xxxPaintIconsInSwitchWindow(), xxxPaintSwitchWindow(), xxxSBWndProc(), xxxShowSwitchWindow(), xxxSysCommand(), xxxTrackPopupMenuEx(), xxxTrackThumb(), and xxxTranslateAccelerator().

    00029 {
    00030     UINT wKeyState;
    00031     PTHREADINFO pti;
    00032
    00033     if ((UINT)vk >= CVKKEYSTATE) {
    00034         RIPERR1(ERROR_INVALID_PARAMETER,
    00035                 RIP_WARNING,
    00036                 "Invalid parameter \"vk\" (%ld) to _GetKeyState",
    00037                 vk);
    00038
    00039         return 0;
    00040     }
    00041
    00042     pti = PtiCurrentShared();
    00043
    00044 #ifdef LATER
    00045 //
    00046 // note - anything that accesses the pq structure is a bad idea since it
    00047 // can be changed between any two instructions.
    00048 //
    00049 #endif
    00050
    00051     wKeyState = 0;
    00052
    00053     /*
    00054      * Set the toggle bit.
    00055      */
    00056     if (TestKeyStateToggle(pti->pq, vk))
    00057         wKeyState = 0x0001;
    00058
    00059     /*
    00060      * Set the keyup/down bit.
    00061      */
    00062     if (TestKeyStateDown(pti->pq, vk)) {
    00063         /*
    00064          * Used to be wKeyState|= 0x8000.Fix for bug 28820; Ctrl-Enter
    00065          * accelerator doesn't work on Nestscape Navigator Mail 2.0
    00066          */
    00067         wKeyState |= 0xff80;  // This is what 3.1 returned!!!!
    00068     }
    00069
    00070     return (SHORT)wKeyState;
    00071 }

PWND _GetLastActivePopup | ( | PWND | pwnd | ) |

Definition at line 490 of file rtl/winmgr.c.

References NULL, REBASEPWND, and tagWND::spwndLastActive.

Referenced by GetLastActivePopup(), and xxxSysCommand().

    00492 {
    00493     if (pwnd->spwndLastActive == NULL)
    00494         return pwnd;
    00495
    00496     return REBASEPWND(pwnd, spwndLastActive);
    00497 }

DWORD _GetMenuDefaultItem | ( | PMENU | pMenu,
|  | BOOL | fByPosition,
|  | UINT | uFlags
| ) |

Definition at line 26 of file ntuser/rtl/menu.c.

References tagMENU::cItems, DWORD, MFMWFP_NOITEM, NULL, REBASEALWAYS, REBASEPTR, tagITEM::spSubMenu, TestMFS, and tagITEM::wID.

Referenced by GetMenuDefaultItem(), SetupFakeMDIAppStuff(), and xxxMNDoubleClick().

    00027 {
    00028     int iItem;
    00029     int cItems;
    00030     PITEM pItem;
    00031     PMENU pSubMenu;
    00032
    00033     pItem = REBASEALWAYS(pMenu, rgItems);
    00034     cItems = pMenu->cItems;
    00035
    00036     /*
    00037      * Walk the list of items sequentially until we find one that has
    00038      * MFS_DEFAULT set.
    00039      */
    00040     for (iItem = 0; iItem < cItems; iItem++, pItem++) {
    00041         if (TestMFS(pItem, MFS_DEFAULT)) {
    00042             if ((uFlags & GMDI_USEDISABLED) || !TestMFS(pItem, MFS_GRAYED)) {
    00043                 if ((uFlags & GMDI_GOINTOPOPUPS) && (pItem->spSubMenu != NULL)) {
    00044                     DWORD id;
    00045
    00046                     /*
    00047                      * Is there a valid submenu default?  If not, we'll use
    00048                      * this one.
    00049                      */
    00050                     pSubMenu = REBASEPTR(pMenu, pItem->spSubMenu);
    00051                     id = _GetMenuDefaultItem(pSubMenu, fByPosition, uFlags);
    00052                     if (id != MFMWFP_NOITEM)
    00053                         return(id);
    00054                 }
    00055
    00056                 break;
    00057             }
    00058         }
    00059     }
    00060
    00061     if (iItem < cItems) {
    00062         return (fByPosition ? iItem : pItem->wID);
    00063     } else {
    00064         return (MFMWFP_NOITEM);
    00065     }
    00066 }

UINT _GetMenuState | ( | PMENU | pMenu,
|  | UINT | wID,
|  | UINT | dwFlags
| ) |

Definition at line 583 of file rtl/wow.c.

References BOOL, dwFlags, DWORD, tagITEM::fState, tagITEM::fType, tagITEM::hbmp, tagITEM::lpstr, MNLookUpItem(), NULL, REBASEPTR, tagITEM::spSubMenu, and UINT.

Referenced by GetMenuState(), xxxDWP_NCMouse(), xxxDWP_SetCursor(), xxxHandleNCMouseGuys(), and xxxMNLoop().

    00587 {
    00588     PITEM pItem;
    00589     DWORD fFlags;
    00590
    00591     /*
    00592      * If the item does not exist, leave
    00593      */
    00594     if ((pItem = MNLookUpItem(pMenu, wId, (BOOL) (dwFlags & MF_BYPOSITION), NULL)) == NULL)
    00595         return (UINT)-1;
    00596
    00597     fFlags = pItem->fState | pItem->fType;
    00598
    00599 #ifndef _USERK_
    00600     /*
    00601      * Add old MFT_BITMAP flag to keep old apps happy
    00602      */
    00603     if ((pItem->hbmp != NULL) && (pItem->lpstr == NULL)) {
    00604         fFlags |= MFT_BITMAP;
    00605     }
    00606 #endif
    00607
    00608     if (pItem->spSubMenu != NULL) {
    00609         /*
    00610          * If the item is a popup, return item count in high byte and
    00611          * popup flags in low byte
    00612          */
    00613
    00614         fFlags = ((fFlags | MF_POPUP) & 0x00FF) +
    00615             (((PMENU)REBASEPTR(pMenu, pItem->spSubMenu))->cItems << 8);
    00616     }
    00617
    00618     return fFlags;
    00619 }

PWND _GetParent | ( | PWND | pwnd | ) |

Definition at line 762 of file rtl/wow.c.

References NULL, REBASEPWND, TestwndChild, and TestwndTiled.

Referenced by _GetAncestor(), GetParent(), and xxxHelpLoop().

    00764 {
    00765     /*
    00766      * For 1.03 compatibility reasons, we should return NULL
    00767      * for top level "tiled" windows and owner for other popups.
    00768      * pwndOwner is set to NULL in xxxCreateWindow for top level
    00769      * "tiled" windows.
    00770      */
    00771     if (!(TestwndTiled(pwnd))) {
    00772         if (TestwndChild(pwnd))
    00773             pwnd = REBASEPWND(pwnd, spwndParent);
    00774         else
    00775             pwnd = REBASEPWND(pwnd, spwndOwner);
    00776         return pwnd;
    00777     }
    00778
    00779     /*
    00780      * The window was not a child window; they may have been just testing
    00781      * if it was
    00782      */
    00783     return NULL;
    00784 }

HANDLE _GetProp | ( | PWND | pwnd,
|  | PCWSTR | pszKey,
|  | BOOL | fInternal
| ) |

Definition at line 106 of file rtl/winprop.c.

References _FindProp(), tagPROP::hData, NULL, and tagWND::ppropList.

Referenced by _DdeGetQualityOfService(), _GetDCEx(), _GetWindowContextHelpId(), _HasCaptionIcon(), _SetLayeredWindowAttributes(), _UpdateLayeredWindow(), AddConvProp(), CkptRestore(), DestroyWindowSmIcon(), DWP_GetIcon(), FindDdeConv(), GetContextHelpId(), GetProp(), InvalidateGDIWindows(), MESSAGECALL(), NtUserGetAppImeLevel(), ParkIcon(), RecreateRedirectionBitmap(), RemoveFlashWindowState(), RemoveRedirectionBitmap(), UnlinkConv(), UpdateLayeredSprite(), UserGetHwnd(), xxxArrangeIconicWindows(), xxxCalcValidRects(), xxxCleanupDdeConv(), xxxDesktopRecalc(), xxxDWP_SetIcon(), xxxFreeWindow(), xxxGetWindowSmIcon(), xxxHelpLoop(), xxxInitSendValidateMinMaxInfo(), xxxMetricsRecalc(), xxxPaintIconsInSwitchWindow(), xxxRecreateSmallIcons(), xxxSetClassIconEnum(), and zzzBltValidBits().

    00110 {
    00111     PPROP pprop;
    00112
    00113     /*
    00114      * A quick little optimization for that case where the window has no
    00115      * properties at all.
    00116      */
    00117     if (pwnd->ppropList == NULL)
    00118         return NULL;
    00119
    00120     /*
    00121      * FindProp does all the work, including converting pszKey to an atom
    00122      * (if necessary) for property lookup.
    00123      */
    00124     pprop = _FindProp(pwnd, pszKey, fInternal);
    00125     if (pprop == NULL)
    00126         return NULL;
    00127
    00128     return pprop->hData;
    00129 }

PMENU _GetSubMenu | ( | PMENU | pMenu,
|  | int | nPos
| ) |

Definition at line 796 of file rtl/wow.c.

References NULL, REBASEALWAYS, REBASEPTR, tagITEM::spSubMenu, and UINT.

Referenced by GetSubMenu(), MDIAddSysMenu(), xxxGetScrollMenu(), xxxGetSysMenu(), xxxGetSystemMenu(), xxxMNKeyDown(), and xxxSetSysMenu().

    00799 {
    00800     PITEM pItem;
    00801     PMENU pPopup = NULL;
    00802
    00803     /*
    00804      * Make sure nPos refers to a valid popup
    00805      */
    00806     if ((UINT)nPos < (UINT)((PMENU)pMenu)->cItems) {
    00807         pItem = &((PITEM)REBASEALWAYS(pMenu, rgItems))[nPos];
    00808         if (pItem->spSubMenu != NULL)
    00809             pPopup = (PMENU)REBASEPTR(pMenu, pItem->spSubMenu);
    00810
    00811     }
    00812
    00813     return (PVOID)pPopup;
    00814 }

PWND _GetWindow | ( | PWND | pwnd,
|  | UINT | cmd
| ) |

Definition at line 668 of file rtl/wow.c.

References BOOL, FALSE, FNID_DESKTOP, GetAppCompatFlags(), GETFNID, GetPrevPwnd(), NtUserCallHwnd(), NULL, PtoHq, REBASEPTR, REBASEPWND, tagWND::spwndChild, tagWND::spwndNext, tagWND::spwndOwner, tagWND::spwndParent, TestWF, TRUE, and WEFTOPMOST.

Referenced by _GetNextQueueWindow(), CheckOnTop(), CheckTopmost(), GetWindow(), xxxCalcValidRects(), and xxxMDINext().

    00671 {
    00672     PWND pwndT;
    00673     BOOL fRebase = FALSE;
    00674
    00675     /*
    00676      * If this is a desktop window, return NULL for sibling or
    00677      * parent information.
    00678      */
    00679     if (GETFNID(pwnd) == FNID_DESKTOP) {
    00680         switch (cmd) {
    00681         case GW_CHILD:
    00682             break;
    00683
    00684         default:
    00685             return NULL;
    00686             break;
    00687         }
    00688     }
    00689
    00690     /*
    00691      * Rebase the returned window at the end of the routine
    00692      * to avoid multiple test for pwndT == NULL.
    00693      */
    00694     pwndT = NULL;
    00695     switch (cmd) {
    00696     case GW_HWNDNEXT:
    00697         pwndT = pwnd->spwndNext;
    00698         fRebase = TRUE;
    00699         break;
    00700
    00701     case GW_HWNDFIRST:
    00702         if (pwnd->spwndParent) {
    00703             pwndT = REBASEPWND(pwnd, spwndParent);
    00704             pwndT = REBASEPWND(pwndT, spwndChild);
    00705             if (GetAppCompatFlags(NULL) & GACF_IGNORETOPMOST) {
    00706                 while (pwndT != NULL) {
    00707                     if (!TestWF(pwndT, WEFTOPMOST))
    00708                         break;
    00709                     pwndT = REBASEPWND(pwndT, spwndNext);
    00710                 }
    00711             }
    00712         }
    00713         break;
    00714
    00715     case GW_HWNDLAST:
    00716         pwndT = GetPrevPwnd(pwnd, NULL);
    00717         break;
    00718
    00719     case GW_HWNDPREV:
    00720         pwndT = GetPrevPwnd(pwnd, pwnd);
    00721         break;
    00722
    00723     case GW_OWNER:
    00724         pwndT = pwnd->spwndOwner;
    00725         fRebase = TRUE;
    00726         break;
    00727
    00728     case GW_CHILD:
    00729         pwndT = pwnd->spwndChild;
    00730         fRebase = TRUE;
    00731         break;
    00732
    00733 #if !defined(_USERK_)
    00734     case GW_ENABLEDPOPUP:
    00735        pwndT = (PWND)NtUserCallHwnd(PtoHq(pwnd), SFI_DWP_GETENABLEDPOPUP);
    00736        fRebase = TRUE;
    00737        break;
    00738 #endif
    00739
    00740     default:
    00741         RIPERR0(ERROR_INVALID_GW_COMMAND, RIP_VERBOSE, "");
    00742         return NULL;
    00743     }
    00744
    00745     if (pwndT != NULL && fRebase)
    00746         pwndT = REBASEPTR(pwnd, pwndT);
    00747
    00748     return pwndT;
    00749 }

VOID _GetWindowRect | ( | PWND | pwnd,
|  | LPRECT | prc
| ) |

Definition at line 967 of file rtl/wow.c.

References FNID_DESKTOP, GETFNID, tagWND::rcWindow, SYSMETRTL, and VOID().

Referenced by _UserSoundSentryWorker(), and GetWindowRect().

    00970 {
    00971
    00972     if (GETFNID(pwnd) != FNID_DESKTOP) {
    00973         *prc = pwnd->rcWindow;
    00974     } else {
    00975         /*
    00976          * For compatibility, return the rect of the primary
    00977          * monitor for the desktop window.
    00978          */
    00979         prc->left   = 0;
    00980         prc->top    = 0;
    00981         prc->right  = SYSMETRTL(CXSCREEN);
    00982         prc->bottom = SYSMETRTL(CYSCREEN);
    00983     }
    00984 }

BOOL _HasCaptionIcon | ( | PWND | pwnd | ) |

Definition at line 763 of file rtl/winmgr.c.

References _GetProp(), tagSERVERINFO::atomIconProp, tagSERVERINFO::atomIconSmProp, BOOL, BYTE, DIALOGCLASS, FALSE, gpsi, HMObjectFromHandle, LOBYTE, MAKEINTATOM, REBASEALWAYS, TestWF, TRUE, WEFDLGMODALFRAME, WEFTOOLWINDOW, WFBORDERMASK, WFDLGFRAME, and WFWIN40COMPAT.

Referenced by FindNCHit(), xxxDrawCaptionTemp(), xxxGetMenuBarInfo(), xxxGetTitleBarInfo(), xxxInitSendValidateMinMaxInfo(), and xxxMNFindWindowFromPoint().

    00764 {
    00765     HICON hIcon;
    00766     PCLS pcls;
    00767
    00768     if (TestWF(pwnd, WEFTOOLWINDOW))
    00769         // it's a tool window -- it doesn't get an icon
    00770         return(FALSE);
    00771
    00772     if ((TestWF(pwnd, WFBORDERMASK) != (BYTE)LOBYTE(WFDLGFRAME)) &&
    00773             !TestWF(pwnd, WEFDLGMODALFRAME))
    00774         // they are not trying to look like a dialog, they get an icon
    00775         return TRUE;
    00776
    00777     if (!TestWF(pwnd, WFWIN40COMPAT) &&
    00778         (((PCLS)REBASEALWAYS(pwnd, pcls))->atomClassName == (ATOM)(ULONG_PTR)DIALOGCLASS))
    00779         // it's an older REAL dialog -- it doesn't get an icon
    00780         return(FALSE);
    00781
    00782     hIcon = (HICON) _GetProp(pwnd, MAKEINTATOM(gpsi->atomIconSmProp), TRUE);
    00783
    00784     if (hIcon) {
    00785         // it's a 4.0 dialog with a small icon -- if that small icon is
    00786         // something other than the generic small windows icon, it gets an icon
    00787         return(hIcon != gpsi->hIconSmWindows);
    00788     }
    00789     hIcon = (HICON) _GetProp(pwnd, MAKEINTATOM(gpsi->atomIconProp), TRUE);
    00790
    00791     if (hIcon && (hIcon != gpsi->hIcoWindows))
    00792         // it's a 4.0 dialog with no small icon, but instead a large icon
    00793         // that's not the generic windows icon -- it gets an icon
    00794         return(TRUE);
    00795
    00796     pcls = REBASEALWAYS(pwnd, pcls);
    00797     if (pcls->spicnSm) {
    00798         if (pcls->spicnSm != HMObjectFromHandle(gpsi->hIconSmWindows)) {
    00799             // it's a 4.0 dialog with a class icon that's not the generic windows
    00800             // icon -- it gets an icon
    00801             return(TRUE);
    00802         }
    00803     }
    00804
    00805     // it's a 4.0 dialog with no small or large icon -- it doesn't get an icon
    00806     return(FALSE);
    00807 }

BOOL _IsChild | ( | PWND | pwndParent,
|  | PWND | pwnd
| ) |

Definition at line 826 of file rtl/wow.c.

References BOOL, FALSE, NULL, REBASEPWND, TestwndChild, and TRUE.

Referenced by _SelectPalette(), CheckPwndFilter(), ComboBoxWndProcWorker(), DefDlgProcWorker(), IsChild(), IsDialogMessageA(), IsDialogMessageW(), and xxxMNLoop().

    00829 {
    00830     /*
    00831      * Don't need a test to get out of the loop because the
    00832      * desktop is not a child.
    00833      */
    00834     while (pwnd != NULL) {
    00835         if (!TestwndChild(pwnd))
    00836             return FALSE;
    00837
    00838         pwnd = REBASEPWND(pwnd, spwndParent);
    00839         if (pwndParent == pwnd)
    00840             return TRUE;
    00841     }
    00842     return FALSE;
    00843 }

BOOL _IsDescendant | ( | PWND | pwndParent,
|  | PWND | pwndChild
| ) |

Definition at line 513 of file rtl/winmgr.c.

References BOOL, FALSE, FNID_DESKTOP, GETFNID, REBASEPWND, and TRUE.

Referenced by _GetNextDlgTabItem(), _NextControl(), CalcVisRgn(), GetNextDlgHelpItem(), PWInsertAfter(), xxxDefWindowProc(), and xxxScrollWindowEx().

    00516 {
    00517     while (1) {
    00518         if (pwndParent == pwndChild)
    00519             return TRUE;
    00520         if (GETFNID(pwndChild) == FNID_DESKTOP)
    00521             break;
    00522         pwndChild = REBASEPWND(pwndChild, spwndParent);
    00523     }
    00524
    00525     return FALSE;
    00526 }

BOOL _IsWindowVisible | ( | PWND | pwnd | ) |

Definition at line 860 of file rtl/wow.c.

References BOOL, FALSE, FNID_DESKTOP, GETFNID, NULL, REBASEPWND, TestWF, TRUE, and WFVISIBLE.

Referenced by ECResetTextInfo(), IsWindowVisible(), ListBoxWndProcWorker(), MLChangeSelection(), MLDeleteText(), MLEditWndProc(), MLEnsureCaretVisible(), MLInsertText(), MLKillFocus(), MLScroll(), MLSetCaretPosition(), MLSetFocus(), SLChangeSelection(), SLDrawLine(), SLDrawText(), SLEditWndProc(), SLPaint(), SLReplaceSel(), xxxDWPPrint(), xxxLBSetCurSel(), xxxLBSetSel(), and xxxSetISelBase().

    00862 {
    00863     /*
    00864      * Check if this is the iconic window being moved around with a mouse
    00865      * If so, return a TRUE, though, strictly speaking, it is hidden.
    00866      * This helps the Tracer guys from going crazy!
    00867      * Fix for Bug #57 -- SANKAR -- 08-08-89 --
    00868      */
    00869     if (pwnd == NULL)
    00870         return TRUE;
    00871
    00872     for (;;) {
    00873         if (!TestWF(pwnd, WFVISIBLE))
    00874             return FALSE;
    00875         if (GETFNID(pwnd) == FNID_DESKTOP)
    00876             break;
    00877         pwnd = REBASEPWND(pwnd, spwndParent);
    00878     }
    00879
    00880     return TRUE;
    00881 }

int _MapWindowPoints | ( | PWND | pwndFrom,
|  | PWND | pwndTo,
|  | LPPOINT | lppt,
|  | DWORD | cpt
| ) |

Definition at line 316 of file rtl/winmgr.c.

References BOOL, FALSE, FNID_DESKTOP, GETFNID, max, min, NULL, PZERO, tagWND::rcClient, and TestWF.

Referenced by MapWindowPoints().

    00321 {
    00322 #ifdef USE_MIRRORING
    00323     int     dx = 0, dy = 0;
    00324     int     SaveLeft, Sign = 1;
    00325     RECT    *pR      = (RECT *)lppt;
    00326     BOOL    bMirrored = FALSE;
    00327 #else
    00328     int dx, dy;
    00329     LPPOINT pptFrom, pptTo;
    00330 #endif
    00331
    00332     /*
    00333      * If a window is NULL, use the desktop window.
    00334      * If the window is the desktop, don't offset by
    00335      * the client rect, since it won't work if the screen
    00336      * origin is not (0,0) - use zero instead.
    00337      */
    00338
    00339     /*
    00340      * Compute deltas
    00341      */
    00342 #ifdef USE_MIRRORING
    00343     if (pwndFrom && GETFNID(pwndFrom) != FNID_DESKTOP) {
    00344         if (TestWF(pwndFrom, WEFLAYOUTRTL)) {
    00345             Sign      = -Sign;
    00346             dx        = -pwndFrom->rcClient.right;
    00347             bMirrored = (cpt == 2);
    00348         } else {
    00349             dx   = pwndFrom->rcClient.left;
    00350         }
    00351         dy   = pwndFrom->rcClient.top;
    00352     }
    00353
    00354     if (pwndTo && GETFNID(pwndTo) != FNID_DESKTOP) {
    00355         if (TestWF(pwndTo, WEFLAYOUTRTL)) {
    00356             Sign      = -Sign;
    00357             dx        = dx + Sign * pwndTo->rcClient.right;
    00358             bMirrored = (cpt == 2);
    00359         } else {
    00360             dx   = dx - Sign * pwndTo->rcClient.left;
    00361         }
    00362         dy   = dy - pwndTo->rcClient.top;
    00363     }
    00364
    00365 #else
    00366     if (pwndFrom == NULL || GETFNID(pwndFrom) == FNID_DESKTOP) {
    00367         pptFrom = PZERO(POINT);
    00368     } else {
    00369         pptFrom = (LPPOINT) &pwndFrom->rcClient;
    00370     }
    00371
    00372     if (pwndTo == NULL || GETFNID(pwndTo) == FNID_DESKTOP) {
    00373         pptTo = PZERO(POINT);
    00374     } else {
    00375         pptTo = (LPPOINT) &pwndTo->rcClient;
    00376     }
    00377     dx = pptFrom->x - pptTo->x;
    00378     dy = pptFrom->y - pptTo->y;
    00379 #endif
    00380
    00381     /*
    00382      * Map the points
    00383      */
    00384     while (cpt--) {
    00385         lppt->x += dx;
    00386 #ifdef USE_MIRRORING
    00387         lppt->x *= Sign;
    00388 #endif
    00389         lppt->y += dy;
    00390         ++lppt;
    00391     }
    00392
    00393 #ifdef USE_MIRRORING
    00394     if (bMirrored) {     //Special case for Rect
    00395         SaveLeft  = min (pR->left, pR->right);
    00396         pR->right = max (pR->left, pR->right);
    00397         pR->left  = SaveLeft;
    00398     }
    00399 #endif
    00400     return MAKELONG(dx, dy);
    00401 }

PMONITOR _MonitorFromPoint | ( | POINT | pt,
|  | DWORD | dwFlags
| ) |

Definition at line 56 of file mmrtl.c.

References BEGIN_EXCEPTION_HANDLER, tagDISPLAYINFO::cMonitors, dwFlags, tagMONITOR::dwMONFlags, END_EXCEPTION_HANDLER, END_EXCEPTION_HANDLER_EMPTY, FALSE, GetDispInfo(), GetPrimaryMonitor(), Int32x32To32, MONF_VISIBLE, MONITORFROMPOINTALGORITHM, NULL, tagMONITOR::pMonitorNext, PtInRect(), REBASESHAREDPTR, REBASESHAREDPTRALWAYS, and UINT.

Referenced by _MonitorFromRect(), ClipPointToDesktop(), InternalCreateDialog(), MonitorFromPoint(), TooltipGetPosition(), and xxxTrackPopupMenuEx().

    00057 {
    00058     PMONITOR        pMonitor, pMonitorResult;
    00059     int             dx;
    00060     int             dy;
    00061
    00062     UserAssert(dwFlags == MONITOR_DEFAULTTONULL ||
    00063                dwFlags == MONITOR_DEFAULTTOPRIMARY ||
    00064                dwFlags == MONITOR_DEFAULTTONEAREST);
    00065
    00066     if (GetDispInfo()->cMonitors == 1 && dwFlags != MONITOR_DEFAULTTONULL)
    00067         return GetPrimaryMonitor();
    00068
    00069     switch (dwFlags) {
    00070     case MONITOR_DEFAULTTONULL:
    00071     case MONITOR_DEFAULTTOPRIMARY:
    00072         /*
    00073          * Return the monitor the point is in.
    00074          */
    00075
    00076         BEGIN_EXCEPTION_HANDLER
    00077
    00078         for (   pMonitor = REBASESHAREDPTRALWAYS(GetDispInfo()->pMonitorFirst);
    00079                 pMonitor;
    00080                 pMonitor = REBASESHAREDPTR(pMonitor->pMonitorNext)) {
    00081
    00082             if (!(pMonitor->dwMONFlags & MONF_VISIBLE))
    00083                 continue;
    00084
    00085             if (PtInRect(&((MONITOR *)pMonitor)->rcMonitor, pt)) {
    00086                 return pMonitor;
    00087             }
    00088         }
    00089
    00090         END_EXCEPTION_HANDLER_EMPTY
    00091
    00092         /*
    00093          * Return what the user wants if it's not found.
    00094          */
    00095         switch (dwFlags) {
    00096         case MONITOR_DEFAULTTONULL:
    00097             return NULL;
    00098
    00099         case MONITOR_DEFAULTTOPRIMARY:
    00100             return GetPrimaryMonitor();
    00101
    00102         default:
    00103             UserAssertMsg0(FALSE, "Logic error in _MonitorFromPoint");
    00104             break;
    00105         }
    00106
    00107     case MONITOR_DEFAULTTONEAREST:
    00108
    00109 #define MONITORFROMPOINTALGORITHM(SUMSQUARESMAX, SUMSQUARESTYPE, POINTMULTIPLY)     \
    00110         SUMSQUARESTYPE  sumsquare;                                                  \
    00111         SUMSQUARESTYPE  leastsumsquare;                                             \
    00112         leastsumsquare = SUMSQUARESMAX;                                             \
    00113         for (   pMonitor = REBASESHAREDPTRALWAYS(GetDispInfo()->pMonitorFirst);     \
    00114                 pMonitor;                                                           \
    00115                 pMonitor = REBASESHAREDPTR(pMonitor->pMonitorNext)) {               \
    00116                                                                                     \
    00117             if (!(pMonitor->dwMONFlags & MONF_VISIBLE))                             \
    00118                 continue;                                                           \
    00119                                                                                     \
    00120             /*                                                                      \
    00121              * Determine distance from monitor along x axis.                        \
    00122              */                                                                     \
    00123             if (pt.x < pMonitor->rcMonitor.left) {                                  \
    00124                 dx = pMonitor->rcMonitor.left - pt.x;                               \
    00125             } else if (pt.x < pMonitor->rcMonitor.right) {                          \
    00126                 dx = 0;                                                             \
    00127             } else {                                                                \
    00128                 /*                                                                  \
    00129                  * Monitor rectangles do not include the rightmost edge.            \
    00130                  */                                                                 \
    00131                 dx = pt.x - (pMonitor->rcMonitor.right - 1);                        \
    00132             }                                                                       \
    00133                                                                                     \
    00134             /*                                                                      \
    00135              * Skip this monitor if dx is greater than dx^2 + dy^2.                 \
    00136              * We do this check to avoid multiplication operations.                 \
    00137              */                                                                     \
    00138             if ((SUMSQUARESTYPE) dx >= leastsumsquare)                              \
    00139                 continue;                                                           \
    00140                                                                                     \
    00141             /*                                                                      \
    00142              * Determine distance from monitor along y axis.                        \
    00143              */                                                                     \
    00144             if (pt.y < pMonitor->rcMonitor.top) {                                   \
    00145                 dy = pMonitor->rcMonitor.top - pt.y;                                \
    00146             } else if (pt.y < pMonitor->rcMonitor.bottom) {                         \
    00147                 /*                                                                  \
    00148                  * The point is in the monitor and we're done                       \
    00149                  * if both dx and dy are zero.                                      \
    00150                  */                                                                 \
    00151                 if (dx == 0)                                                        \
    00152                     return pMonitor;                                                \
    00153                                                                                     \
    00154                 dy = 0;                                                             \
    00155             } else {                                                                \
    00156                 dy = pt.y - (pMonitor->rcMonitor.bottom - 1);                       \
    00157             }                                                                       \
    00158                                                                                     \
    00159             /*                                                                      \
    00160              * Calculate dx^2. Skip this monitor if dx is greater                   \
    00161              * than dx^2 + dy^2. We do this check to avoid                          \
    00162              * multiplication operations.                                           \
    00163              */                                                                     \
    00164             sumsquare = POINTMULTIPLY(dx, dx);                                      \
    00165             if (sumsquare >= leastsumsquare)                                        \
    00166                 continue;                                                           \
    00167                                                                                     \
    00168             /*                                                                      \
    00169              * Skip this monitor if dx^2 + y is greater than dx^2 + dy^2.           \
    00170              * We do this check to avoid multiplication operations.                 \
    00171              */                                                                     \
    00172             if (sumsquare + (SUMSQUARESTYPE) dy >= leastsumsquare)                  \
    00173                 continue;                                                           \
    00174                                                                                     \
    00175             /*                                                                      \
    00176              * Compute dx^2 + dy^2. Skip this monitor if it's not the least.        \
    00177              */                                                                     \
    00178             sumsquare += (SUMSQUARESTYPE) POINTMULTIPLY(dy, dy);                    \
    00179             if (sumsquare >= leastsumsquare)                                        \
    00180                 continue;                                                           \
    00181                                                                                     \
    00182             /*                                                                      \
    00183              * This is the closest monitor so far.                                  \
    00184              */                                                                     \
    00185             leastsumsquare = sumsquare;                                             \
    00186             pMonitorResult = pMonitor;                                              \
    00187         }
    00188
    00189 #if DBG
    00190         pMonitorResult = (PMONITOR) -1;
    00191 #endif
    00192
    00193         if (    pt.x < SHRT_MIN || SHRT_MAX < pt.x ||
    00194                 pt.y < SHRT_MIN || SHRT_MAX < pt.y) {
    00195

PMONITOR _MonitorFromRect | ( | LPCRECT | lprc,
|  | DWORD | dwFlags
| ) |

Definition at line 221 of file mmrtl.c.

References _MonitorFromPoint(), BEGIN_EXCEPTION_HANDLER, tagDISPLAYINFO::cMonitors, dwFlags, tagMONITOR::dwMONFlags, END_EXCEPTION_HANDLER, EqualRect, GetDispInfo(), GetPrimaryMonitor(), IntersectRect(), IsRectEmpty(), MONF_VISIBLE, MONITORFROMRECTALGORITHM, NULL, tagMONITOR::pMonitorNext, tagDISPLAYINFO::rcScreen, REBASESHAREDPTR, and REBASESHAREDPTRALWAYS.

Referenced by _GetWindowPlacement(), CkptRestore(), CreateSpb(), DefDlgProcWorker(), InternalCreateDialog(), MonitorFromRect(), xxxCheckFullScreen(), xxxMNPositionHierarchy(), xxxMS_TrackMove(), xxxSetInternalWindowPos(), xxxSetWindowPlacement(), and xxxSystemParametersInfo().

    00227            :
    00228 *     lprc    - The rect.
    00229 *     dwFlags - One of:
    00230 *         MONITOR_DEFAULTTONULL - If the rect doesn't intersect a monitor,
    00231 *             return NULL.
    00232 *
    00233 *         MONITOR_DEFAULTTOPRIMARY - If the rect doesn't intersect a monitor,
    00234 *             return the primary monitor.
    00235 *
    00236 *         MONITOR_DEFAULTTONEAREST - Return the monitor nearest the rect.
    00237 *
    00238 * History:
    00239 * 22-Sep-1996 adams     Created.
    00240 * 29-Mar-1997 adams     Moved to rtl.
    00241 \***************************************************************************/
    00242
    00243 PMONITOR
    00244 _MonitorFromRect(LPCRECT lprc, DWORD dwFlags)
    00245 {
    00246     PDISPLAYINFO    pDispInfo;
    00247     PMONITOR        pMonitor, pMonitorResult;
    00248     RECT            rc;
    00249     int             area, areaMost;
    00250
    00251     UserAssert(dwFlags == MONITOR_DEFAULTTONULL ||
    00252                dwFlags == MONITOR_DEFAULTTOPRIMARY ||
    00253                dwFlags == MONITOR_DEFAULTTONEAREST);
    00254
    00255     /*
    00256      * Special case the most common case - 1 monitor.
    00257      */
    00258     pDispInfo = GetDispInfo();
    00259     if (pDispInfo->cMonitors == 1 && dwFlags != MONITOR_DEFAULTTONULL)
    00260         return GetPrimaryMonitor();
    00261
    00262     /*
    00263      * If rect is empty, use topleft point.
    00264      */
    00265     if (IsRectEmpty(lprc)) {
    00266         return _MonitorFromPoint(*(LPPOINT)lprc, dwFlags);
    00267     }
    00268
    00269     /*
    00270      * Return the primary monitor if the rectangle covers the desktop.
    00271      */
    00272     if (    lprc->left   <= pDispInfo->rcScreen.left &&
    00273             lprc->top    <= pDispInfo->rcScreen.top &&
    00274             lprc->right  >= pDispInfo->rcScreen.right &&
    00275             lprc->bottom >= pDispInfo->rcScreen.bottom) {
    00276
    00277         return GetPrimaryMonitor();
    00278     }
    00279
    00280     /*
    00281      * Calculate the nearest rectangle by determining which
    00282      * monitor has the greatest intersection with the rectangle.
    00283      */
    00284
    00285     BEGIN_EXCEPTION_HANDLER
    00286
    00287     areaMost = 0;
    00288     for (   pMonitor = REBASESHAREDPTRALWAYS(GetDispInfo()->pMonitorFirst);
    00289             pMonitor;
    00290             pMonitor = REBASESHAREDPTR(pMonitor->pMonitorNext)) {
    00291
    00292         if (!(pMonitor->dwMONFlags & MONF_VISIBLE))
    00293             continue;
    00294
    00295         if (IntersectRect(&rc, lprc, &((MONITOR *)pMonitor)->rcMonitor)) {
    00296             if (EqualRect(&rc, lprc))
    00297                 return pMonitor;
    00298
    00299             /*
    00300              * Calculate the area of the intersection. Note that
    00301              * the intersection must be in 16bit coordinats, since
    00302              * we limit monitor rects to 16bit coordinate space.
    00303              * So the result of any area calculation will fit in
    00304              * in an int.
    00305              */
    00306             area = (rc.right - rc.left) * (rc.bottom - rc.top);
    00307             if (area > areaMost) {
    00308                 areaMost = area;
    00309                 pMonitorResult = pMonitor;
    00310             }
    00311         }
    00312     }
    00313
    00314     END_EXCEPTION_HANDLER
    00315
    00316     UserAssert(areaMost >= 0);
    00317     if (areaMost > 0)
    00318         return pMonitorResult;
    00319
    00320
    00321     switch (dwFlags) {
    00322     case MONITOR_DEFAULTTONULL:
    00323         return NULL;
    00324
    00325     case MONITOR_DEFAULTTOPRIMARY:
    00326         return GetPrimaryMonitor();
    00327
    00328     case MONITOR_DEFAULTTONEAREST:
    00329         {
    00330             int dx, dy;
    00331
    00332 #define MONITORFROMRECTALGORITHM(SUMSQUARESMAX, SUMSQUARESTYPE, POINTMULTIPLY)      \
    00333             SUMSQUARESTYPE  sumsquare;                                              \
    00334             SUMSQUARESTYPE  leastsumsquare;                                         \
    00335             leastsumsquare = SUMSQUARESMAX;                                         \
    00336             for (   pMonitor = REBASESHAREDPTRALWAYS(GetDispInfo()->pMonitorFirst); \
    00337                     pMonitor;                                                       \
    00338                     pMonitor = REBASESHAREDPTR(pMonitor->pMonitorNext)) {           \
    00339                                                                                     \
    00340                 if (!(pMonitor->dwMONFlags & MONF_VISIBLE))                         \
    00341                     continue;                                                       \
    00342                                                                                     \
    00343                 /*                                                                  \
    00344                  * Determine distance from monitor along x axis.                    \
    00345                  */                                                                 \
    00346                 if (lprc->right <= pMonitor->rcMonitor.left) {                      \
    00347                     /*                                                              \
    00348                      * Add 1 because rectangles do not include the rightmost edge.  \
    00349                      */                                                             \
    00350                     dx = pMonitor->rcMonitor.left - lprc->right + 1;                \
    00351                 } else if (lprc->left < pMonitor->rcMonitor.right) {                \
    00352                     dx = 0;                                                         \
    00353                 } else {                                                            \
    00354                     /*                                                              \
    00355                      * Add 1 because rectangles do not include the rightmost edge.  \
    00356                      */                                                             \
    00357                     dx = lprc->left - (pMonitor->rcMonitor.right - 1);              \
    00358                 }                                                                   \
    00359                                                                                     \
    00360                 /*                                                                  \
    00361                  * Skip this monitor if dx is greater than dx^2 + dy^2.             \
    00362                  * We do this check to avoid multiplication operations.             \
    00363                  */                                                                 \
    00364                 if ((SUMSQUARESTYPE) dx >= leastsumsquare)                          \
    00365                     continue;                                                       \
    00366                                                                                     \
    00367                 /*                                                                  \
    00368                  * Determine distance from monitor along y axis.                    \
    00369                  */                                                                 \
    00370                 if (lprc->bottom <= pMonitor->rcMonitor.top) {                      \
    00371                     /*                                                              \
    00372                      * Add 1 because rectangles do not include the bottommost edge. \
    00373                      */                                                             \
    00374                     dy = pMonitor->rcMonitor.top - lprc->bottom + 1;                \
    00375                 } else if (lprc->top < pMonitor->rcMonitor.bottom) {                \
    00376                     UserAssert(dx != 0 && "This rectangle intersects a monitor, so we shouldn't be here."); \
    00377                     dy = 0;                                                         \
    00378                 } else {                                                            \
    00379                     /*                                                              \
    00380                      * Add 1 because rectangles do not include the bottommost edge. \
    00381                      */                                                             \
    00382                     dy = lprc->top - pMonitor->rcMonitor.bottom + 1;                \
    00383                 }                                                                   \
    00384                                                                                     \
    00385                 /*                                                                  \
    00386                  * Calculate dx^2. Skip this monitor if dx is greater               \
    00387                  * than dx^2 + dy^2. We do this check to avoid                      \
    00388                  * multiplication operations.                                       \
    00389                  */                                                                 \
    00390                 sumsquare = POINTMULTIPLY(dx, dx);                                  \
    00391                 if (sumsquare >= leastsumsquare)                                    \
    00392                     continue;                                                       \
    00393                                                                                     \
    00394                 /*                                                                  \
    00395                  * Skip this monitor if dx^2 + y is greater than dx^2 + dy^2.       \
    00396                  * We do this check to avoid multiplication operations.             \
    00397                  */                                                                 \
    00398                 if (sumsquare + (SUMSQUARESTYPE) dy >= leastsumsquare)              \
                        continue;                                                       \

PMONITOR _MonitorFromWindow | ( | PWND | pwnd,
|  | DWORD | dwFlags
| ) |

Definition at line 426 of file mmrtl.c.

References BEGIN_EXCEPTION_HANDLER, END_EXCEPTION_HANDLER, Int32x32To32, MONITORFROMRECTALGORITHM, and UINT.

Referenced by FixBogusSWP(), GetDialogMonitor(), IsSmallerThanScreen(), MonitorFromWindow(), SelectWindowRgn(), ValidatePositionableWindow(), xxxCBShowListBoxWindow(), xxxCheckFullScreen(), xxxCreateWindowEx(), xxxFreeWindow(), xxxInitSendValidateMinMaxInfo(), xxxMenuWindowProc(), xxxMNPositionHierarchy(), and xxxSetTrayWindow().

    00428                    {
    00429
    00430                 BEGIN_EXCEPTION_HANDLER
    00431                 MONITORFROMRECTALGORITHM(UINT_MAX, UINT, Int32x32To32)
    00432                 END_EXCEPTION_HANDLER
    00433
    00434             }
    00435
    00436             UserAssert(pMonitorResult != (PMONITOR) -1);
    00437             return pMonitorResult;
    00438         }
    00439
    00440     default:
    00441         UserAssertMsg0(0, "Logic error in _MonitorFromWindow, shouldn't have gotten here.");
    00442         break;
    00443     }
    00444
    00445     UserAssertMsg0(0, "Logic error in _MonitorFromWindow, shouldn't have gotten here.");
    00446     return NULL;
    00447 }
    00448
    00449
    00450
    00451 /***************************************************************************\
    00452 * _MonitorFromWindow
    00453 *
    00454 * Calculate the monitor that a window is in or is nearest to. We use
    00455 * the center of the window to determine its location. If the window
    00456 * is minimized, use its normal position.
    00457 *
    00458 * Arguments:
    00459 *     pwnd    - The window.
    00460 *     dwFlags - One of:
    00461 *         MONITOR_DEFAULTTONULL - If the window doesn't intersect a monitor,
    00462 *             return NULL.
    00463 *
    00464 *         MONITOR_DEFAULTTOPRIMARY - If the window doesn't intersect a monitor,
    00465 *             return the primary monitor.
    00466 *
    00467 *         MONITOR_DEFAULTTONEAREST - Return the monitor nearest the window.
    00468 *
    00469 * History:
    00470 * 22-Sep-1996 adams     Created.
    00471 * 29-Mar-1997 adams     Moved to rtl.
    00472 \***************************************************************************/
    00473
    00474 PMONITOR
    00475 _MonitorFromWindow(PWND pwnd, DWORD dwFlags)
    00476 {
    00477     PWND            pwndParent;
    00478
    00479     UserAssert(dwFlags == MONITOR_DEFAULTTONULL ||
    00480                dwFlags == MONITOR_DEFAULTTOPRIMARY ||
    00481                dwFlags == MONITOR_DEFAULTTONEAREST);
    00482
    00483     if (GetDispInfo()->cMonitors == 1 && dwFlags != MONITOR_DEFAULTTONULL) {
    00484         return GetPrimaryMonitor();
    00485     }
    00486
    00487     if (!pwnd)
    00488         goto NoWindow;
    00489
    00490     /*
    00491      * Handle minimized windows.
    00492      */
    00493     if (TestWF(pwnd, WFMINIMIZED))
    00494     {
    00495 #ifdef _USERK_
    00496         CHECKPOINT *    pcp;

BOOL _RegisterServicesProcess | ( | DWORD | dwProcessId | ) |

BOOL _SBGetParms | ( | PWND | pwnd,
|  | int | code,
|  | PSBDATA | pw,
|  | LPSCROLLINFO | lpsi
| ) |

Definition at line 140 of file sbctl.c.

References BOOL, FALSE, tagSBTRACK::nBar, tagSBDATA::page, tagSBDATA::pos, tagSBDATA::posMax, tagSBDATA::posMin, tagSBTRACK::posNew, PWNDTOPSBTRACK, tagSBTRACK::spwndTrack, and TRUE.

Referenced by NtUserSBGetParms(), and xxxSBWndProc().

    00145 {
    00146     PSBTRACK pSBTrack;
    00147
    00148     pSBTrack = PWNDTOPSBTRACK(pwnd);
    00149
    00150
    00151     if (lpsi->fMask & SIF_RANGE) {
    00152         lpsi->nMin = pw->posMin;
    00153         lpsi->nMax = pw->posMax;
    00154     }
    00155
    00156     if (lpsi->fMask & SIF_PAGE)
    00157         lpsi->nPage = pw->page;
    00158
    00159     if (lpsi->fMask & SIF_POS) {
    00160         lpsi->nPos = pw->pos;
    00161     }
    00162
    00163     if (lpsi->fMask & SIF_TRACKPOS)
    00164     {
    00165         if (pSBTrack && (pSBTrack->nBar == code) && (pSBTrack->spwndTrack == pwnd)) {
    00166             // posNew is in the context of psbiSB's window and bar code
    00167             lpsi->nTrackPos = pSBTrack->posNew;
    00168         } else {
    00169             lpsi->nTrackPos = pw->pos;
    00170         }
    00171     }
    00172     return ((lpsi->fMask & SIF_ALL) ? TRUE : FALSE);
    00173 }

VOID _ScreenToClient | ( | PWND | pwnd,
|  | PPOINT | ppt
| ) |

Definition at line 995 of file rtl/wow.c.

References FNID_DESKTOP, GETFNID, tagWND::rcClient, TestWF, and VOID().

Referenced by ChildMinMaxInfo(), ComboBoxWndProcWorker(), ListBoxWndProcWorker(), ScreenToClient(), xxxArrangeIconicWindows(), xxxDrawDragRect(), xxxQueryDropObject(), and xxxSetParent().

    00998 {
    00999     /*
    01000      * Client and screen coordinates are the same for the
    01001      * desktop window.
    01002      */
    01003     if (GETFNID(pwnd) != FNID_DESKTOP) {
    01004 #ifdef USE_MIRRORING
    01005         if (TestWF(pwnd, WEFLAYOUTRTL)) {
    01006             ppt->x  = pwnd->rcClient.right - ppt->x;
    01007         } else
    01008 #endif
    01009         {
    01010             ppt->x -= pwnd->rcClient.left;
    01011         }
    01012         ppt->y -= pwnd->rcClient.top;
    01013     }
    01014 }

UINT CalcWakeMask | ( | UINT | wMsgFilterMin,
|  | UINT | wMsgFilterMax,
|  | UINT | fsWakeMaskFilter
| ) |

Definition at line 43 of file ntuser/rtl/input.c.

References CheckMsgFilter, CheckMsgRange, FALSE, UINT, and WM_SYSTIMER.

Referenced by PeekMessage(), TransferWakeBit(), and xxxInternalGetMessage().

    00047 {
    00048     UINT fsWakeMask;
    00049
    00050     /*
    00051      * New for NT5: wake mask filter.
    00052      * In addition to the message filter, the application can also provide
    00053      *      a wake mask directly.
    00054      * If none is provided, default to NT4 mask (plus QS_SENDMESSAGE).
    00055      */
    00056     if (fsWakeMaskFilter == 0) {
    00057         fsWakeMask = (QS_ALLINPUT | QS_EVENT | QS_ALLPOSTMESSAGE);
    00058     } else {
    00059         /*
    00060          * If the caller wants input, we force all input events. The
    00061          *  same goes for posted messages. We do this to keep NT4
    00062          *  compatibility as much as possible.
    00063          */
    00064         if (fsWakeMaskFilter & QS_INPUT) {
    00065             fsWakeMaskFilter |= (QS_INPUT | QS_EVENT);
    00066         }
    00067         if (fsWakeMaskFilter & (QS_POSTMESSAGE | QS_TIMER | QS_HOTKEY)) {
    00068             fsWakeMaskFilter |= (QS_POSTMESSAGE | QS_TIMER | QS_HOTKEY);
    00069         }
    00070         fsWakeMask = fsWakeMaskFilter;
    00071     }
    00072
    00073 #ifndef _USERK_
    00074     /*
    00075      * The client PeekMessage in client\cltxt.h didn't used to
    00076      *  call CalcWakeMask if wMsgFilterMax was 0. We call it now
    00077      *  to take care of fsWakeMaskFilter but still bail before
    00078      *  messing with the message filter.
    00079      */
    00080     if (wMsgFilterMax == 0) {
    00081         return fsWakeMask;
    00082     }
    00083 #endif
    00084
    00085     /*
    00086      * Message filter.
    00087      * If the filter doesn't match certain ranges, we take out bits one by one.
    00088      * First check for a 0, 0 filter which means we want all input.
    00089      */
    00090     if (wMsgFilterMin == 0 && wMsgFilterMax == ((UINT)-1)) {
    00091         return fsWakeMask;
    00092     }
    00093
    00094     /*
    00095      * We're not looking at all posted messages.
    00096      */
    00097     fsWakeMask &= ~QS_ALLPOSTMESSAGE;
    00098
    00099     /*
    00100      * Check for mouse move messages.
    00101      */
    00102     if ((CheckMsgFilter(WM_NCMOUSEMOVE, wMsgFilterMin, wMsgFilterMax) == FALSE) &&
    00103             (CheckMsgFilter(WM_MOUSEMOVE, wMsgFilterMin, wMsgFilterMax) == FALSE)) {
    00104         fsWakeMask &= ~QS_MOUSEMOVE;
    00105     }
    00106
    00107     /*
    00108      * First check to see if mouse buttons messages are in the filter range.
    00109      */
    00110     if ((CheckMsgRange(WM_NCLBUTTONDOWN, WM_NCMBUTTONDBLCLK, wMsgFilterMin,
    00111             wMsgFilterMax) == FALSE) && (CheckMsgRange(WM_MOUSEFIRST + 1,
    00112             WM_MOUSELAST, wMsgFilterMin, wMsgFilterMax) == FALSE)) {
    00113         fsWakeMask &= ~QS_MOUSEBUTTON;
    00114     }
    00115
    00116     /*
    00117      * Check for key messages.
    00118      */
    00119     if (CheckMsgRange(WM_KEYFIRST, WM_KEYLAST,
    00120             wMsgFilterMin, wMsgFilterMax) == FALSE) {
    00121         fsWakeMask &= ~QS_KEY;
    00122     }
    00123
    00124     /*
    00125      * Check for paint messages.
    00126      */
    00127     if (CheckMsgFilter(WM_PAINT, wMsgFilterMin, wMsgFilterMax) == FALSE) {
    00128         fsWakeMask &= ~QS_PAINT;
    00129     }
    00130
    00131     /*
    00132      * Check for timer messages.
    00133      */
    00134     if ((CheckMsgFilter(WM_TIMER, wMsgFilterMin, wMsgFilterMax) == FALSE) &&
    00135             (CheckMsgFilter(WM_SYSTIMER,
    00136             wMsgFilterMin, wMsgFilterMax) == FALSE)) {
    00137         fsWakeMask &= ~QS_TIMER;
    00138     }
    00139
    00140     /*
    00141      * Check also for WM_QUEUESYNC which maps to all input bits.
    00142      * This was added for CBT/EXCEL processing.  Without it, a
    00143      * xxxPeekMessage(....  WM_QUEUESYNC, WM_QUEUESYNC, FALSE) would
    00144      * not see the message. (bobgu 4/7/87)
    00145      * Since the user can provide a wake mask now (fsWakeMaskFilter),
    00146      *  we also add QS_EVENT in this case (it was always set on NT4).
    00147      */
    00148     if (wMsgFilterMin == WM_QUEUESYNC) {
    00149         fsWakeMask |= (QS_INPUT | QS_EVENT);
    00150     }
    00151
    00152     return fsWakeMask;
    00153 }

PCURSOR ClassSetSmallIcon | ( | PCLS | pcls,
|  | PCURSOR | pcursor,
|  | BOOL | fServerCreated
| ) |

BOOL ClientFrame | ( | HDC | hDC,
|  | CONST RECT * | pRect,
|  | HBRUSH | hBrush,
|  | DWORD | patOp
| ) |

BOOL APIENTRY CopyInflateRect | ( | LPRECT | prcDst,
|  | CONST RECT * | prcSrc,
|  | int | cx,
|  | int | cy
| ) |

Definition at line 52 of file rect.c.

References APIENTRY, BOOL, cy, and TRUE.

Referenced by DefFrameProcWorker(), FindNCHit(), MNItemHitTest(), SLScrollText(), xxxCalcCaptionButton(), xxxCBInternalUpdateEditWindow(), xxxHelpLoop(), xxxLBSize(), xxxMetricsRecalc(), and xxxPaintSwitchWindow().

    00056 {
    00057     prcDst->left   = prcSrc->left   - cx;
    00058     prcDst->right  = prcSrc->right  + cx;
    00059     prcDst->top    = prcSrc->top    - cy;
    00060     prcDst->bottom = prcSrc->bottom + cy;
    00061     return TRUE;
    00062 }

BOOL APIENTRY CopyOffsetRect | ( | LPRECT | prcDst,
|  | CONST RECT * | prcSrc,
|  | int | cx,
|  | int | cy
| ) |

Definition at line 73 of file rect.c.

References APIENTRY, BOOL, cy, and TRUE.

Referenced by NormalizeRect(), PreventInterMonitorBlts(), TooltipRender(), xxxMNOpenHierarchy(), xxxMS_TrackMove(), and xxxScrollWindowEx().

    00077 {
    00078     prcDst->left   = prcSrc->left   + cx;
    00079     prcDst->right  = prcSrc->right  + cx;
    00080     prcDst->top    = prcSrc->top    + cy;
    00081     prcDst->bottom = prcSrc->bottom + cy;
    00082     return TRUE;
    00083 }

__inline void CopyRectInl | ( | LPRECT | prcDest,
|  | LPCRECT | prcSrc
| ) |

Definition at line 274 of file inc/user.h.

    00275 {
    00276     *prcDest = *prcSrc;
    00277 }

DECLARE_HANDLE | ( | HQ |  | ) |

DECLARE_KHANDLE | ( | HIMC |  | ) |

BOOL DrawFrame | ( | HDC | hdc,
|  | LPRECT | prect,
|  | int | clFrame,
|  | int | cmd
| ) |

void DrawPushButton | ( | HDC | hdc,
|  | LPRECT | lprc,
|  | UINT | state,
|  | UINT | flags
| ) |

Definition at line 1125 of file rtl/draw.c.

References BOOL, DrawEdge(), DWORD, FALSE, FillRect(), gpsi, SYSHBR, SYSRGBRTL, TRUE, UINT, UserSetBkColor, UserSetTextColor, and VOID().

Referenced by DrawFrameControl(), DrawThumb2(), and xxxDrawButton().

    01130 {
    01131     RECT   rc;
    01132     HBRUSH hbrMiddle;
    01133     DWORD  rgbBack;
    01134     DWORD  rgbFore;
    01135     BOOL   fDither;
    01136
    01137     rc = *lprc;
    01138
    01139     DrawEdge(hdc,
    01140              &rc,
    01141              (state & (DFCS_PUSHED | DFCS_CHECKED)) ? EDGE_SUNKEN : EDGE_RAISED,
    01142              (UINT)(BF_ADJUST | BF_RECT | (flags & (BF_SOFT | BF_FLAT | BF_MONO))));
    01143
    01144     /*
    01145      * BOGUS
    01146      * On monochrome, need to do something to make pushed buttons look
    01147      * better.
    01148      */
    01149
    01150     /*
    01151      * Fill in middle.  If checked, use dither brush (gray brush) with
    01152      * black becoming normal color.
    01153      */
    01154     fDither = FALSE;
    01155
    01156     if (state & DFCS_CHECKED) {
    01157
    01158         if ((gpsi->BitCount < 8) || (SYSRGBRTL(3DHILIGHT) == RGB(255,255,255))) {
    01159             hbrMiddle = gpsi->hbrGray;
    01160             rgbBack = UserSetBkColor(hdc, SYSRGBRTL(3DHILIGHT));
    01161             rgbFore = UserSetTextColor(hdc, SYSRGBRTL(3DFACE));
    01162             fDither = TRUE;
    01163         } else {
    01164             hbrMiddle = SYSHBR(3DHILIGHT);
    01165         }
    01166
    01167     } else {
    01168         hbrMiddle = SYSHBR(3DFACE);
    01169     }
    01170
    01171     FillRect(hdc, &rc, hbrMiddle);
    01172
    01173     if (fDither) {
    01174         UserSetBkColor(hdc, rgbBack);
    01175         UserSetTextColor(hdc, rgbFore);
    01176     }
    01177
    01178     if (flags & BF_ADJUST)
    01179         *lprc = rc;
    01180 }

int DrawTextExWorker | ( | HDC | hdc,
|  | LPWSTR | lpchText,
|  | int | cchText,
|  | LPRECT | lprc,
|  | UINT | dwDTformat,
|  | LPDRAWTEXTPARAMS | lpDTparams,
|  | int | iCharset
| ) |

Definition at line 1708 of file rtl/drawtext.c.

References AddEllipsisAndDrawLine(), BOOL, CALCRECT, CALL_LPK, CR, DT_CHARSETDONE, DT_CHARSETINIT, DT_DrawJustifiedLine(), DT_GetLineBreak(), DT_InitDrawTextInfo(), DT_VFMTMASK, EDITCONTROL, ENDELLIPSIS, FALSE, GETAPPVER, LF, LPDRAWTEXTDATA, MODIFYSTRING, NOCLIP, NULL, PATHELLIPSIS, PBYTE, PtiCurrentShared, RTLREADING, SINGLELINE, TRUE, UINT, UserCreateRectRgn, UserDeleteObject, UserExtSelectClipRgn, UserGetClipRgn, UserGetTextAlign, UserIntersectClipRect, UserSetTextAlign, VER40, WORDBREAK, and WORDELLIPSIS.

Referenced by DrawTextExA(), and DrawTextExW().

    01716 {
    01717     DRAWTEXTDATA DrawInfo;
    01718     WORD         wFormat = LOWORD(dwDTformat);
    01719     LPWSTR       lpchTextBegin;
    01720     LPWSTR       lpchEnd;
    01721     LPWSTR       lpchNextLineSt;
    01722     int          iLineLength;
    01723     int          iySign;
    01724     int          yLine;
    01725     int          yLastLineHeight;
    01726     HRGN         hrgnClip;
    01727     int          iLineCount;
    01728     RECT         rc;
    01729     BOOL         fLastLine;
    01730     WCHAR        ch;
    01731     UINT         oldAlign;
    01732
    01733 #if DBG
    01734     if (dwDTformat & ~DT_VALID)
    01735         RIPMSG0 (RIP_WARNING, "DrawTextExW: Invalid dwDTformat flags");
    01736 #endif
    01737
    01738     if (lpchText == NULL) {
    01739         return 1;
    01740     }
    01741
    01742     if (cchText == 0 && *lpchText) {
    01743         /*
    01744          * infoview.exe passes lpchText that points to '\0'
    01745          *
    01746          * "Microsoft Expedia Streets and Trips 2000" and "MS MapPoint 2000"
    01747          * tries cchText == 0 to detect if DrawTextW is supported.
    01748          */
    01749
    01750         /* Added by Chicago:
    01751          * Lotus Notes doesn't like getting a zero return here
    01752          */
    01753         return 1;
    01754     }
    01755
    01756     if (cchText == -1)
    01757         cchText = wcslen(lpchText);
    01758
    01759
    01760
    01761     if ((lpDTparams) && (lpDTparams->cbSize != sizeof(DRAWTEXTPARAMS))) {
    01762         RIPERR1(ERROR_INVALID_PARAMETER, RIP_WARNING, "DrawTextEx: cbSize %ld is invalid",
    01763                 lpDTparams->cbSize);
    01764         return 0;
    01765     }
    01766
    01767
    01768 #ifdef LATER
    01769     /*
    01770      * If DT_MODIFYSTRING is specified, then check for read-write pointer.
    01771      */
    01772     if (MODIFYSTRING(dwDTformat) &&
    01773             (ENDELLIPSIS(dwDTformat) || PATHELLIPSIS(dwDTformat))) {
    01774         if(IsBadWritePtr(lpchText, cchText)) {
    01775             RIPERR0(ERROR_INVALID_PARAMETER, RIP_WARNING, "DrawTextEx: For DT_MODIFYSTRING, lpchText must be read-write");
    01776             return(0);
    01777         }
    01778     }
    01779 #endif
    01780
    01781     /*
    01782      * Initialize the DrawInfo structure.
    01783      */
    01784     if (!DT_InitDrawTextInfo(hdc, lprc, dwDTformat, (LPDRAWTEXTDATA)&DrawInfo, lpDTparams))
    01785         return 0;
    01786
    01787     DrawInfo.iCharset = iCharset;
    01788     /*
    01789      * If the rect is too narrow or the margins are too wide.....Just forget it!
    01790      *
    01791      * If wordbreak is specified, the MaxWidth must be a reasonable value.
    01792      * This check is sufficient because this will allow CALCRECT and NOCLIP
    01793      * cases.  --SANKAR.
    01794      *
    01795      * This also fixed all of our known problems with AppStudio.
    01796      */
    01797     if (DrawInfo.cxMaxWidth <= 0) {
    01798
    01799         /*
    01800          * We used to return a non-zero value in win31.
    01801          * If the kernel calls this we are always Ver 4.0 or above
    01802          */
    01803 #ifdef _USERK_
    01804         if (0) {
    01805 #else
    01806         if (GETAPPVER() < VER40) {
    01807 #endif
    01808             if((DrawInfo.cxMaxWidth == 0) && !CALCRECT(wFormat)) {
    01809                 return(1);
    01810             }
    01811         } else {
    01812             if (WORDBREAK(wFormat)) {
    01813                 RIPMSG0 (RIP_WARNING, "DrawTextExW: FAILURE DrawInfo.cxMaxWidth <=0");
    01814                 return (1);
    01815             }
    01816         }
    01817     }
    01818
    01819     /*
    01820      * if we're not doing the drawing, initialise the lpk-dll
    01821      */
    01822     if (RTLREADING(dwDTformat)) {
    01823         oldAlign = UserSetTextAlign(hdc, TA_RTLREADING | UserGetTextAlign(hdc));
    01824     }
    01825
    01826     if (DrawInfo.bCharsetDll) {
    01827 #ifdef _USERK_
    01828         PTHREADINFO ptiCurrent = PtiCurrentShared();
    01829
    01830         if(CALL_LPK(ptiCurrent))
    01831 #endif // _USERK_
    01832             (*UserLpkDrawTextEx)(hdc, 0, 0, lpchText, cchText, FALSE, dwDTformat,
    01833                                  (LPDRAWTEXTDATA)&DrawInfo, DT_CHARSETINIT, iCharset);
    01834     }
    01835
    01836     /*
    01837      * If we need to clip, let us do that.
    01838      */
    01839     if (!NOCLIP(wFormat)) {
    01840         //
    01841         // Save clipping region so we can restore it later.
    01842         //
    01843         // hrgnSave = SaveClipRgn(hdc);
    01844         // IntersectClipRect(hdc, lprc->left, lprc->top, lprc->right, lprc->bottom);
    01845
    01846         hrgnClip = UserCreateRectRgn(0,0,0,0);
    01847         if (hrgnClip != NULL) {
    01848             if (UserGetClipRgn(hdc, hrgnClip) != 1) {
    01849                 UserDeleteObject(hrgnClip);
    01850                 hrgnClip = (HRGN)-1;
    01851             }
    01852             rc = *lprc;
    01853             UserIntersectClipRect(hdc, rc.left, rc.top, rc.right, rc.bottom);
    01854         }
    01855     } else {
    01856         hrgnClip = NULL;
    01857     }
    01858
    01859     lpchTextBegin = lpchText;
    01860     lpchEnd = lpchText + cchText;
    01861
    01862 ProcessDrawText:
    01863
    01864     iLineCount = 0;  // Reset number of lines to 1.
    01865     yLine = lprc->top;
    01866
    01867     if (SINGLELINE(wFormat)) {
    01868         iLineCount = 1;  // It is a single line.
    01869
    01870
    01871         /*
    01872          * Process single line DrawText.
    01873          */
    01874         switch (wFormat & DT_VFMTMASK) {
    01875             case DT_BOTTOM:
    01876                 yLine = lprc->bottom - DrawInfo.cyLineHeight;
    01877                 break;
    01878
    01879             case DT_VCENTER:
    01880                 yLine = lprc->top + ((lprc->bottom - lprc->top - DrawInfo.cyLineHeight) / 2);
    01881                 break;
    01882         }
    01883
    01884         cchText = AddEllipsisAndDrawLine(hdc, yLine, lpchText, cchText, dwDTformat, &DrawInfo, iCharset);
    01885         yLine += DrawInfo.cyLineHeight;
    01886         lpchText += cchText;
    01887     } else  {
    01888
    01889         /*
    01890          * Multiline
    01891          * If the height of the rectangle is not an integral multiple of the
    01892          * average char height, then it is possible that the last line drawn
    01893          * is only partially visible. However, if DT_EDITCONTROL style is
    01894          * specified, then we must make sure that the last line is not drawn if
    01895          * it is going to be partially visible. This will help imitate the
    01896          * appearance of an edit control.
    01897          */
    01898         if (EDITCONTROL(wFormat))
    01899             yLastLineHeight = DrawInfo.cyLineHeight;
    01900         else
    01901             yLastLineHeight = 0;
    01902
    01903         iySign = DrawInfo.iYSign;
    01904         fLastLine = FALSE;
    01905         // Process multiline DrawText.
    01906         while ((lpchText < lpchEnd) && (!fLastLine)) {
    01907           // Check if the line we are about to draw is the last line that needs
    01908           // to be drawn.
    01909           // Let us check if the display goes out of the clip rect and if so
    01910           // let us stop here, as an optimisation;
    01911           if (!CALCRECT(wFormat) &&         // We don't need to calc rect?
    01912                   (!NOCLIP(wFormat)) &&     // Must we clip the display ?
    01913                                             // Are we outside the rect?
    01914                   ((yLine + DrawInfo.cyLineHeight + yLastLineHeight)*iySign > (lprc->bottom*iySign))) {
    01915               fLastLine = TRUE;    // Let us quit this loop
    01916           }
    01917
    01918
    01919           /*
    01920            * We do the Ellipsis processing only for the last line.
    01921            */
    01922           if (fLastLine && (ENDELLIPSIS(dwDTformat) || PATHELLIPSIS(dwDTformat))) {
    01923               lpchText += AddEllipsisAndDrawLine(hdc, yLine, lpchText, cchText, dwDTformat, &DrawInfo, iCharset);
    01924           } else {
    01925               lpchNextLineSt = (LPWSTR)DT_GetLineBreak(hdc, lpchText, cchText, dwDTformat, &iLineLength, &DrawInfo, iCharset);
    01926
    01927               /*
    01928                * Check if we need to put ellipsis at the end of this line.
    01929                * Also check if this is the last line.
    01930                */
    01931               if (WORDELLIPSIS(dwDTformat) ||
    01932                        ((lpchNextLineSt >= lpchEnd) && (ENDELLIPSIS(dwDTformat) || PATHELLIPSIS(dwDTformat))))
    01933                   AddEllipsisAndDrawLine(hdc, yLine, lpchText, iLineLength, dwDTformat, &DrawInfo, iCharset);
    01934               else
    01935                   DT_DrawJustifiedLine(hdc, yLine, lpchText, iLineLength, dwDTformat, &DrawInfo, iCharset);
    01936               cchText -= (int)((PBYTE)lpchNextLineSt - (PBYTE)lpchText) / sizeof(WCHAR);
    01937               lpchText = lpchNextLineSt;
    01938           }
    01939             iLineCount++; // We draw one more line.
    01940             yLine += DrawInfo.cyLineHeight;
    01941         }
    01942
    01943
    01944         /*
    01945          * For Win3.1 and NT compatibility, if the last char is a CR or a LF
    01946          * then the height returned includes one more line.
    01947          */
    01948         if (!EDITCONTROL(dwDTformat) &&
    01949                 (lpchEnd > lpchTextBegin)    &&   // If zero length it will fault.
    01950                 (((ch = (*(lpchEnd-1))) == CR) || (ch == LF)))
    01951             yLine += DrawInfo.cyLineHeight;
    01952     }
    01953
    01954
    01955     /*
    01956      * If DT_CALCRECT, modify width and height of rectangle to include
    01957      * all of the text drawn.
    01958      */
    01959     if (CALCRECT(wFormat)) {
    01960         DrawInfo.rcFormat.right = DrawInfo.rcFormat.left + DrawInfo.cxMaxExtent * DrawInfo.iXSign;
    01961         lprc->right = DrawInfo.rcFormat.right + DrawInfo.cxRightMargin;
    01962
    01963         // If the Width is more than what was provided, we have to redo all
    01964         // the calculations, because, the number of lines can be less now.
    01965         // (We need to do this only if we have more than one line).
    01966         if((iLineCount > 1) && (DrawInfo.cxMaxExtent > DrawInfo.cxMaxWidth)) {
    01967             DrawInfo.cxMaxWidth = DrawInfo.cxMaxExtent;
    01968             lpchText = lpchTextBegin;
    01969             cchText = (int)((PBYTE)lpchEnd - (PBYTE)lpchTextBegin)/sizeof(WCHAR);
    01970             goto  ProcessDrawText;  // Start all over again!
    01971         }
    01972         lprc->bottom = yLine;
    01973     }
    01974
    01975 // if (!NOCLIP(wFormat))
    01976 // {
    01977 //     RestoreClipRgn(hdc, hrgnClip);
    01978 // }
    01979
    01980     if (hrgnClip != NULL) {
    01981         if (hrgnClip == (HRGN)-1) {
    01982             UserExtSelectClipRgn(hdc, NULL, RGN_COPY);
    01983         } else {
    01984             UserExtSelectClipRgn(hdc, hrgnClip, RGN_COPY);
    01985             UserDeleteObject(hrgnClip);
    01986         }
    01987     }
    01988
    01989     if(DrawInfo.bCharsetDll) {
    01990 #ifdef _USERK_
    01991         PTHREADINFO ptiCurrent = PtiCurrentShared();
    01992
    01993         if(CALL_LPK(ptiCurrent))
    01994 #endif // _USERK_
    01995             (*UserLpkDrawTextEx)(hdc, 0, 0, lpchText, cchText, FALSE, dwDTformat,
    01996                                  (LPDRAWTEXTDATA)&DrawInfo, DT_CHARSETDONE, iCharset);
    01997     }
    01998
    01999     if (RTLREADING(dwDTformat))
    02000         UserSetTextAlign(hdc, oldAlign);
    02001
    02002     /*
    02003      * Copy the number of characters actually drawn
    02004      */
    02005     if(lpDTparams != NULL)
    02006         lpDTparams->uiLengthDrawn = (UINT)((PBYTE)lpchText - (PBYTE)lpchTextBegin)/sizeof(WCHAR);
    02007
    02008     if (yLine == lprc->top)
    02009         return 1;
    02010
    02011     return (yLine - lprc->top);
    02012 }

BOOL CALLBACK EnumPwndDlgChildProc | ( | PWND | pwnd,
|  | LPARAM | lParam
| ) |

Definition at line 54 of file rtl/help.c.

References BOOL, FIsParentDude(), IsVisible(), PDLGENUMDATA, tagDLGENUMDATA::ptCurHelp, PtInRect(), tagDLGENUMDATA::pwndControl, tagDLGENUMDATA::pwndDialog, and TRUE.

Referenced by EnumHwndDlgChildProc().

    00055 {
    00056     PDLGENUMDATA pDlgEnumData = (PDLGENUMDATA)lParam;
    00057
    00058     if (pwnd != pDlgEnumData->pwndDialog && IsVisible(pwnd) &&
    00059             PtInRect(&((WND *)pwnd)->rcWindow, pDlgEnumData->ptCurHelp)) {
    00060         /*
    00061          * If it's a group box, keep enumerating. This takes care of
    00062          * the case where we have a disabled control in a group box.
    00063          * We'll find the group box first, and keep enumerating until we
    00064          * hit the disabled control.
    00065          */
    00066         pDlgEnumData->pwndControl = pwnd;
    00067         return (FIsParentDude(pwnd));
    00068     }
    00069     return TRUE;
    00070 }

__inline DWORD EqualRectInl | ( | LPCRECT | prc1,
|  | LPCRECT | prc2
| ) |

Definition at line 280 of file inc/user.h.

    00281 {
    00282     return RtlEqualMemory(prc1, prc2, sizeof(*prc1));
    00283 }

DWORD FindCharPosition | ( | LPWSTR | lpString,
|  | WCHAR | ch
| ) |

Definition at line 80 of file w32/ntuser/rtl/random.c.

References DWORD, and L.

Referenced by MNRecalcTabStrings(), xxxDlgDirListHelper(), xxxMNItemSize(), and xxxRealDrawMenuItem().

    00083 {
    00084     DWORD dwPos = 0L;
    00085
    00086     while (*lpString && *lpString != ch) {
    00087         ++lpString;
    00088         ++dwPos;
    00089     }
    00090     return dwPos;
    00091 }

int FindNCHit | ( | PWND | pwnd,
|  | LONG | lPt
| ) |

Definition at line 19 of file rtl/winmgr.c.

References _HasCaptionIcon(), CopyInflateRect(), FALSE, GET_X_LPARAM, GET_Y_LPARAM, GetWindowBorders(), InflateRect(), LOBYTE, PtInRect(), tagWND::rcClient, tagWND::rcWindow, SizeBoxHwnd(), SYSMETRTL, TestWF, TRUE, WEFCLIENTEDGE, WEFCONTEXTHELP, WEFDLGMODALFRAME, WEFLEFTSCROLL, WEFTOOLWINDOW, WFBORDERMASK, WFCAPTION, WFDLGFRAME, WFHPRESENT, WFMAXBOX, WFMINBOX, WFMINIMIZED, WFMPRESENT, WFSIZEBOX, WFSYSMENU, WFVPRESENT, and WFWIN40COMPAT.

Referenced by DefWindowProcWorker(), EditWndProc(), WinHelpA(), xxxDefWindowProc(), xxxDesktopThread(), xxxMNLoop(), and xxxTrackInitSize().

    00022 {
    00023     POINT pt;
    00024     RECT rcWindow;
    00025     RECT rcClient;
    00026     RECT rcClientAdj;
    00027     int cBorders;
    00028     int dxButton;
    00029
    00030     pt.x = GET_X_LPARAM(lPt);
    00031     pt.y = GET_Y_LPARAM(lPt);
    00032
    00033     if (!PtInRect(&((WND *)pwnd)->rcWindow, pt))
    00034         return HTNOWHERE;
    00035
    00036     if (TestWF(pwnd, WFMINIMIZED)) {
    00037         CopyInflateRect(&rcWindow, &((WND *)pwnd)->rcWindow,
    00038             -(SYSMETRTL(CXFIXEDFRAME) + SYSMETRTL(CXBORDER)), -(SYSMETRTL(CYFIXEDFRAME) + SYSMETRTL(CYBORDER)));
    00039
    00040         if (!PtInRect(&rcWindow, pt))
    00041             return HTCAPTION;
    00042
    00043         goto CaptionHit;
    00044     }
    00045
    00046     // Get client rectangle
    00047     rcClient = pwnd->rcClient;
    00048     if (PtInRect(&rcClient, pt))
    00049         return HTCLIENT;
    00050
    00051     // Are we in "pseudo" client, i.e. the client & scrollbars & border
    00052     if (TestWF(pwnd, WEFCLIENTEDGE))
    00053         CopyInflateRect(&rcClientAdj, &rcClient, SYSMETRTL(CXEDGE), SYSMETRTL(CYEDGE));
    00054     else
    00055         rcClientAdj = rcClient;
    00056
    00057     if (TestWF(pwnd, WFVPRESENT)) {
    00058 #ifdef USE_MIRRORING
    00059        if ((!!TestWF(pwnd, WEFLEFTSCROLL)) ^ (!!TestWF(pwnd, WEFLAYOUTRTL)))
    00060 #else
    00061        if (TestWF(pwnd, WEFLEFTSCROLL))
    00062 #endif
    00063            rcClientAdj.left -= SYSMETRTL(CXVSCROLL);
    00064        else
    00065            rcClientAdj.right += SYSMETRTL(CXVSCROLL);
    00066     }
    00067     if (TestWF(pwnd, WFHPRESENT))
    00068         rcClientAdj.bottom += SYSMETRTL(CYHSCROLL);
    00069
    00070     if (!PtInRect(&rcClientAdj, pt))
    00071     {
    00072         // Subtract out window borders
    00073         cBorders = GetWindowBorders(pwnd->style, pwnd->ExStyle, TRUE, FALSE);
    00074         CopyInflateRect(&rcWindow, &((WND *)pwnd)->rcWindow,
    00075             -cBorders*SYSMETRTL(CXBORDER), -cBorders*SYSMETRTL(CYBORDER));
    00076
    00077         // Are we on the border?
    00078         if (!PtInRect(&rcWindow, pt))
    00079         {
    00080             // On a sizing border?
    00081             if (!TestWF(pwnd, WFSIZEBOX)) {
    00082                 //
    00083                 // Old compatibility thing:  For 3.x windows that just had
    00084                 // a border, we returned HTNOWHERE, believe it or not,
    00085                 // because our hit-testing code was so brain dead.
    00086                 //
    00087                 if (!TestWF(pwnd, WFWIN40COMPAT) &&
    00088                         !TestWF(pwnd, WFDLGFRAME)    &&
    00089                         !TestWF(pwnd, WEFDLGMODALFRAME)) {
    00090                     return(HTNOWHERE);
    00091
    00092                 } else {
    00093                     return(HTBORDER);  // We are on a dlg frame.
    00094                 }
    00095             } else {
    00096
    00097                 int ht;
    00098
    00099                 //
    00100                 // Note this improvement.  The HT codes are numbered so that
    00101                 // if you subtract HTSIZEFIRST-1 from them all, they sum up.  I.E.,
    00102                 // (HTLEFT - HTSIZEFIRST + 1) + (HTTOP - HTSIZEFIRST + 1) ==
    00103                 // (HTTOPLEFT - HTSIZEFIRST + 1).
    00104                 //
    00105
    00106                 if (TestWF(pwnd, WEFTOOLWINDOW))
    00107                     InflateRect(&rcWindow, -SYSMETRTL(CXSMSIZE), -SYSMETRTL(CYSMSIZE));
    00108                 else
    00109                     InflateRect(&rcWindow, -SYSMETRTL(CXSIZE), -SYSMETRTL(CYSIZE));
    00110
    00111                 if (pt.y < rcWindow.top)
    00112                     ht = (HTTOP - HTSIZEFIRST + 1);
    00113                 else if (pt.y >= rcWindow.bottom)
    00114                     ht = (HTBOTTOM - HTSIZEFIRST + 1);
    00115                 else
    00116                     ht = 0;
    00117
    00118                 if (pt.x < rcWindow.left)
    00119                     ht += (HTLEFT - HTSIZEFIRST + 1);
    00120                 else if (pt.x >= rcWindow.right)
    00121                     ht += (HTRIGHT - HTSIZEFIRST + 1);
    00122
    00123                 return (ht + HTSIZEFIRST - 1);
    00124             }
    00125         }
    00126
    00127         // Are we above the client area?
    00128         if (pt.y < rcClientAdj.top)
    00129         {
    00130             // Are we in the caption?
    00131             if (TestWF(pwnd, WFBORDERMASK) == LOBYTE(WFCAPTION))
    00132             {
    00133 CaptionHit:
    00134
    00135 #ifdef USE_MIRRORING
    00136                 if (TestWF(pwnd, WEFLAYOUTRTL)) {
    00137                     pt.x = pwnd->rcWindow.right - (pt.x - pwnd->rcWindow.left);
    00138                 }
    00139 #endif
    00140
    00141                 if (pt.y >= rcWindow.top)
    00142                 {
    00143                     if (TestWF(pwnd, WEFTOOLWINDOW))
    00144                     {
    00145                         rcWindow.top += SYSMETRTL(CYSMCAPTION);
    00146                         dxButton = SYSMETRTL(CXSMSIZE);
    00147                     }
    00148                     else
    00149                     {
    00150                         rcWindow.top += SYSMETRTL(CYCAPTION);
    00151                         dxButton = SYSMETRTL(CXSIZE);
    00152                     }
    00153
    00154                     if ((pt.y >= rcWindow.top) && TestWF(pwnd, WFMPRESENT))
    00155                         return(HTMENU);
    00156
    00157                     if ((pt.x >= rcWindow.left)  &&
    00158                         (pt.x <  rcWindow.right) &&
    00159                         (pt.y <  rcWindow.top))
    00160                     {
    00161                         // Are we in the window menu?
    00162                         if (TestWF(pwnd, WFSYSMENU))
    00163                         {
    00164                             rcWindow.left += dxButton;
    00165                             if (pt.x < rcWindow.left)
    00166                             {
    00167                                 if (!_HasCaptionIcon(pwnd))
    00168                                 // iconless windows have no sysmenu hit rect
    00169                                     return(HTCAPTION);
    00170
    00171                                 return(HTSYSMENU);
    00172                             }
    00173                         }
    00174                         else if (TestWF(pwnd, WFWIN40COMPAT))
    00175                             return(HTCAPTION);
    00176
    00177                         // only a close button if window has a system menu
    00178
    00179                         // Are we in the close button?
    00180                         rcWindow.right -= dxButton;
    00181                         if (pt.x >= rcWindow.right)
    00182                             return HTCLOSE;
    00183
    00184                         if ((pt.x < rcWindow.right) && !TestWF(pwnd, WEFTOOLWINDOW))
    00185                         {
    00186                             // Are we in the maximize/restore button?
    00187                             if (TestWF(pwnd, (WFMAXBOX | WFMINBOX)))
    00188                             {
    00189                                 // Note that sizing buttons are same width for both
    00190                                 // big captions and small captions.
    00191                                 rcWindow.right -= dxButton;
    00192                                 if (pt.x >= rcWindow.right)
    00193                                     return HTZOOM;
    00194
    00195                                 // Are we in the minimize button?
    00196                                 rcWindow.right -= dxButton;
    00197                                 if (pt.x >= rcWindow.right)
    00198                                     return HTREDUCE;
    00199                             }
    00200                             else if (TestWF(pwnd, WEFCONTEXTHELP))
    00201                             {
    00202                                 rcWindow.right -= dxButton;
    00203                                 if (pt.x >= rcWindow.right)
    00204                                     return HTHELP;
    00205                             }
    00206                         }
    00207                     }
    00208                 }
    00209
    00210                 // We're in the caption proper
    00211                 return HTCAPTION;
    00212             }
    00213
    00214             //
    00215             // Are we in the menu?
    00216             //
    00217             if (TestWF(pwnd, WFMPRESENT))
    00218                 return HTMENU;
    00219         }
    00220     }
    00221     else
    00222     {
    00223         //
    00224         // NOTE:
    00225         // We can only be here if we are on the client edge, horz scroll,
    00226         // sizebox, or vert scroll.  Hence, if we are not on the first 3,
    00227         // we must be on the last one.
    00228         //
    00229
    00230         //
    00231         // Are we on the client edge?
    00232         //
    00233         if (TestWF(pwnd, WEFCLIENTEDGE))
    00234         {
    00235             InflateRect(&rcClientAdj, -SYSMETRTL(CXEDGE), -SYSMETRTL(CYEDGE));
    00236             if (!PtInRect(&rcClientAdj, pt))
    00237                 return(HTBORDER);
    00238         }
    00239
    00240         //
    00241         // Are we on the scrollbars?
    00242         //
    00243         if (TestWF(pwnd, WFHPRESENT) && (pt.y >= rcClient.bottom))
    00244         {
    00245             int iHitTest=HTHSCROLL;
    00246             UserAssert(pt.y < rcClientAdj.bottom);
    00247
    00248             if (TestWF(pwnd, WFVPRESENT)) {
    00249                 PWND pwndSizeBox = SizeBoxHwnd(pwnd);
    00250
    00251                 if(pt.x >= rcClient.right)
    00252                     return(pwndSizeBox ? HTBOTTOMRIGHT : HTGROWBOX);
    00253 #ifdef USE_MIRRORING
    00254                 //
    00255                 // Mirror the grip box location so that it becomes
    00256                 // on the bottom-left side if this is a RTL mirrrored
    00257                 // windows.
    00258                 //
    00259                 else if (TestWF(pwnd, WEFLAYOUTRTL) && (pt.x < rcClient.left))
    00260                     return(pwndSizeBox ? HTBOTTOMLEFT : HTGROWBOX);
    00261 #endif
    00262             }
    00263
    00264             return(iHitTest);
    00265         }
    00266         else
    00267         {
    00268             UserAssert(TestWF(pwnd, WFVPRESENT));
    00269 #ifdef USE_MIRRORING
    00270             if ((!!TestWF(pwnd, WEFLEFTSCROLL)) ^ (!!TestWF(pwnd, WEFLAYOUTRTL))) {
    00271 #else
    00272             if (TestWF(pwnd, WEFLEFTSCROLL)) {
    00273 #endif
    00274                 UserAssert(pt.x < rcClient.left);
    00275                 UserAssert(pt.x >= rcClientAdj.left);
    00276             } else {
    00277                 UserAssert(pt.x >= rcClient.right);
    00278                 UserAssert(pt.x < rcClientAdj.right);
    00279             }
    00280             return(HTVSCROLL);
    00281         }
    00282     }
    00283
    00284     //
    00285     // We give up.
    00286     //
    00287     // Win31 returned HTNOWHERE in this case; For compatibility, we will
    00288     // keep it that way.
    00289     //
    00290     return(HTNOWHERE);
    00291
    00292 }

BOOL FIsParentDude | ( | PWND | pwnd | ) |

Definition at line 12 of file rtl/help.c.

References BFTYPEMASK, BOOL, FNID_BUTTON, GETFNID, TestWF, WEFCONTROLPARENT, and WFDIALOGWINDOW.

Referenced by EnumPwndDlgChildProc(), WinHelpA(), and xxxHelpLoop().

    00013 {
    00014     return(TestWF(pwnd, WEFCONTROLPARENT) || TestWF(pwnd, WFDIALOGWINDOW) ||
    00015         ((GETFNID(pwnd) == FNID_BUTTON) &&
    00016          (TestWF(pwnd, BFTYPEMASK) == BS_GROUPBOX)));
    00017 }

LRESULT CALLBACK fnHkINDWORD | ( | DWORD | nCode,
|  | WPARAM | wParam,
|  | LPARAM | lParam,
|  | ULONG_PTR | xParam,
|  | PROC | xpfnProc,
|  | LPDWORD | lpFlags
| ) |

| Referenced by xxxHkCallHook().

LRESULT CALLBACK fnHkINLPCBTACTIVATESTRUCT | ( | DWORD | nCode,
|  | WPARAM | wParam,
|  | LPCBTACTIVATESTRUCT | lParam,
|  | ULONG_PTR | xParam,
|  | PROC | xpfnProc
| ) |

| Referenced by xxxHkCallHook().

LRESULT CALLBACK fnHkINLPCBTCSTRUCT | ( | UINT | msg,
|  | WPARAM | wParam,
|  | LPCBT_CREATEWND | pcbt,
|  | PROC | xpfnProc,
|  | BOOL | bAnsi
| ) |

LRESULT CALLBACK fnHkINLPCBTMDICCSTRUCT | ( | UINT | msg,
|  | WPARAM | wParam,
|  | LPCBT_CREATEWND | pcbt,
|  | PROC | xpfnProc,
|  | BOOL | bAnsi
| ) |

LRESULT CALLBACK fnHkINLPDEBUGHOOKSTRUCT | ( | DWORD | nCode,
|  | WPARAM | wParam,
|  | LPDEBUGHOOKINFO | lParam,
|  | ULONG_PTR | xParam,
|  | PROC | xpfnProc
| ) |

| Referenced by xxxHkCallHook().

LRESULT CALLBACK fnHkINLPKBDLLHOOKSTRUCT | ( | DWORD | nCode,
|  | WPARAM | wParam,
|  | LPKBDLLHOOKSTRUCT | lParam,
|  | ULONG_PTR | xParam,
|  | PROC | xpfnProc
| ) |

| Referenced by xxxHkCallHook().

LRESULT CALLBACK fnHkINLPMOUSEHOOKSTRUCTEX | ( | DWORD | nCode,
|  | WPARAM | wParam,
|  | LPMOUSEHOOKSTRUCTEX | lParam,
|  | ULONG_PTR | xParam,
|  | PROC | xpfnProc,
|  | LPDWORD | lpFlags
| ) |

| Referenced by xxxHkCallHook().

LRESULT CALLBACK fnHkINLPMSG | ( | DWORD | nCode,
|  | WPARAM | wParam,
|  | LPMSG | lParam,
|  | ULONG_PTR | xParam,
|  | PROC | xpfnProc,
|  | BOOL | bAnsi,
|  | LPDWORD | lpFlags
| ) |

| Referenced by xxxHkCallHook().

LRESULT CALLBACK fnHkINLPMSLLHOOKSTRUCT | ( | DWORD | nCode,
|  | WPARAM | wParam,
|  | LPMSLLHOOKSTRUCT | lParam,
|  | ULONG_PTR | xParam,
|  | PROC | xpfnProc
| ) |

| Referenced by xxxHkCallHook().

LRESULT CALLBACK fnHkINLPRECT | ( | DWORD | nCode,
|  | WPARAM | wParam,
|  | LPRECT | lParam,
|  | ULONG_PTR | xParam,
|  | PROC | xpfnProc
| ) |

| Referenced by xxxHkCallHook().

LRESULT CALLBACK fnHkOPTINLPEVENTMSG | ( | DWORD | nCode,
|  | WPARAM | wParam,
|  | LPEVENTMSGMSG | lParam,
|  | ULONG_PTR | xParam,
|  | PROC | xpfnProc
| ) |

| Referenced by xxxHkCallHook().

DWORD GetAppCompatFlags | ( | PTHREADINFO | pti | ) |

Definition at line 494 of file winmgrc.c.

References ConnectIfNecessary, tagTHREADINFO::dwCompatFlags, DWORD, GetClientInfo, NULL, and PtiCurrentShared.

Referenced by _GetWindow(), InternalInvalidate2(), LBGetScrollFlags(), xxxCalcValidRects(), xxxCreateWindowEx(), and xxxDoScrollMenu().

    00496 {
    00497     UNREFERENCED_PARAMETER(pti);
    00498
    00499     ConnectIfNecessary();
    00500
    00501     return GetClientInfo()->dwCompatFlags;
    00502 }

DWORD GetAppCompatFlags2 | ( | WORD | wVer | ) |

Definition at line 514 of file winmgrc.c.

References ConnectIfNecessary, DWORD, GetAppCompatFlags2ForPti(), GETAPPVER, GetClientInfo, and PtiCurrentShared.

Referenced by DispatchMessageWorker(), NtUserCreateWindowEx(), UnlinkConvFromOthers(), xxxCBShowListBoxWindow(), xxxDDETrackGetMessageHook(), xxxDDETrackWindowDying(), xxxDrawMenuBarUnderlines(), xxxDrawMenuItemText(), xxxInternalToUnicode(), xxxMenuBarDraw(), xxxMenuWindowProc(), xxxSetWindowStyle(), and zzzHideCursorNoCapture().

    00516 {
    00517     ConnectIfNecessary();
    00518     /*
    00519      * Newer apps should behave, so they get no hacks
    00520      */
    00521     if (wVer < GETAPPVER()) {
    00522         return 0;
    00523     }
    00524     return GetClientInfo()->dwCompatFlags2;
    00525 }

DWORD GetAppImeCompatFlags | ( | PTHREADINFO | pti | ) |

Definition at line 1039 of file queue.c.

References tagPROCESSINFO::dwImeCompatFlags, DWORD, NULL, tagTHREADINFO::ppi, and PtiCurrentShared.

Referenced by NlsKbdSendIMEProc(), xxxButtonEvent(), xxxImmProcessKey(), and xxxScanSysQueue().

    01041 {
    01042     if (pti == NULL) {
    01043         pti = PtiCurrentShared();
    01044     }
    01045
    01046     UserAssert(pti->ppi);
    01047     return pti->ppi->dwImeCompatFlags;
    01048 }

int GetCharDimensions | ( | HDC | hDC,
|  | TEXTMETRICW * | lpTextMetrics,
|  | LPINT | lpcy
| ) |

DWORD GetContextHelpId | ( | PWND | pwnd | ) |

Definition at line 28 of file rtl/help.c.

    00030 {
    00031     DWORD  dwContextId;
    00032
    00033     while (!(dwContextId = (DWORD)(ULONG_PTR)_GetProp(pwnd,
    00034             MAKEINTATOM(gpsi->atomContextHelpIdProp), PROPF_INTERNAL))) {
    00035         pwnd = (TestwndChild(pwnd) ?
    00036                 REBASEPWND(pwnd, spwndParent) :
    00037                 REBASEPWND(pwnd, spwndOwner));
    00038         if (!pwnd || (GETFNID(pwnd) == FNID_DESKTOP))
    00039             break;
    00040     }
    00041
    00042     return dwContextId;
    00043 }

ULONG_PTR GetCPD | ( | PVOID | pWndOrCls,
|  | DWORD | options,
|  | ULONG_PTR | dwData
| ) |

Definition at line 1789 of file clmsg.c.

References BOOL, CALLPROCDATA, CheckCritIn, CPD_ANSI_TO_UNICODE, CPD_CLASS, CPD_DIALOG, CPD_UNICODE_TO_ANSI, CPD_WND, CPD_WNDTOCLS, CSF_ANSIPROC, tagCLS::CSF_flags, FindPCPD(), HMAllocObject(), HW, ISCPDTAG, Lock, MAKE_CPDHANDLE, NtUserGetCPD(), NULL, _CALLPROCDATA::pfnClientPrevious, PtiCurrent, PtoH, tagTHREADINFO::rpdesk, tagCLS::spcpdFirst, _CALLPROCDATA::spcpdNext, TestWF, TYPE_CALLPROC, WFANSIPROC, and _CALLPROCDATA::wType.

Referenced by _GetClassData(), _GetClassInfoEx(), _GetWindowLongPtr(), _SetWindowLongPtr(), GetWindowData(), NtUserGetCPD(), xxxSetClassData(), and xxxSetWindowData().

    01793 {
    01794     return NtUserGetCPD(HW(pWndOrCls), options, dwData);
    01795 }

__inline WORD GetInputBits | ( | PCLIENTTHREADINFO | pcti,
|  | WORD | fsWakeMask,
|  | BOOL | fAvailable
| ) |

Definition at line 3067 of file inc/user.h.

References tagCLIENTTHREADINFO::fsChangeBits, and tagCLIENTTHREADINFO::fsWakeBits.

Referenced by MsgWaitForMultipleObjectsEx(), and xxxGetInputEvent().

    03068 {
    03069     return (pcti->fsChangeBits  | (fAvailable ? pcti->fsWakeBits : 0)) & fsWakeMask;
    03070 }

LONG GetPrefixCount | ( | LPCWSTR | lpstr,
|  | int | cb,
|  | LPWSTR | lpstrCopy,
|  | int | cbCopy
| ) |

Definition at line 806 of file rtl/drawtext.c.

References CH_ENGLISHPREFIX, CH_KANJIPREFIX, CH_PREFIX, and NULL.

Referenced by DT_GetExtentMinusPrefixes(), PSMGetTextExtent(), UserLpkPSMTextOut(), xxxDrawMenuBarUnderlines(), xxxDrawMenuItemText(), and xxxPSMTextOut().

    00811 {
    00812     int chprintpos = 0;         /* Num of chars that will be printed */
    00813     int chcount = 0;            /* Num of prefix chars that will be removed */
    00814     int chprefixloc = -1;       /* Pos (in printed chars) of the prefix */
    00815     WCHAR ch;
    00816
    00817     /*
    00818      * If not copying, use a large bogus count...
    00819      */
    00820     if (lpstrCopy == NULL)
    00821         charcopycount = 32767;
    00822
    00823     while ((cch-- > 0) && *lpstr && charcopycount-- != 0) {
    00824
    00825         /*
    00826          * Is this guy a prefix character ?
    00827          */
    00828         if ((ch = *lpstr++) == CH_PREFIX) {
    00829
    00830             /*
    00831              * Yup - increment the count of characters removed during print.
    00832              */
    00833             chcount++;
    00834
    00835             /*
    00836              * Is the next also a prefix char?
    00837              */
    00838             if (*lpstr != CH_PREFIX) {
    00839
    00840                 /*
    00841                  * Nope - this is a real one, mark its location.
    00842                  */
    00843                 chprefixloc = chprintpos;
    00844
    00845             } else {
    00846
    00847                 /*
    00848                  * yup - simply copy it if copying.
    00849                  */
    00850                 if (lpstrCopy != NULL)
    00851                     *(lpstrCopy++) = CH_PREFIX;
    00852                 cch--;
    00853                 lpstr++;
    00854                 chprintpos++;
    00855             }
    00856         } else if (ch == CH_ENGLISHPREFIX) {    // Still needs to be parsed
    00857             /*
    00858              * Yup - increment the count of characters removed during print.
    00859              */
    00860             chcount++;
    00861
    00862             /*
    00863              * Next character is a real one, mark its location.
    00864              */
    00865             chprefixloc = chprintpos;
    00866
    00867         } else if (ch == CH_KANJIPREFIX) {      // Still needs to be parsed
    00868             /*
    00869              * We only support Alpha Numeric(CH_ENGLISHPREFIX).
    00870              * no support for Kana(CH_KANJIPREFIX).
    00871              */
    00872             /*
    00873              * Yup - increment the count of characters removed during print.
    00874              */
    00875             chcount++;
    00876
    00877             if(cch) {
    00878                 /* don't copy the character */
    00879                 chcount++;
    00880                 lpstr++;
    00881                 cch--;
    00882             }
    00883         } else {
    00884
    00885             /*
    00886              * Nope - just inc count of char.  that will be printed
    00887              */
    00888             chprintpos++;
    00889             if (lpstrCopy != NULL)
    00890                 *(lpstrCopy++) = ch;
    00891         }
    00892     }
    00893
    00894     if (lpstrCopy != NULL)
    00895         *lpstrCopy = 0;
    00896
    00897     /*
    00898      * Return the character counts
    00899      */
    00900     return MAKELONG(chprefixloc, chcount);
    00901 }

PWND GetPrevPwnd | ( | PWND | pwndList,
|  | PWND | pwndFind
| ) |

Definition at line 631 of file rtl/wow.c.

References NULL, REBASEPWND, and tagWND::spwndParent.

Referenced by _GetWindow().

    00634 {
    00635     PWND pwndFound, pwndNext;
    00636
    00637     if (pwndList == NULL)
    00638         return NULL;
    00639
    00640     if (pwndList->spwndParent == NULL)
    00641         return NULL;
    00642
    00643     pwndNext = REBASEPWND(pwndList, spwndParent);
    00644     pwndNext = REBASEPWND(pwndNext, spwndChild);
    00645     pwndFound = NULL;
    00646
    00647     while (pwndNext != NULL) {
    00648         if (pwndNext == pwndFind)
    00649             break;
    00650         pwndFound = pwndNext;
    00651         pwndNext = REBASEPWND(pwndNext, spwndNext);
    00652     }
    00653
    00654     return (pwndNext == pwndFind) ? pwndFound : NULL;
    00655 }

void GetRealClientRect | ( | PWND | pwnd,
|  | LPRECT | prc,
|  | UINT | uFlags,
|  | PMONITOR | pMonitor
| ) |

Definition at line 417 of file rtl/winmgr.c.

References FNID_DESKTOP, GETFNID, GetPrimaryMonitor(), GetRect(), GRC_FULLSCREEN, GRC_MINWNDS, GRC_SCROLLS, GRECT_CLIENT, GRECT_CLIENTCOORDS, tagMONITOR::rcMonitor, tagMONITOR::rcWork, SYSMETRTL, TestWF, WFHPRESENT, and WFVPRESENT.

Referenced by GetParentArrangeRect(), ParkIcon(), SetTiledRect(), and xxxArrangeIconicWindows().

    00423 {
    00424     if (GETFNID(pwnd) == FNID_DESKTOP) {
    00425         if (!pMonitor) {
    00426             pMonitor = GetPrimaryMonitor();
    00427         }
    00428         *prc = (uFlags & GRC_FULLSCREEN) ? pMonitor->rcMonitor : pMonitor->rcWork;
    00429     } else {
    00430         GetRect(pwnd, prc, GRECT_CLIENT | GRECT_CLIENTCOORDS);
    00431         if (uFlags & GRC_SCROLLS) {
    00432             if (TestWF(pwnd, WFHPRESENT)){
    00433                 prc->bottom += SYSMETRTL(CYHSCROLL);
    00434             }
    00435
    00436             if (TestWF(pwnd, WFVPRESENT)) {
    00437                 prc->right += SYSMETRTL(CXVSCROLL);
    00438             }
    00439         }
    00440     }
    00441
    00442     if (uFlags & GRC_MINWNDS) {
    00443         switch (SYSMETRTL(ARRANGE) & ~ARW_HIDE) {
    00444             case ARW_TOPLEFT | ARW_RIGHT:
    00445             case ARW_TOPRIGHT | ARW_LEFT:
    00446                 //
    00447                 // Leave space on top for one row of min windows
    00448                 //
    00449                 prc->top += SYSMETRTL(CYMINSPACING);
    00450                 break;
    00451
    00452             case ARW_TOPLEFT | ARW_DOWN:
    00453             case ARW_BOTTOMLEFT | ARW_UP:
    00454                 //
    00455                 // Leave space on left for one column of min windows
    00456                 //
    00457                 prc->left += SYSMETRTL(CXMINSPACING);
    00458                 break;
    00459
    00460             case ARW_TOPRIGHT | ARW_DOWN:
    00461             case ARW_BOTTOMRIGHT | ARW_UP:
    00462                 //
    00463                 // Leave space on right for one column of min windows
    00464                 //
    00465                 prc->right -= SYSMETRTL(CXMINSPACING);
    00466                 break;
    00467
    00468             case ARW_BOTTOMLEFT | ARW_RIGHT:
    00469             case ARW_BOTTOMRIGHT | ARW_LEFT:
    00470                 //
    00471                 // Leave space on bottom for one row of min windows
    00472                 //
    00473                 prc->bottom -= SYSMETRTL(CYMINSPACING);
    00474                 break;
    00475         }
    00476     }
    00477 }

void GetRect | ( | PWND | pwnd,
|  | LPRECT | lprc,
|  | UINT | uCoords
| ) |

Definition at line 856 of file rtl/winmgr.c.

References FNID_DESKTOP, GETFNID, GRECT_CLIENTCOORDS, GRECT_COORDMASK, GRECT_PARENTCOORDS, GRECT_RECTMASK, GRECT_WINDOW, GRECT_WINDOWCOORDS, OffsetRect(), tagWND::rcClient, tagWND::rcWindow, REBASEPWND, TestWF, and WFCHILD.

Referenced by _GetScrollBarInfo(), CalcSBStuff(), GetRealClientRect(), MDICheckCascadeRect(), ParkIcon(), SBCtlSetup(), UpdateCheckpoint(), UT_GetParentDCClipBox(), xxxCalcValidRects(), xxxDrawCaptionBar(), xxxDrawWindowFrame(), xxxMinMaximize(), xxxScrollWindowEx(), and xxxSetStaticImage().

    00857 {
    00858     PWND    pwndParent;
    00859     LPRECT  lprcOffset;
    00860
    00861     UserAssert(lprc);
    00862     UserAssert((uCoords & ~(GRECT_COORDMASK | GRECT_RECTMASK)) == 0);
    00863     UserAssert(uCoords & GRECT_COORDMASK);
    00864     UserAssert(uCoords & GRECT_RECTMASK);
    00865
    00866     *lprc = (uCoords & GRECT_WINDOW) ? pwnd->rcWindow : pwnd->rcClient;
    00867
    00868     /*
    00869      * If this is the desktop window, we have what we want, whether we
    00870      * are asking for GRECT_PARENTCOORDS, WINDOWCOORD or CLIENTCOORDS
    00871      */
    00872     if (GETFNID(pwnd) == FNID_DESKTOP)
    00873         return;
    00874
    00875     switch (uCoords & GRECT_COORDMASK) {
    00876     case GRECT_PARENTCOORDS:
    00877         pwndParent = REBASEPWND(pwnd, spwndParent);
    00878         if (GETFNID(pwndParent) == FNID_DESKTOP)
    00879             return;
    00880
    00881         lprcOffset = &pwndParent->rcClient;
    00882
    00883 #if defined(USE_MIRRORING)
    00884         //
    00885         // Let's mirror the edges of the child's window since the parent
    00886         // is mirrored, so should the child window be. [samera]
    00887         //
    00888         if (TestWF(pwndParent,WEFLAYOUTRTL) &&
    00889                 (uCoords & GRECT_WINDOW) &&
    00890                 (TestWF(pwnd,WFCHILD))) {
    00891             int iLeft;
    00892
    00893             //
    00894             // I am using OffsetRect instead of implementing a new
    00895             // OffsetMirrorRect API since this is the only place I am
    00896             // doing it in.
    00897             //
    00898             // Since screen coordinates are not mirrored, the rect offsetting
    00899             // should be done relative to prcOffset->right since it is the
    00900             // leading edge for mirrored windows. [samera]
    00901             //
    00902
    00903             UserVerify(OffsetRect(lprc, -lprcOffset->right, -lprcOffset->top));
    00904
    00905             iLeft = lprc->left;
    00906             lprc->left  = (lprc->right * -1);
    00907             lprc->right = (iLeft * -1);
    00908
    00909             return;
    00910         }
    00911 #endif
    00912
    00913         break;
    00914
    00915     case GRECT_WINDOWCOORDS:
    00916         lprcOffset = &pwnd->rcWindow;
    00917         break;
    00918
    00919     case GRECT_CLIENTCOORDS:
    00920         lprcOffset = &pwnd->rcClient;
    00921         break;
    00922
    00923     default:
    00924         UserAssert(0 && "Logic error in _GetRect - invalid uCoords");
    00925     }
    00926
    00927     UserVerify(OffsetRect(lprc, -lprcOffset->left, -lprcOffset->top));
    00928 }

PWND GetTopLevelWindow | ( | PWND | pwnd | ) |

Definition at line 817 of file rtl/winmgr.c.

References NULL, REBASEPWND, and TestwndChild.

Referenced by _GetNextQueueWindow(), _SelectPalette(), ConvertRedirectionDCs(), GetLayeredWindow(), ImeSetContextHandler(), InternalDialogBox(), NtUserSetImeOwnerWindow(), RecreateRedirectionBitmap(), WinHelpA(), xxxActivateThisWindow(), xxxButtonEvent(), xxxCreateWindowEx(), xxxDefWindowProc(), xxxDesktopWndProc(), xxxDrawMenuBarUnderlines(), xxxDWP_ProcessVirtKey(), xxxHandleNCMouseGuys(), xxxNextWindow(), and xxxSetForegroundWindow().

    00819 {
    00820     if (pwnd != NULL) {
    00821         while (TestwndChild(pwnd))
    00822             pwnd = REBASEPWND(pwnd, spwndParent);
    00823     }
    00824
    00825     return pwnd;
    00826 }

int GetWindowBorders | ( | LONG | lStyle,
|  | DWORD | dwExStyle,
|  | BOOL | fWindow,
|  | BOOL | fClient
| ) |

Definition at line 582 of file rtl/winmgr.c.

References gpsi.

Referenced by _AdjustWindowRectEx(), DefFrameProcWorker(), FindNCHit(), GetWindowInfo(), MNPositionSysMenu(), xxxAnimateCaption(), xxxCalcCaptionButton(), xxxCalcClientRect(), xxxCheckFullScreen(), xxxDrawCaptionBar(), xxxDrawWindowFrame(), xxxDWP_DoNCActivate(), xxxGetMenuBarInfo(), xxxGetTitleBarInfo(), xxxHelpLoop(), xxxInitSendValidateMinMaxInfo(), xxxLBSize(), xxxMNFindWindowFromPoint(), and xxxMNRecomputeBarIfNeeded().

    00583 {
    00584     int cBorders = 0;
    00585
    00586     if (fWindow) {
    00587         //
    00588         // Is there a 3D border around the window?
    00589         //
    00590         if (dwExStyle & WS_EX_WINDOWEDGE)
    00591             cBorders += 2;
    00592         else if (dwExStyle & WS_EX_STATICEDGE)
    00593             ++cBorders;
    00594
    00595         //
    00596         // Is there a single flat border around the window?  This is true for
    00597         // WS_BORDER, WS_DLGFRAME, and WS_EX_DLGMODALFRAME windows.
    00598         //
    00599         if ( (lStyle & WS_CAPTION) || (dwExStyle & WS_EX_DLGMODALFRAME) )
    00600                 ++cBorders;
    00601
    00602         //
    00603         // Is there a sizing flat border around the window?
    00604         //
    00605         if (lStyle & WS_SIZEBOX)
    00606                 cBorders += gpsi->gclBorder;
    00607     }
    00608
    00609     if (fClient) {
    00610             //
    00611             // Is there a 3D border around the client?
    00612             //
    00613             if (dwExStyle & WS_EX_CLIENTEDGE)
    00614             cBorders += 2;
    00615     }
    00616
    00617     return(cBorders);
    00618 }

PVOID FASTCALL HMValidateCatHandleNoRip | ( | HANDLE | h,
|  | BYTE | btype
| ) |

PVOID FASTCALL HMValidateCatHandleNoSecure | ( | HANDLE | h,
|  | BYTE | bType
| ) |

| Referenced by HMAssignmentLock().

PVOID FASTCALL HMValidateCatHandleNoSecureCCX | ( | HANDLE | h,
|  | BYTE | bType,
|  | PCLIENTINFO | ccxPci
| ) |

PVOID FASTCALL HMValidateHandle | ( | HANDLE | h,
|  | BYTE | btype
| ) |

Definition at line 150 of file rtl/wow.c.

References CHECK_RESTRICTED, DWORD, _CLIENTINFO::dwTIFlags, FASTCALL, GET_CURRENT_CLIENTINFO, HMUniqFromHandle, NULL, TIF_16BIT, TYPE_ACCELTABLE, TYPE_CURSOR, TYPE_HOOK, TYPE_MENU, TYPE_MONITOR, TYPE_SETWINDOWPOS, TYPE_WINDOW, and ValidateHandleMacro.

Referenced by _MapDesktopObject(), _SetCursorIconData(), DestroyInputContext(), ImeIsUsableContext(), ImeMarkUsedContext(), ImmCallImeConsoleIME(), ImmLockClientImc(), IsMenu(), NtUserCreateLocalMemHandle(), NtUserUserHandleGrantAccess(), SetClassCursor(), ValidateHmenu(), ValidateHwnd(), xxxGetDummyPalette(), and xxxQueryDropObject().

    00153 {
    00154     DWORD       dwError;
    00155     KERNEL_PVOID pobj = NULL;
    00156     PCLIENTINFO pci;
    00157
    00158     GET_CURRENT_CLIENTINFO();
    00159
    00160 #if DBG != 0 && !defined(_USERK_)
    00161     /*
    00162      * We don't want 32 bit apps passing 16 bit handles
    00163      *  we should consider failing this before we get
    00164      *  stuck supporting it (Some VB apps do this).
    00165      */
    00166     if (pci && (h != NULL)
    00167            && (HMUniqFromHandle(h) == 0)
    00168            && !(pci->dwTIFlags & TIF_16BIT)) {
    00169         RIPMSG3(RIP_WARNING, "HMValidateHandle: 32bit process [%d] using 16 bit handle [%#p] bType:%#lx",
    00170                 HandleToUlong(NtCurrentTeb()->ClientId.UniqueProcess), h, (DWORD)bType);
    00171     }
    00172 #endif
    00173
    00174     /*
    00175      * Object can't be located in shared memory.
    00176      */
    00177     UserAssert(bType != TYPE_MONITOR);
    00178
    00179     /*
    00180      * Validation macro. Falls through if the handle is invalid.
    00181      */
    00182     ValidateHandleMacro(pci, pobj, h, bType);
    00183
    00184     /*
    00185      * check for secure process
    00186      */
    00187     CHECK_RESTRICTED();
    00188
    00189     if (pobj != NULL) {
    00190         return pobj;
    00191     }
    00192
    00193     switch (bType) {
    00194
    00195     case TYPE_WINDOW:
    00196         dwError = ERROR_INVALID_WINDOW_HANDLE;
    00197         break;
    00198
    00199     case TYPE_MENU:
    00200         dwError = ERROR_INVALID_MENU_HANDLE;
    00201         break;
    00202
    00203     case TYPE_CURSOR:
    00204         dwError = ERROR_INVALID_CURSOR_HANDLE;
    00205         break;
    00206
    00207     case TYPE_ACCELTABLE:
    00208         dwError = ERROR_INVALID_ACCEL_HANDLE;
    00209         break;
    00210
    00211     case TYPE_HOOK:
    00212         dwError = ERROR_INVALID_HOOK_HANDLE;
    00213         break;
    00214
    00215     case TYPE_SETWINDOWPOS:
    00216         dwError = ERROR_INVALID_DWP_HANDLE;
    00217         break;
    00218
    00219     default:
    00220         dwError = ERROR_INVALID_HANDLE;
    00221         break;
    00222     }
    00223
    00224     RIPERR2(dwError,
    00225             RIP_WARNING,
    00226             "HMValidateHandle: Invalid:%#p Type:%#lx",
    00227             h, (DWORD)bType);
    00228
    00229     /*
    00230      * If we get here, it's an error.
    00231      */
    00232     return NULL;
    00233 }

KERNEL_PVOID FASTCALL HMValidateHandleNoDesktop | ( | HANDLE | h,
|  | BYTE | btype
| ) |

| Referenced by AddAccResource(), and FindAccResource().

PVOID FASTCALL HMValidateHandleNoRip | ( | HANDLE | h,
|  | BYTE | btype
| ) |

Definition at line 353 of file rtl/wow.c.

References CHECK_RESTRICTED, FASTCALL, GET_CURRENT_CLIENTINFO, NULL, TYPE_MONITOR, and ValidateHandleMacro.

Referenced by _CsDdeUninitialize(), _CsUpdateInstance(), _SetWindowLongPtr(), CallWindowProcAorW(), DestroyWindowSmIcon(), DrawIconCallBack(), DWP_GetIcon(), FindQMsg(), MungeClipData(), ProcessRegistrationMessage(), UT_FreeCBFormat(), ValidateHwndNoRip(), xxxCreateWindowSmIcon(), xxxDDETrackGetMessageHook(), xxxDWP_SetIcon(), xxxEventWndProc(), xxxGetDummyBitmap(), xxxGetDummyDib(), xxxGetDummyDibV5(), xxxPaintIconsInSwitchWindow(), xxxRealDrawMenuItem(), xxxRegisterClassEx(), xxxSetClassData(), xxxSetWindowData(), and xxxWrapCallWindowProc().

    00356 {
    00357     KERNEL_PVOID pobj = NULL;
    00358     PCLIENTINFO pci;
    00359
    00360     /*
    00361      * This is the fastest way way to do validation, because
    00362      *  unlike HMValidateHandle, this function doesn't set the
    00363      *  last error.
    00364      *
    00365      * Validation macro. Falls through if the handle is invalid.
    00366      */
    00367
    00368     GET_CURRENT_CLIENTINFO();
    00369
    00370     /*
    00371      * Object can't be located in shared memory.
    00372      */
    00373     UserAssert(bType != TYPE_MONITOR);
    00374
    00375     ValidateHandleMacro(pci, pobj, h, bType);
    00376
    00377     /*
    00378      * check for secure process
    00379      */
    00380     CHECK_RESTRICTED();
    00381
    00382     return pobj;
    00383 }

PVOID FASTCALL HMValidateHandleNoSecure | ( | HANDLE | h,
|  | BYTE | bType
| ) |

Definition at line 242 of file rtl/wow.c.

References DWORD, _CLIENTINFO::dwTIFlags, FASTCALL, GET_CURRENT_CLIENTINFO, HMUniqFromHandle, NULL, TIF_16BIT, TYPE_MONITOR, and ValidateHandleMacro.

Referenced by ValidateAndLockCursor(), and xxxGetWindowSmIcon().

    00245 {
    00246     KERNEL_PVOID pobj = NULL;
    00247     PCLIENTINFO pci;
    00248
    00249     GET_CURRENT_CLIENTINFO();
    00250
    00251 #if !defined(_USERK_)
    00252     /*
    00253      * We don't want 32 bit apps passing 16 bit handles
    00254      *  we should consider failing this before we get
    00255      *  stuck supporting it (Some VB apps do this).
    00256      */
    00257     if (pci && (h != NULL)
    00258            && (HMUniqFromHandle(h) == 0)
    00259            && !(pci->dwTIFlags & TIF_16BIT)) {
    00260         RIPMSG3(RIP_WARNING, "HMValidateHandle: 32bit process [%d] using 16 bit handle [%#p] bType:%#lx",
    00261                 HandleToUlong(NtCurrentTeb()->ClientId.UniqueProcess), h, (DWORD)bType);
    00262     }
    00263 #endif
    00264
    00265     /*
    00266      * Object can't be located in shared memory.
    00267      */
    00268     UserAssert(bType != TYPE_MONITOR);
    00269
    00270     /*
    00271      * Validation macro.
    00272      */
    00273     ValidateHandleMacro(pci, pobj, h, bType);
    00274
    00275     return pobj;
    00276 }

PVOID FASTCALL HMValidateSharedHandle | ( | HANDLE | h,
|  | BYTE | bType
| ) |

Definition at line 419 of file rtl/wow.c.

References DWORD, GetClientInfo, HMUniqFromHandle, NULL, TIF_16BIT, TYPE_MONITOR, and ValidateSharedHandleMacro.

Referenced by ValidateHmonitor().

    00422 {
    00423     DWORD dwError;
    00424     KERNEL_PVOID pobj = NULL;
    00425
    00426 #if DBG != 0 && !defined(_USERK_)
    00427
    00428     /*
    00429      * We don't want 32 bit apps passing 16 bit handles
    00430      *  we should consider failing this before we get
    00431      *  stuck supporting it (Some VB apps do this).
    00432      */
    00433     if ((h != NULL)
    00434            && (HMUniqFromHandle(h) == 0)
    00435            && !(GetClientInfo()->dwTIFlags & TIF_16BIT)) {
    00436         RIPMSG3(RIP_WARNING, "HMValidateHandle: 32bit process [%d] using 16 bit handle [%#p] bType:%#lx",
    00437                 HandleToUlong(NtCurrentTeb()->ClientId.UniqueProcess), h, (DWORD)bType);
    00438     }
    00439 #endif
    00440
    00441     /*
    00442      * Validation macro. Falls through if the handle is invalid.
    00443      */
    00444     ValidateSharedHandleMacro(pobj, h, bType);
    00445
    00446     if (pobj != NULL)
    00447         return pobj;
    00448
    00449     switch (bType) {
    00450         case TYPE_MONITOR:
    00451             dwError = ERROR_INVALID_MONITOR_HANDLE;
    00452             break;
    00453
    00454         default:
    00455             UserAssertMsg0(0, "Logic error in HMValidateSharedHandle");
    00456             break;
    00457     }
    00458
    00459     RIPERR2(dwError,
    00460             RIP_WARNING,
    00461             "HMValidateSharedHandle: Invalid:%#p Type:%#lx",
    00462             h, (DWORD)bType);
    00463
    00464     /*
    00465      * If we get here, it's an error.
    00466      */
    00467     return NULL;
    00468 }

__inline BOOL IsEmptyString | ( | PVOID | p,
|  | ULONG | bAnsi
| ) |

Definition at line 472 of file inc/user.h.

References BOOL.

Referenced by SLCreate().

    00473 {
    00474     return (BOOL)!(bAnsi ? *(LPSTR)p : *(LPWSTR)p);
    00475 }

BOOL IsSysFontAndDefaultMode | ( | HDC | hdc | ) |

Definition at line 2027 of file rtl/drawtext.c.

References BOOL, ghFontSys, UserGetHFONT, and UserGetMapMode.

Referenced by DT_InitDrawTextInfo(), and TabTextOut().

    02028 {
    02029     return((UserGetHFONT(hdc) == ghFontSys) && (UserGetMapMode(hdc) == MM_TEXT));
    02030 }

BOOL IsVisible | ( | PWND | pwnd | ) |

Definition at line 537 of file rtl/winmgr.c.

References BOOL, FALSE, FNID_DESKTOP, GETFNID, REBASEPWND, TestWF, TRUE, WFMINIMIZED, and WFVISIBLE.

Referenced by _GetDCEx(), BNSetFont(), ButtonWndProcWorker(), CalcVisRgn(), EnumPwndDlgChildProc(), FBitsTouch(), RestoreSpb(), SpbCheckRect(), StaticRepaint(), StaticWndProcWorker(), UT_InvertCaret(), xxxActivateThisWindow(), xxxBNGetDC(), xxxDrawCaptionBar(), xxxDrawWindowFrame(), xxxEnableSBCtlArrows(), xxxEnableWndSBArrows(), xxxLBResetContent(), xxxMinMaximize(), xxxRedrawWindow(), xxxScrollWindowEx(), and xxxSetScrollBar().

    00539 {
    00540     PWND pwndT;
    00541
    00542     for (pwndT = pwnd; pwndT; pwndT = REBASEPWND(pwndT, spwndParent)) {
    00543
    00544         /*
    00545          * Invisible windows are always invisible
    00546          */
    00547         if (!TestWF(pwndT, WFVISIBLE))
    00548             return FALSE;
    00549
    00550         if (TestWF(pwndT, WFMINIMIZED)) {
    00551
    00552             /*
    00553              * Children of minimized windows are always invisible.
    00554              */
    00555             if (pwndT != pwnd)
    00556                 return FALSE;
    00557         }
    00558
    00559         /*
    00560          * If we're at the desktop, then we don't want to go any further.
    00561          */
    00562         if (GETFNID(pwndT) == FNID_DESKTOP)
    00563             break;
    00564     }
    00565
    00566     return TRUE;
    00567 }

void KernelBP | ( | void |  | ) |

ULONG_PTR MapClientNeuterToClientPfn | ( | PCLS | pcls,
|  | KERNEL_ULONG_PTR | dw,
|  | BOOL | bAnsi
| ) |

Definition at line 49 of file ntuser/rtl/getset.c.

References tagCLS::fnid, FNID_CONTROLEND, FNID_CONTROLSTART, FNID_TO_CLIENT_PFNA_CLIENT, FNID_TO_CLIENT_PFNA_KERNEL, FNID_TO_CLIENT_PFNW_CLIENT, and FNID_TO_CLIENT_PFNW_KERNEL.

Referenced by _GetClassData(), _GetClassInfoEx(), GetWindowData(), xxxCreateWindowEx(), xxxSetClassData(), and xxxSetWindowData().

    00053 {
    00054     /*
    00055      * Default to the class window proc.
    00056      */
    00057     if (dw == 0) {
    00058         dw = (KERNEL_ULONG_PTR)pcls->lpfnWndProc;
    00059     }
    00060
    00061     /*
    00062      * If this is one of our controls and it hasn't been subclassed, try
    00063      * to return the correct ANSI/Unicode function.
    00064      */
    00065     if (pcls->fnid >= FNID_CONTROLSTART && pcls->fnid <= FNID_CONTROLEND) {
    00066         if (!bAnsi) {
    00067             if (FNID_TO_CLIENT_PFNA_KERNEL(pcls->fnid) == dw)
    00068                 return FNID_TO_CLIENT_PFNW_CLIENT(pcls->fnid);
    00069         } else {
    00070             if (FNID_TO_CLIENT_PFNW_KERNEL(pcls->fnid) == dw)
    00071                 return FNID_TO_CLIENT_PFNA_CLIENT(pcls->fnid);
    00072         }
    00073 #ifdef BUILD_WOW6432
    00074         if (!bAnsi) {
    00075             if (FNID_TO_CLIENT_PFNW_KERNEL(pcls->fnid) == dw)
    00076                 return FNID_TO_CLIENT_PFNW_CLIENT(pcls->fnid);
    00077         } else {
    00078             if (FNID_TO_CLIENT_PFNA_KERNEL(pcls->fnid) == dw)
    00079                 return FNID_TO_CLIENT_PFNA_CLIENT(pcls->fnid);
    00080         }
    00081 #endif
    00082     }
    00083
    00084     return (ULONG_PTR)dw;
    00085 }

ULONG_PTR MapServerToClientPfn | ( | KERNEL_ULONG_PTR | dw,
|  | BOOL | bAnsi
| ) |

Definition at line 22 of file ntuser/rtl/getset.c.

References FNID_TO_CLIENT_PFNA_CLIENT, FNID_TO_CLIENT_PFNW_CLIENT, FNID_WNDPROCEND, FNID_WNDPROCSTART, STOCID, and WNDPROC_PWND.

Referenced by _GetClassData(), _GetClassInfoEx(), GetWindowData(), xxxSetClassData(), and xxxSetWindowData().

    00025 {
    00026     int i;
    00027
    00028     for (i = FNID_WNDPROCSTART; i <= FNID_WNDPROCEND; i++) {
    00029         if ((WNDPROC_PWND)dw == STOCID(i)) {
    00030             if (bAnsi) {
    00031                 return FNID_TO_CLIENT_PFNA_CLIENT(i);
    00032             } else {
    00033                 return FNID_TO_CLIENT_PFNW_CLIENT(i);
    00034             }
    00035         }
    00036     }
    00037     return 0;
    00038 }

LPWSTR MB_GetString | ( | UINT | wBtn | ) |

Definition at line 1627 of file msgbox.c.

References GETGPSIMBPSTR, MAX_SEB_STYLES, and NULL.

Referenced by HardErrorHandler().

    01629 {
    01630     if (wBtn < MAX_SEB_STYLES)
    01631         return GETGPSIMBPSTR(wBtn);
    01632
    01633     RIPMSG1(RIP_ERROR, "Invalid wBtn: %d", wBtn);
    01634
    01635     return NULL;
    01636 }

PITEM MNLookUpItem | ( | PMENU | pMenu,
|  | UINT | wCmd,
|  | BOOL | fByPosition,
|  | PMENU * | ppMenuItemIsOn
| ) |

Definition at line 486 of file rtl/wow.c.

References tagMENU::cItems, FALSE, MFMWFP_NOITEM, NULL, REBASEALWAYS, REBASEPTR, and UINT.

Referenced by _GetMenuState(), _SetMenuDefaultItem(), CheckMenuItem(), CheckMenuRadioItem(), EnableMenuItem(), MenuItemState(), UT_FindTopLevelMenuIndex(), xxxInsertMenuItem(), xxxMNCanClose(), xxxRemoveDeleteMenuHelper(), xxxSetMenuItemInfo(), xxxSetSysMenu(), and xxxTA_AccelerateMenu().

    00491 {
    00492     PITEM pItem;
    00493     PITEM pItemRet = NULL;
    00494     PITEM  pItemMaybe;
    00495     PMENU   pMenuMaybe = NULL;
    00496     int i;
    00497
    00498     if (ppMenuItemIsOn != NULL)
    00499         *ppMenuItemIsOn = NULL;
    00500
    00501     if (pMenu == NULL || !pMenu->cItems || wCmd == MFMWFP_NOITEM) {
    00502 //      RIPERR0(ERROR_INVALID_PARAMETER, RIP_WARNING, "MNLookUpItem: invalid item");
    00503         return NULL;
    00504     }
    00505
    00506     /*
    00507      * dwFlags determines how we do the search
    00508      */
    00509     if (fByPosition) {
    00510         if (wCmd < (UINT)pMenu->cItems) {
    00511             pItemRet = &((PITEM)REBASEALWAYS(pMenu, rgItems))[wCmd];
    00512             if (ppMenuItemIsOn != NULL)
    00513                 *ppMenuItemIsOn = pMenu;
    00514             return (pItemRet);
    00515         } else
    00516             return NULL;
    00517     }
    00518     /*
    00519      * Walk down the menu and try to find an item with an ID of wCmd.
    00520      * The search procedes from the end of the menu (as was done in
    00521      * assembler).
    00522      */
    00523
    00524 /* this is the Chicago code, which walks from the front of the menu -- Fritz */
    00525
    00526
    00527 //        for (pItem = &pMenu->rgItems[i - 1]; pItemRet == NULL && i--; --pItem) {
    00528     for (i = 0, pItem = REBASEALWAYS(pMenu, rgItems); i < (int)pMenu->cItems;
    00529             i++, pItem++) {
    00530
    00531         /*
    00532          * If the item is a popup, recurse down the tree
    00533          */
    00534         if (pItem->spSubMenu != NULL) {
    00535         //
    00536         // COMPAT:
    00537         // Allow apps to pass in menu handle as ID in menu APIs.  We
    00538         // remember that this popup had a menu handle with the same ID
    00539         // value.  This is a 2nd choice though.  We still want to see
    00540         // if there's some actual command that has this ID value first.
    00541         //
    00542             if (pItem->wID == wCmd) {
    00543                 pMenuMaybe = pMenu;
    00544                 pItemMaybe = pItem;
    00545             }
    00546
    00547             pItemRet = MNLookUpItem((PMENU)REBASEPTR(pMenu, pItem->spSubMenu),
    00548                     wCmd, FALSE, ppMenuItemIsOn);
    00549             if (pItemRet != NULL)
    00550                 return pItemRet;
    00551         } else if (pItem->wID == wCmd) {
    00552
    00553                 /*
    00554                  * Found the item, now save things for later
    00555                  */
    00556                 if (ppMenuItemIsOn != NULL)
    00557                     *ppMenuItemIsOn = pMenu;
    00558                 return pItem;
    00559         }
    00560     }
    00561
    00562     if (pMenuMaybe) {
    00563         // no non popup menu match found -- use the 2nd choice popup menu
    00564         // match
    00565         if (ppMenuItemIsOn != NULL)
    00566             *ppMenuItemIsOn = pMenuMaybe;
    00567         return(pItemMaybe);
    00568     }
    00569
    00570     return(NULL);
    00571 }

BOOL NeedsWindowEdge | ( | DWORD | dwStyle,
|  | DWORD | dwExStyle,
|  | BOOL | fNewApp
| ) |

Definition at line 727 of file rtl/winmgr.c.

References BOOL, FALSE, and TRUE.

Referenced by _AdjustWindowRectEx(), xxxCreateWindowEx(), and xxxSetWindowStyle().

    00728 {
    00729     BOOL    fGetsWindowEdge;
    00730
    00731     fGetsWindowEdge = FALSE;
    00732
    00733     if (dwExStyle & WS_EX_DLGMODALFRAME)
    00734         fGetsWindowEdge = TRUE;
    00735     else if (dwExStyle & WS_EX_STATICEDGE)
    00736         fGetsWindowEdge = FALSE;
    00737     else if (dwStyle & WS_THICKFRAME)
    00738         fGetsWindowEdge = TRUE;
    00739     else switch (dwStyle & WS_CAPTION)
    00740     {
    00741         case WS_DLGFRAME:
    00742             fGetsWindowEdge = TRUE;
    00743             break;
    00744
    00745         case WS_CAPTION:
    00746             fGetsWindowEdge = fNewApp;
    00747             break;
    00748     }
    00749
    00750     return(fGetsWindowEdge);
    00751 }

__inline void NullTerminateString | ( | PVOID | p,
|  | ULONG | bAnsi
| ) |

Definition at line 476 of file inc/user.h.

References CHAR.

Referenced by _GetAltTabInfo(), and MESSAGECALL().

    00477 {
    00478     if (bAnsi) *(LPSTR)p = (CHAR)0; else *(LPWSTR)p = (WCHAR)0;
    00479 }

HBITMAP OwnerLoadBitmap | ( | HANDLE | hInstLoad,
|  | LPWSTR | lpName,
|  | HANDLE | hOwner
| ) |

Definition at line 20 of file rmcreate.c.

References NULL.

    00024 {
    00025 // LATER port this huge hunk of code
    00026     return NULL;
    00027 }

PHOOK PhkNextValid | ( | PHOOK | phk | ) |

Definition at line 1031 of file rtl/wow.c.

References tagDESKTOPINFO::aphkStart, CheckCritInShared, DbgValidateHooks, tagHOOK::flags, GetClientInfo, HF_DESTROYED, HF_GLOBAL, tagHOOK::iHook, NULL, _CLIENTINFO::pDeskInfo, PtiCurrent, REBASEALWAYS, and _CLIENTINFO::ulClientDelta.

Referenced by CallNextHookEx(), PhkFirstGlobalValid(), PhkFirstValid(), xxxCallHook2(), xxxCallNextHookEx(), zzzCancelJournalling(), zzzUnhookWindowsHook(), and zzzUnhookWindowsHookEx().

    01032 {
    01033
    01034 #if DBG
    01035     int iHook = phk->iHook;
    01036 #ifdef _USERK_
    01037     CheckCritInShared();
    01038 #endif
    01039 #endif
    01040
    01041     do {
    01042         /*
    01043          * If this hook is marked as destroyed, it must be either
    01044          *  locked or we should be in the process of destroying it
    01045          */
    01046         UserAssert(!(phk->flags & HF_DESTROYED)
    01047                     || (((PHEAD)phk)->cLockObj != 0)
    01048                     || (phk->flags & HF_INCHECKWHF));
    01049         /*
    01050          * Get the next hook
    01051          */
    01052         if (phk->phkNext != NULL) {
    01053             phk = REBASEALWAYS(phk, phkNext);
    01054         } else if (!(phk->flags & HF_GLOBAL)) {
    01055 #ifdef _USERK_
    01056             phk = PtiCurrent()->pDeskInfo->aphkStart[phk->iHook + 1];
    01057 #else
    01058             PCLIENTINFO pci = GetClientInfo();
    01059             phk = pci->pDeskInfo->aphkStart[phk->iHook + 1];
    01060             /*
    01061              * If it found a pointer, rebase it.
    01062              */
    01063             if (phk != NULL) {
    01064                 (KPBYTE)phk -= pci->ulClientDelta;
    01065             }
    01066 #endif
    01067             UserAssert((phk == NULL) || (phk->flags & HF_GLOBAL));
    01068         } else {
    01069             return NULL;
    01070         }
    01071         /*
    01072          * If destroyed, keep looking.
    01073          */
    01074     } while ((phk != NULL) && (phk->flags & HF_DESTROYED));
    01075
    01076 #ifdef _USERK_
    01077     DbgValidateHooks(phk, iHook);
    01078 #endif
    01079
    01080     return phk;
    01081 }

BOOL PSMGetTextExtent | ( | HDC | hdc,
|  | LPCWSTR | lpstr,
|  | int | cch,
|  | PSIZE | psize
| ) |

Definition at line 72 of file rtl/text.c.

References BOOL, FALSE, GetPrefixCount(), NULL, TRUE, UserGetTextExtentPointW, UserLocalAlloc, and UserLocalFree.

Referenced by BNCalcRect(), DrawStateW(), and xxxBNDrawText().

    00077 {
    00078     int result;
    00079     WCHAR szTemp[255], *pchOut;
    00080
    00081     if (cch > sizeof(szTemp)/sizeof(WCHAR)) {
    00082         pchOut = (WCHAR*)UserLocalAlloc(0, (cch+1) * sizeof(WCHAR));
    00083         if (pchOut == NULL)
    00084             return FALSE;
    00085     } else {
    00086         pchOut = szTemp;
    00087     }
    00088
    00089     result = HIWORD(GetPrefixCount(lpstr, cch, pchOut, cch));
    00090
    00091     if (result) {
    00092         lpstr = pchOut;
    00093         cch -= result;
    00094     }
    00095
    00096     UserGetTextExtentPointW(hdc, lpstr, cch, psize);
    00097
    00098     if (pchOut != szTemp)
    00099         UserLocalFree(pchOut);
    00100
    00101     /*
    00102      * IanJa everyone seems to ignore the ret val
    00103      */
    00104     return TRUE;
    00105 }

void RECTFromSIZERECT | ( | PRECT | prc,
|  | PCSIZERECT | psrc
| ) |

Definition at line 448 of file rect.c.

References tagSIZERECT::cx, tagSIZERECT::cy, PCSIZERECT, tagSIZERECT::x, and tagSIZERECT::y.

Referenced by xxxCheckFullScreen(), and xxxCreateWindowEx().

    00449 {
    00450     prc->left = psrc->x;
    00451     prc->top = psrc->y;
    00452     prc->right = psrc->x + psrc->cx;
    00453     prc->bottom = psrc->y + psrc->cy;
    00454 }

DWORD RtlGetExpWinVer | ( | HANDLE | hmod | ) |

Definition at line 28 of file w32/ntuser/rtl/random.c.

References BYTE, DWORD, FALSE, NULL, and RtlImageNtHeader().

Referenced by xxxCreateThreadInfo().

    00030 {
    00031     PIMAGE_NT_HEADERS pnthdr;
    00032     DWORD dwMajor = 3;
    00033     DWORD dwMinor = 0xA;
    00034
    00035     /*
    00036      * If it doesn't look like a valid 32bit hmod, use the default
    00037      *  (i.e., assuming all 16bit hmods are 0x30a)
    00038      */
    00039     if ((hmod != NULL) && (LOWORD(HandleToUlong(hmod)) == 0)) {
    00040         try {
    00041             pnthdr = RtlImageNtHeader((PVOID)hmod);
    00042             dwMajor = pnthdr->OptionalHeader.MajorSubsystemVersion;
    00043             /*
    00044              * Still need this hack 'cuz the linker still puts
    00045              * version 1.00 in the header of some things.
    00046              */
    00047             if (dwMajor == 1) {
    00048                 dwMajor = 0x3;
    00049             } else {
    00050                 dwMinor = pnthdr->OptionalHeader.MinorSubsystemVersion;
    00051             }
    00052         } except (W32ExceptionHandler(FALSE, RIP_WARNING)) {
    00053             dwMajor = 3;        // just to be safe
    00054             dwMinor = 0xA;
    00055         }
    00056     }
    00057
    00058
    00059     /*
    00060      * Return this is a win3.1 compatible format:
    00061      *
    00062      * 0x030A == win3.1
    00063      * 0x0300 == win3.0
    00064      * 0x0200 == win2.0, etc.
    00065      */
    00066
    00067     return (DWORD)MAKELONG(MAKEWORD((BYTE)dwMinor, (BYTE)dwMajor), 0);
    00068 }

VOID RtlInitLargeAnsiString | ( | PLARGE_ANSI_STRING | plstr,
|  | LPCSTR | psz,
|  | UINT | cchLimit
| ) |

Definition at line 608 of file chartran.c.

References _LARGE_ANSI_STRING::bAnsi, _LARGE_ANSI_STRING::Buffer, _LARGE_ANSI_STRING::Length, _LARGE_ANSI_STRING::MaximumLength, min, PLARGE_ANSI_STRING, strlen(), TRUE, and VOID().

Referenced by _CreateWindowEx(), _DefSetText(), MESSAGECALL(), NtUserfnHkINLPCBTCREATESTRUCT(), and xxxCreateWindowEx().

    00612 {
    00613     ULONG Length;
    00614
    00615     plstr->Buffer = (PSTR)psz;
    00616     plstr->bAnsi = TRUE;
    00617     if (ARGUMENT_PRESENT( psz )) {
    00618         Length = strlen( psz );
    00619         plstr->Length = min(Length, cchLimit);
    00620         plstr->MaximumLength = min((Length + 1), cchLimit);
    00621     } else {
    00622         plstr->MaximumLength = 0;
    00623         plstr->Length = 0;
    00624     }
    00625 }

VOID RtlInitLargeUnicodeString | ( | PLARGE_UNICODE_STRING | plstr,
|  | LPCWSTR | psz,
|  | UINT | cchLimit
| ) |

Definition at line 636 of file chartran.c.

References _LARGE_UNICODE_STRING::bAnsi, _LARGE_UNICODE_STRING::Buffer, FALSE, _LARGE_UNICODE_STRING::Length, _LARGE_UNICODE_STRING::MaximumLength, min, PLARGE_UNICODE_STRING, and VOID().

Referenced by _CreateWindowEx(), _DefSetText(), DlgDirSelectHelper(), DrawSwitchWndHilite(), InternalCreateDialog(), MESSAGECALL(), NtUserfnHkINLPCBTCREATESTRUCT(), SendNotifyMessage(), xxxCreateDefaultImeWindow(), xxxSetFrameTitle(), and xxxSystemParametersInfo().

    00640 {
    00641     ULONG Length;
    00642
    00643     plstr->Buffer = (PWSTR)psz;
    00644     plstr->bAnsi = FALSE;
    00645     if (ARGUMENT_PRESENT( psz )) {
    00646         Length = wcslen( psz ) * sizeof( WCHAR );
    00647         plstr->Length = min(Length, cchLimit);
    00648         plstr->MaximumLength = min((Length + sizeof(UNICODE_NULL)), cchLimit);
    00649     } else {
    00650         plstr->MaximumLength = 0;
    00651         plstr->Length = 0;
    00652     }
    00653 }

BOOL RtlMBMessageWParamCharToWCS | ( | DWORD | msg,
|  | WPARAM * | pWParam
| ) |

Definition at line 490 of file chartran.c.

References BOOL, CHAR, DWORD, FALSE, IS_ACP, IS_DBCS_ENABLED, MAKE_WPARAM_DBCSCHAR, msg, NT_SUCCESS, NTSTATUS(), NULL, RtlMultiByteToUnicodeN(), Status, THREAD_CODEPAGE, TRUE, and WMCR_IR_DBCSCHAR.

Referenced by CallMsgFilter(), DispatchMessageWorker(), IsDialogMessageA(), MESSAGECALL(), PostMessage(), PostThreadMessage(), SendMessageCallback(), SendMessageWorker(), SendNotifyMessage(), TranslateAcceleratorA(), and xxxDispatchMessage().

    00491 {
    00492     DWORD dwUni;
    00493     NTSTATUS Status;
    00494     // FE_SB    (RtlMBMessageWParamCharToWCS)
    00495     BOOL  bWmCrIrDbcsChar = FALSE;
    00496     WORD  wAnsi = LOWORD(*pWParam);
    00497     // end FE_SB    (RtlMBMessageWParamCharToWCS)
    00498     WORD CodePage = THREAD_CODEPAGE();
    00499
    00500     /*
    00501      * Only these messages have CHARs: others are passed through
    00502      */
    00503
    00504     switch(msg) {
    00505     // FE_SB    (RtlMBMessageWParamCharToWCS)
    00506     case WM_CHAR:
    00507         //
    00508         // WM_CHAR's wParam format for WM_IME_REPORT:IR_DBCSCHAR
    00509         //
    00510         if (IS_DBCS_ENABLED() && (*pWParam & WMCR_IR_DBCSCHAR)) {
    00511             //
    00512             // Mark this message is sent as IR_DBCSCHAR format.
    00513             //
    00514             bWmCrIrDbcsChar = TRUE;
    00515         }
    00516
    00517         //
    00518         // Fall through....
    00519         //
    00520 #ifdef FE_IME
    00521     case WM_IME_CHAR:
    00522     case WM_IME_COMPOSITION:
    00523         //
    00524         // We need to re-align for Unicode convertsion..
    00525         // WM_CHAR/WM_IME_CHAR/WM_IME_COMPOSITION's wParam format :
    00526         //
    00527         // ReAlign IR_DBCS char format to regular sequence.
    00528         //
    00529         // From:
    00530         //
    00531         //  HIWORD(wParam)         = 0;
    00532         //  HIBYTE(LOWORD(wParam)) = DBCS LeadingByte.
    00533         //  LOBYTE(LOWORD(wParan)) = DBCS TrailingByte or SBCS character.
    00534         //
    00535         // To:
    00536         //  HIWORD(wParam)         = 0;
    00537         //  HIBYTE(LOWORD(wParam)) = DBCS TrailingByte.
    00538         //  LOBYTE(LOWORD(wParam)) = DBCS LeadingByte or SBCS character.
    00539         //
    00540         if (IS_DBCS_ENABLED()) {
    00541             *pWParam = MAKE_WPARAM_DBCSCHAR(wAnsi);
    00542         }
    00543 #endif
    00544         //
    00545         // Fall through...
    00546         //
    00547         // end FE_SB    (RtlMBMessageWParamCharToWCS)
    00548     case WM_CHARTOITEM:
    00549     case EM_SETPASSWORDCHAR:
    00550     case WM_DEADCHAR:
    00551     case WM_SYSCHAR:
    00552     case WM_SYSDEADCHAR:
    00553     case WM_MENUCHAR:
    00554
    00555         dwUni = 0;
    00556
    00557         if (IS_ACP(CodePage)) {
    00558             Status = RtlMultiByteToUnicodeN((LPWSTR)&dwUni, sizeof(dwUni),
    00559                     NULL, (LPSTR)pWParam, 2 * sizeof(CHAR));
    00560             if (!NT_SUCCESS(Status))
    00561                 return FALSE;
    00562         } else {
    00563             int cwch;
    00564 #ifdef _USERK_
    00565             cwch = EngMultiByteToWideChar(CodePage,
    00566                     (LPWSTR)&dwUni, sizeof(dwUni),
    00567                     (LPSTR)pWParam, 2);
    00568 #else
    00569             cwch = MultiByteToWideChar(CodePage, 0,
    00570                     (LPSTR)pWParam, 2,
    00571                     (LPWSTR)&dwUni, sizeof(dwUni) / sizeof(WCHAR));
    00572 #endif // _USERK_
    00573             // KdPrint(("0x%02x -> 0x%04x (%d)\n", *pWParam, dwUni, CodePage));
    00574             if (cwch == 0) {
    00575                 return FALSE;
    00576             }
    00577         }
    00578
    00579         // FE_SB    (RtlMBMessageWParamCharToWCS)
    00580         //
    00581         // if this character is sent for WM_IME_REPORT:IR_DBCSCHAR, we mark it.
    00582         //
    00583         if (bWmCrIrDbcsChar)
    00584             dwUni |= WMCR_IR_DBCSCHAR;
    00585         // else FE_SB (RtlMBMessageWParamCharToWCS)
    00586 #if DBG
    00587         if ((dwUni == 0) || (dwUni > 0xFF)) {
    00588             RIPMSG1(RIP_VERBOSE, "msgA -> msgW: wchar = 0x%lX\n", dwUni);
    00589         }
    00590 #endif
    00591         // end FE_SB
    00592         *pWParam = dwUni;
    00593         break;
    00594     }
    00595
    00596     return TRUE;
    00597 }

BOOL RtlWCSMessageWParamCharToMB | ( | DWORD | msg,
|  | WPARAM * | pWParam
| ) |

Definition at line 361 of file chartran.c.

References BOOL, DWORD, HIBYTE, IS_ACP, IS_DBCS_ENABLED, IS_DBCS_MESSAGE, LOBYTE, msg, NT_SUCCESS, NTSTATUS(), NULL, RtlUnicodeToMultiByteN(), Status, THREAD_CODEPAGE, and TRUE.

Referenced by _PeekMessage(), DispatchMessageWorker(), GetMessage(), SendMessageWorker(), and xxxDispatchMessage().

    00362 {
    00363     DWORD dwAnsi;
    00364     NTSTATUS Status;
    00365     WORD CodePage;
    00366     int nbWch;
    00367
    00368 #ifdef FE_SB // RtlWCSMessageWParamCharToMB()
    00369     //
    00370     // Format of *pWParam here...
    00371     //
    00372     // LOWORD(*pWParam) = Unicode CodePoint...
    00373     // HIWORD(*pWParam) = Has some information for DBCS messaging
    00374     //                    (ex. WPARAM_IR_DBCSCHAR)
    00375     //
    00376     // Then we need to convert ONLY loword of wParam to Unicode...
    00377     //
    00378 #endif // FE_SB
    00379 #ifndef FE_SB
    00380     // NtBug #3135 (Closed 02/04/93)
    00381     // Publisher Posts WM_CHAR messages with wParam > 0xFF (not a valid ANSI char)!
    00382     //
    00383     // It does this to disable TranslateAccelerator for that char.
    00384     // MSPub's winproc must get the non-ANSI 'character' value, so PostMessage must
    00385     // translate *two* characters of wParam for character messages, and PeekMessage
    00386     // must translate *two* Unicode chars of wParam for ANSI app.
    00387 #endif
    00388
    00389     /*
    00390      * Only these messages have CHARs: others are passed through
    00391      */
    00392
    00393     switch(msg) {
    00394 #ifdef FE_IME // RtlWCSMessageWParamCharToMB()
    00395     case WM_IME_CHAR:
    00396     case WM_IME_COMPOSITION:
    00397 #endif // FE_IME
    00398     case WM_CHAR:
    00399     case WM_CHARTOITEM:
    00400     case EM_SETPASSWORDCHAR:
    00401     case WM_DEADCHAR:
    00402     case WM_SYSCHAR:
    00403     case WM_SYSDEADCHAR:
    00404     case WM_MENUCHAR:
    00405
    00406         CodePage = THREAD_CODEPAGE();
    00407         dwAnsi = 0;
    00408
    00409         nbWch = IS_DBCS_ENABLED() ? 1 * sizeof(WCHAR) : 2 * sizeof(WCHAR);
    00410
    00411         if (IS_ACP(CodePage)) {
    00412             // HACK HACK HACK HACK (for NtBug #3135)
    00413             // to allow applications that store data in high word of wParam
    00414             // Jan/06/96 hiroyama
    00415             Status = RtlUnicodeToMultiByteN((LPSTR)&dwAnsi, sizeof(dwAnsi),
    00416                     NULL, (LPWSTR)pWParam, nbWch);
    00417             if (!NT_SUCCESS(Status)) {
    00418                 // LATER IanJa: returning FALSE makes GetMessage fail, which
    00419                 // terminates the app.  We should use some default 'bad character'
    00420                 // I use 0x00 for now.
    00421                 *pWParam = 0x00;
    00422                 return TRUE;
    00423             }
    00424         } else {
    00425             int cwch;
    00426             // assuming little endian
    00427 #ifdef _USERK_
    00428             cwch = EngWideCharToMultiByte(CodePage,
    00429                     (LPWSTR)pWParam, nbWch,
    00430                     (LPSTR)&dwAnsi, sizeof(dwAnsi));
    00431 #else
    00432             cwch = WideCharToMultiByte(CodePage, 0,
    00433                     (LPCWSTR)pWParam, nbWch / sizeof(WCHAR),
    00434                     (LPSTR)&dwAnsi, sizeof(dwAnsi), NULL, NULL);
    00435 #endif // _USERK_
    00436             // KdPrint(("0x%04x -> 0x%02x (%d)\n", *pWParam, dwAnsi, CodePage));
    00437             if (cwch == 0) {
    00438                 *pWParam = 0x00;
    00439                 return TRUE;
    00440             }
    00441         }
    00442         if (IS_DBCS_ENABLED()) {
    00443             WORD wAnsi = LOWORD(dwAnsi);
    00444             //
    00445             // From:
    00446             //   HIBYTE(wAnsi)            = Dbcs TrailingByte.
    00447             //   LOBYTE(wAnsi)            = Dbcs LeadingByte or Sbcs character.
    00448             //
    00449             // To:
    00450             //   HIWORD(*pWParam)         = Original Data (information for DBCS messgaing).
    00451             //   HIBYTE(LOWORD(*pWParam)) = Dbcs LeadingByte Byte.
    00452             //   LOBYTE(LOWORD(*pWParam)) = Dbcs TrailingByte or Sbcs character.
    00453             //
    00454             if (IS_DBCS_MESSAGE(wAnsi)) {
    00455                 //
    00456                 // It's a DBCS character.
    00457                 //
    00458                 *pWParam = MAKEWPARAM(MAKEWORD(HIBYTE(wAnsi),LOBYTE(wAnsi)),HIWORD(*pWParam));
    00459             } else {
    00460                 //
    00461                 // It's a SBCS character.
    00462                 //
    00463                 *pWParam = MAKEWPARAM(MAKEWORD(LOBYTE(wAnsi),0),0);
    00464             }
    00465         } else {
    00466 #if DBG
    00467             if ((dwAnsi == 0) || (dwAnsi > 0xFF)) {
    00468                 RIPMSG1(RIP_VERBOSE, "msgW -> msgA: char = 0x%.4lX\n", dwAnsi);
    00469             }
    00470 #endif
    00471             *pWParam = dwAnsi;
    00472         }
    00473         break;
    00474     }
    00475
    00476     return TRUE;
    00477 }

__inline void SetRectEmptyInl | ( | LPRECT | prc | ) |

Definition at line 286 of file inc/user.h.

    00287 {
    00288     RtlZeroMemory(prc, sizeof(*prc));
    00289 }

PWND SizeBoxHwnd | ( | PWND | pwnd | ) |

Definition at line 636 of file rtl/winmgr.c.

    00638 {
    00639 #ifdef USE_MIRRORING
    00640     BOOL bMirroredSizeBox = (BOOL) TestWF(pwnd, WEFLAYOUTRTL);
    00641 #endif
    00642
    00643     int xbrChild;
    00644     int ybrChild = pwnd->rcWindow.bottom;
    00645
    00646 #ifdef USE_MIRRORING
    00647     if (bMirroredSizeBox) {
    00648         xbrChild = pwnd->rcWindow.left;
    00649     } else
    00650 #endif
    00651     {
    00652         xbrChild = pwnd->rcWindow.right;
    00653     }
    00654
    00655     while (GETFNID(pwnd) != FNID_DESKTOP) {
    00656         if (TestWF(pwnd, WFSIZEBOX)) {
    00657             // First sizeable parent found
    00658             int xbrParent;
    00659             int ybrParent;
    00660
    00661             if (TestWF(pwnd, WFMAXIMIZED))
    00662                 return(NULL);
    00663
    00664 #ifdef USE_MIRRORING
    00665             if (bMirroredSizeBox) {
    00666                 xbrParent = pwnd->rcClient.left;
    00667             } else
    00668 #endif
    00669             {
    00670                 xbrParent = pwnd->rcClient.right;
    00671             }
    00672             ybrParent = pwnd->rcClient.bottom;
    00673
    00674             /*  If the sizebox dude is within an EDGE of the client's bottom
    00675              *  right corner (left corner for mirrored windows), let this succeed.
    00676              *  That way people who draw their own sunken clients will be happy.
    00677              */
    00678 #ifdef USE_MIRRORING
    00679             if (bMirroredSizeBox) {
    00680                 if ((xbrChild - SYSMETRTL(CXEDGE) > xbrParent) || (ybrChild + SYSMETRTL(CYEDGE) < ybrParent)) {
    00681                     //
    00682                     // Child's bottom, left corner of SIZEBOX isn't close enough
    00683                     // to bottom left of parent's client.
    00684                     //
    00685                     return(NULL);
    00686                 }
    00687             } else
    00688 #endif
    00689             {
    00690                 if ((xbrChild + SYSMETRTL(CXEDGE) < xbrParent) || (ybrChild + SYSMETRTL(CYEDGE) < ybrParent)) {
    00691                     //
    00692                     // Child's bottom, right corner of SIZEBOX isn't close enough
    00693                     // to bottom right of parent's client.
    00694                     //
    00695                     return(NULL);
    00696                 }
    00697             }
    00698
    00699             return(pwnd);
    00700         }
    00701
    00702         if (!TestWF(pwnd, WFCHILD) || TestWF(pwnd, WFCPRESENT))
    00703             break;
    00704
    00705         pwnd = REBASEPWND(pwnd, spwndParent);
    00706     }
    00707     return(NULL);
    00708 }

void SIZERECTFromRECT | ( | PSIZERECT | psrc,
|  | LPCRECT | prc
| ) |

Definition at line 467 of file rect.c.

References tagSIZERECT::cx, tagSIZERECT::cy, PSIZERECT, tagSIZERECT::x, and tagSIZERECT::y.

    00468 {
    00469     psrc->x = prc->left;
    00470     psrc->y = prc->top;
    00471     psrc->cx = prc->right - prc->left;
    00472     psrc->cy = prc->bottom - prc->top;
    00473 }

int SoftModalMessageBox | ( | LPMSGBOXDATA | lpmb | ) |

Definition at line 730 of file msgbox.c.

References BYTE, _MSGBOXDATA::cButtons, ConnectIfNecessary, CopyRect, DrawTextExW(), DU_BTNGAP, DU_BTNHEIGHT, DU_INNERMARGIN, DU_OUTERMARGIN, DWORD, FALSE, GetClientInfo, GetDialogMonitor(), gpsi, hmodUser, InternalDialogBox(), IS_PTR, L, LMEM_ZEROINIT, max, MAX_PATH, MAX_RES_STRING, MB_AddPushButtons(), MB_DlgProcW(), MB_FindDlgTemplateSize(), MB_GetIconOrdNum(), MB_MASKSHIFT, MB_UpdateDlgHdr(), MB_UpdateDlgItem(), min, MultDiv, NtUserCallOneParam(), NtUserGetDCEx(), NtUserGetForegroundWindow(), NtUserReleaseDC, NtUserSetCursor(), NULL, PTR_TO_ID, tagMONITOR::rcMonitor, tagMONITOR::rcWork, STATICCODE, SYSMET, szEmpty, UNICODE_RLM, USER_SOUND_MAX, UserLocalFree, VER31, tagSERVERINFO::wMaxBtnSize, XPixFromXDU, and YPixFromYDU.

Referenced by HardErrorHandler(), and MessageBoxWorker().

    00730                                             {
    00731     LPBYTE              lpDlgTmp;
    00732     int                 cyIcon, cxIcon;
    00733     int                 cxButtons;
    00734     int                 cxMBMax;
    00735     int                 cxText, cyText, xText;
    00736     int                 cxBox, cyBox;
    00737     int                 cxFoo, cxCaption;
    00738     int                 xMB, yMB;
    00739     HDC                 hdc;
    00740     DWORD               wIconOrdNum;
    00741     DWORD               wCaptionLen;
    00742     DWORD               wTextLen;
    00743     WORD                OrdNum[2];  // Must be an array or WORDs
    00744     RECT                rc;
    00745     RECT                rcWork;
    00746     HCURSOR             hcurOld;
    00747     DWORD               dwStyleMsg, dwStyleText;
    00748     DWORD               dwExStyleMsg = 0;
    00749     DWORD               dwStyleDlg;
    00750     HWND                hwndOwner;
    00751     LPWSTR              lpsz;
    00752     int                 iRetVal     = 0;
    00753     HICON               hIcon;
    00754     HGLOBAL             hTemplate   = NULL;
    00755     HGLOBAL             hCaption    = NULL;
    00756     HGLOBAL             hText       = NULL;
    00757     HINSTANCE           hInstMsg    = lpmb->hInstance;
    00758     SIZE                size;
    00759     HFONT               hFontOld    = NULL;
    00760     int                 cntMBox;
    00761     PMONITOR            pMonitor;
    00762
    00763     ConnectIfNecessary();
    00764
    00765     dwStyleMsg = lpmb->dwStyle;
    00766
    00767     //
    00768     // This code is disabled since Mirroring will take care of this.
    00769     //
    00770 #ifndef USE_MIRRORING
    00771     if (dwStyleMsg & MB_RTLREADING) {
    00772         dwExStyleMsg |= WS_EX_RTLREADING;
    00773     }
    00774 #endif
    00775     if (dwStyleMsg & MB_RIGHT) {
    00776         dwExStyleMsg |= WS_EX_RIGHT;
    00777     }
    00778
    00779     if (!IS_PTR(lpmb->lpszCaption)) {
    00780
    00781         // won't ever be NULL because MessageBox sticks "Error!" in in that case
    00782         if (hInstMsg && (hCaption = LocalAlloc(LPTR, MAX_RES_STRING * sizeof(WCHAR)))) {
    00783             lpsz = (LPWSTR) hCaption;
    00784             LoadString(hInstMsg, PTR_TO_ID(lpmb->lpszCaption), lpsz, MAX_RES_STRING);
    00785         } else
    00786             lpsz = NULL;
    00787
    00788         lpmb->lpszCaption = lpsz ? lpsz : szEmpty;
    00789     }
    00790
    00791     if (!IS_PTR(lpmb->lpszText)) {
    00792         // NULL not allowed
    00793         if (hInstMsg && (hText = LocalAlloc(LPTR, MAX_RES_STRING * sizeof(WCHAR)))) {
    00794             lpsz = (LPWSTR) hText;
    00795             LoadString(hInstMsg, PTR_TO_ID(lpmb->lpszText), lpsz, MAX_RES_STRING);
    00796         } else
    00797             lpsz = NULL;
    00798
    00799         lpmb->lpszText = lpsz ? lpsz : szEmpty;
    00800     }
    00801
    00802 #ifdef USE_MIRRORING
    00803     //
    00804     // Mirroring of MessageBox'es is only enabled if :-
    00805     //
    00806     // * MB_RTLREADING style has been specified in the MessageBox styles OR
    00807     // * The first two code points of the MessageBox text are Right-To-Left
    00808     //   marks (RLMs = U+200f).
    00809     // The feature of enable RTL mirroring if two consecutive RLMs are found
    00810     // in the MB text is to acheive a no-code-change for localization of
    00811     // of MessageBoxes for BiDi Apps.  [samera]
    00812     //
    00813     if ((dwStyleMsg & MB_RTLREADING) ||
    00814             (lpmb->lpszText != NULL && (lpmb->lpszText[0] == UNICODE_RLM) &&
    00815             (lpmb->lpszText[1] == UNICODE_RLM))) {
    00816         //
    00817         // Set Mirroring so that MessageBox and its child controls
    00818         // get mirrored. Otherwise, the message box and its child controls
    00819         // are Left-To-Right.
    00820         //
    00821         dwExStyleMsg |= WS_EX_LAYOUTRTL;
    00822
    00823         //
    00824         // And turn off any conflicting flags.
    00825         //
    00826         dwExStyleMsg &= ~WS_EX_RIGHT;
    00827         if (dwStyleMsg & MB_RTLREADING) {
    00828             dwStyleMsg &= ~MB_RTLREADING;
    00829             dwStyleMsg ^= MB_RIGHT;
    00830         }
    00831     }
    00832 #endif
    00833
    00834
    00835     if ((dwStyleMsg & MB_ICONMASK) == MB_USERICON)
    00836         hIcon = LoadIcon(hInstMsg, lpmb->lpszIcon);
    00837     else
    00838         hIcon = NULL;
    00839
    00840     // For compatibility reasons, we still allow the message box to come up.
    00841     hwndOwner = lpmb->hwndOwner;
    00842
    00843     // For PowerBuilder4.0, we must make their messageboxes owned popups. Or, else
    00844     // they get WM_ACTIVATEAPP and they install multiple keyboard hooks and get into
    00845     // infinite loop later.
    00846     // Bug #15896 -- WIN95B -- 2/17/95 -- SANKAR --
    00847     if(!hwndOwner)
    00848       {
    00849         WCHAR pwszLibFileName[MAX_PATH];
    00850         static WCHAR szPB040[] = L"PB040";  // Module name of PowerBuilder4.0
    00851         WCHAR *pw1;
    00852
    00853         //Is this a win3.1 or older app?
    00854         if(GetClientInfo()->dwExpWinVer <= VER31)
    00855           {
    00856             if (GetModuleFileName(NULL, pwszLibFileName, sizeof(pwszLibFileName)/sizeof(WCHAR)) == 0) goto getthedc;
    00857             pw1 = pwszLibFileName + wcslen(pwszLibFileName) - 1;
    00858             while (pw1 > pwszLibFileName) {
    00859                 if (*pw1 == TEXT('.')) *pw1-- = 0;
    00860                 else if (*pw1 == TEXT(':')) {pw1++; break;}
    00861                 else if (*pw1 == TEXT('\\')) {pw1++; break;}
    00862                 else pw1--;
    00863             }
    00864             // Is this the PowerBuilder 4.0 module?
    00865             if(!_wcsicmp(pw1, szPB040))
    00866                 hwndOwner = NtUserGetForegroundWindow(); // Make the MsgBox owned.
    00867           }
    00868       }
    00869 getthedc:
    00870     // Check if we're out of cache DCs until robustness...
    00871     if (!(hdc = NtUserGetDCEx(NULL, NULL, DCX_WINDOW | DCX_CACHE))) {
    00872
    00873         /*
    00874          * The above call might fail for TIF_RESTRICTED processes
    00875          * so check for the DC from the owner window
    00876          */
    00877         if (!(hdc = NtUserGetDCEx(hwndOwner, NULL, DCX_WINDOW | DCX_CACHE)))
    00878             goto SMB_Exit;
    00879     }
    00880
    00881     // Figure out the types and dimensions of buttons
    00882
    00883     cxButtons = (lpmb->cButtons * gpsi->wMaxBtnSize) + ((lpmb->cButtons - 1) * XPixFromXDU(DU_BTNGAP, gpsi->cxMsgFontChar));
    00884
    00885     // Ditto for the icon, if there is one.  If not, cxIcon & cyIcon are 0.
    00886
    00887     if (wIconOrdNum = MB_GetIconOrdNum(dwStyleMsg)) {
    00888         cxIcon = SYSMET(CXICON) + XPixFromXDU(DU_INNERMARGIN, gpsi->cxMsgFontChar);
    00889         cyIcon = SYSMET(CYICON);
    00890     } else
    00891         cxIcon = cyIcon = 0;
    00892
    00893     hFontOld = SelectObject(hdc, gpsi->hCaptionFont);
    00894
    00895     // Find the max between the caption text and the buttons
    00896     wCaptionLen = wcslen(lpmb->lpszCaption);
    00897     GetTextExtentPoint(hdc, lpmb->lpszCaption, wCaptionLen, &size);
    00898     cxCaption = size.cx + 2*SYSMET(CXSIZE);
    00899
    00900     //
    00901     // The max width of the message box is 5/8 of the work area for most
    00902     // countries.  We will then try 6/8 and 7/8 if it won't fit.  Then
    00903     // we will use whole screen.
    00904     //
    00905     pMonitor = GetDialogMonitor(hwndOwner, MONITOR_DEFAULTTOPRIMARY);
    00906     CopyRect(&rcWork, &pMonitor->rcWork);
    00907     cxMBMax = MultDiv(rcWork.right - rcWork.left, 5, 8);
    00908
    00909     cxFoo = 2*XPixFromXDU(DU_OUTERMARGIN, gpsi->cxMsgFontChar);
    00910
    00911     SelectObject(hdc, gpsi->hMsgFont);
    00912
    00913     //
    00914     // If the text doesn't fit in 5/8, try 7/8 of the screen
    00915     //
    00916 ReSize:
    00917     //
    00918     // The message box is as big as needed to hold the caption/text/buttons,
    00919     // but not bigger than the maximum width.
    00920     //
    00921
    00922     cxBox = cxMBMax - 2*SYSMET(CXFIXEDFRAME);
    00923
    00924     // Ask DrawText for the right cx and cy
    00925     rc.left     = 0;
    00926     rc.top      = 0;
    00927     rc.right    = cxBox - cxFoo - cxIcon;
    00928     rc.bottom   = rcWork.bottom - rcWork.top;
    00929     cyText = DrawTextExW(hdc, (LPWSTR)lpmb->lpszText, -1, &rc,
    00930                 DT_CALCRECT | DT_WORDBREAK | DT_EXPANDTABS |
    00931                 DT_NOPREFIX | DT_EXTERNALLEADING | DT_EDITCONTROL, NULL);
    00932     //
    00933     // Make sure we have enough width to hold the buttons, in addition to
    00934     // the icon+text.  Always force the buttons.  If they don't fit, it's
    00935     // because the working area is small.
    00936     //
    00937     //
    00938     // The buttons are centered underneath the icon/text.
    00939     //
    00940     cxText = rc.right - rc.left + cxIcon + cxFoo;
    00941     cxBox = min(cxBox, max(cxText, cxCaption));
    00942     cxBox = max(cxBox, cxButtons + cxFoo);
    00943     cxText = cxBox - cxFoo - cxIcon;
    00944
    00945     //
    00946     // Now we know the text width for sure.  Really calculate how high the
    00947     // text will be.
    00948     //
    00949     rc.left     = 0;
    00950     rc.top      = 0;
    00951     rc.right    = cxText;
    00952     rc.bottom   = rcWork.bottom - rcWork.top;
    00953     cyText      = DrawTextExW(hdc, (LPWSTR)lpmb->lpszText, -1, &rc, DT_CALCRECT | DT_WORDBREAK
    00954         | DT_EXPANDTABS | DT_NOPREFIX | DT_EXTERNALLEADING | DT_EDITCONTROL, NULL);
    00955
    00956     // Find the window size.
    00957     cxBox += 2*SYSMET(CXFIXEDFRAME);
    00958     cyBox = 2*SYSMET(CYFIXEDFRAME) + SYSMET(CYCAPTION) + YPixFromYDU(2*DU_OUTERMARGIN +
    00959         DU_INNERMARGIN + DU_BTNHEIGHT, gpsi->cyMsgFontChar);
    00960
    00961     cyBox += max(cyIcon, cyText);
    00962
    00963     //
    00964     // If the message box doesn't fit on the working area, we'll try wider
    00965     // sizes successively:  6/8 of work then 7/8 of screen.
    00966     //
    00967     if (cyBox > rcWork.bottom - rcWork.top)
    00968     {
    00969         int cxTemp;
    00970
    00971         cxTemp = MultDiv(rcWork.right - rcWork.left, 6, 8);
    00972
    00973         if (cxMBMax == MultDiv(rcWork.right - rcWork.left, 5, 8))
    00974         {
    00975             cxMBMax = cxTemp;
    00976             goto ReSize;
    00977         }
    00978         else if (cxMBMax == cxTemp)
    00979         {
    00980             // then let's try with rcMonitor
    00981             CopyRect(&rcWork, &pMonitor->rcMonitor);
    00982             cxMBMax = MultDiv(rcWork.right - rcWork.left, 7, 8);
    00983             goto ReSize;
    00984         }
    00985     }
    00986
    00987     if (hFontOld)
    00988         SelectFont(hdc, hFontOld);
    00989     NtUserReleaseDC(NULL, hdc);
    00990
    00991     // Find the window position
    00992     cntMBox = GetClientInfo()->pDeskInfo->cntMBox;
    00993
    00994     xMB = (rcWork.left + rcWork.right - cxBox) / 2 + (cntMBox * SYSMET(CXSIZE));
    00995     xMB = max(xMB, rcWork.left);
    00996     yMB = (rcWork.top + rcWork.bottom - cyBox) / 2 + (cntMBox * SYSMET(CYSIZE));
    00997     yMB = max(yMB, rcWork.top);
    00998
    00999     // Bottom, right justify if we're going off the screen--but leave a
    01000     // little gap
    01001
    01002     if (xMB + cxBox > rcWork.right)
    01003         xMB = rcWork.right - SYSMET(CXEDGE) - cxBox;
    01004
    01005     //
    01006     // Pin to the working area.  If it won't fit, then pin to the screen
    01007     // height.  Bottom justify it at least if too big even for that, so
    01008     // that the buttons are visible.
    01009     //
    01010     if (yMB + cyBox > rcWork.bottom) {
    01011         yMB = rcWork.bottom - SYSMET(CYEDGE) - cyBox;
    01012         if (yMB < rcWork.top) {
    01013             yMB = pMonitor->rcMonitor.bottom - SYSMET(CYEDGE) - cyBox;
    01014         }
    01015     }
    01016
    01017     wTextLen = wcslen(lpmb->lpszText);
    01018
    01019     // Find out the memory required for the Dlg template and try to alloc it
    01020     hTemplate = LocalAlloc(LMEM_ZEROINIT, MB_FindDlgTemplateSize(lpmb));
    01021
    01022     if (!hTemplate)
    01023         goto SMB_Exit;
    01024
    01025     lpDlgTmp = (LPBYTE) hTemplate;
    01026
    01027     //
    01028     // Setup the dialog style for the message box
    01029     //
    01030     dwStyleDlg = WS_POPUPWINDOW | WS_CAPTION | DS_ABSALIGN | DS_NOIDLEMSG |
    01031                  DS_SETFONT | DS_3DLOOK;
    01032
    01033     if ((dwStyleMsg & MB_MODEMASK) == MB_SYSTEMMODAL)
    01034         dwStyleDlg |= DS_SYSMODAL | DS_SETFOREGROUND;
    01035     else
    01036         dwStyleDlg |= DS_MODALFRAME | WS_SYSMENU;
    01037
    01038     if (dwStyleMsg & MB_SETFOREGROUND)
    01039         dwStyleDlg |= DS_SETFOREGROUND;
    01040
    01041     // Add the Header of the Dlg Template
    01042     // BOGUS !!!  don't ADD bools
    01043     lpDlgTmp = MB_UpdateDlgHdr((LPDLGTEMPLATE) lpDlgTmp, dwStyleDlg, dwExStyleMsg,
    01044         (BYTE) (lpmb->cButtons + (wIconOrdNum != 0) + (lpmb->lpszText != NULL)),
    01045         xMB, yMB, cxBox, cyBox, (LPWSTR)lpmb->lpszCaption, wCaptionLen);
    01046
    01047     //
    01048     // Center the buttons
    01049     //
    01050
    01051     cxFoo = (cxBox - 2*SYSMET(CXFIXEDFRAME) - cxButtons) / 2;
    01052
    01053     lpDlgTmp = MB_AddPushButtons((LPDLGITEMTEMPLATE)lpDlgTmp, lpmb, cxFoo,
    01054         cyBox - SYSMET(CYCAPTION) - (2 * SYSMET(CYFIXEDFRAME)) -
    01055         YPixFromYDU(DU_OUTERMARGIN, gpsi->cyMsgFontChar), dwStyleMsg);
    01056
    01057     // Add Icon, if any, to the Dlg template
    01058     //
    01059     // The icon is always top justified.  If the text is shorter than the
    01060     // height of the icon, we center it.  Otherwise the text will start at
    01061     // the top.
    01062     //
    01063     if (wIconOrdNum) {
    01064         OrdNum[0] = 0xFFFF;  // To indicate that an Ordinal number follows
    01065         OrdNum[1] = (WORD) wIconOrdNum;
    01066
    01067         lpDlgTmp = MB_UpdateDlgItem((LPDLGITEMTEMPLATE)lpDlgTmp, IDUSERICON,        // Control Id
    01068             SS_ICON | WS_GROUP | WS_CHILD | WS_VISIBLE, 0,
    01069             XPixFromXDU(DU_OUTERMARGIN, gpsi->cxMsgFontChar),   // X co-ordinate
    01070             YPixFromYDU(DU_OUTERMARGIN, gpsi->cyMsgFontChar),   // Y co-ordinate
    01071             0,  0,          // For Icons, CX and CY are ignored, can be zero
    01072             OrdNum,         // Ordinal number of Icon
    01073             sizeof(OrdNum)/sizeof(WCHAR), // Length of OrdNum
    01074             STATICCODE);
    01075     }
    01076
    01077     // Add the Text of the Message to the Dlg Template
    01078     if (lpmb->lpszText) {
    01079         //
    01080         // Center the text if shorter than the icon.
    01081         //
    01082         if (cyText >= cyIcon)
    01083             cxFoo = 0;
    01084         else
    01085             cxFoo = (cyIcon - cyText) / 2;
    01086
    01087         dwStyleText = SS_NOPREFIX | WS_GROUP | WS_CHILD | WS_VISIBLE | SS_EDITCONTROL;
    01088         if (dwStyleMsg & MB_RIGHT) {
    01089             dwStyleText |= SS_RIGHT;
    01090             xText = cxBox - (SYSMET(CXSIZE) + cxText);
    01091         } else {
    01092             dwStyleText |= SS_LEFT;
    01093             xText = cxIcon + XPixFromXDU(DU_INNERMARGIN, gpsi->cxMsgFontChar);
    01094         }
    01095
    01096         MB_UpdateDlgItem((LPDLGITEMTEMPLATE)lpDlgTmp, -1, dwStyleText, dwExStyleMsg, xText,
    01097             YPixFromYDU(DU_OUTERMARGIN, gpsi->cyMsgFontChar) + cxFoo,
    01098             cxText, cyText,
    01099             (LPWSTR)lpmb->lpszText, wTextLen, STATICCODE);
    01100     }
    01101
    01102     // The dialog template is ready
    01103
    01104     //
    01105     // Set the normal cursor
    01106     //
    01107     hcurOld = NtUserSetCursor(LoadCursor(NULL, IDC_ARROW));
    01108
    01109     lpmb->lpszIcon = (LPWSTR) hIcon;  // BUGBUG - How to diff this from a resource?
    01110
    01111     if (!(lpmb->dwStyle & MB_USERICON))
    01112     {
    01113         int wBeep = (LOWORD(lpmb->dwStyle & MB_ICONMASK)) >> MB_MASKSHIFT;
    01114         if (wBeep < USER_SOUND_MAX) {
    01115             NtUserCallOneParam(wBeep, SFI_PLAYEVENTSOUND);
    01116         }
    01117     }
    01118
    01119     iRetVal = (int)InternalDialogBox(hmodUser, hTemplate, hwndOwner,
    01120         MB_DlgProcW, (LPARAM) lpmb, FALSE);
    01121
    01122     //
    01123     // Fix up return value
    01124     if (iRetVal == -1)
    01125         iRetVal = 0;                /* Messagebox should also return error */
    01126
    01127      //
    01128      // If the messagebox contains only OK button, then its ID is changed as
    01129      // IDCANCEL in MB_DlgProc; So, we must change it back to IDOK irrespective
    01130      // of whether ESC is pressed or Carriage return is pressed;
    01131      //
    01132     if (((dwStyleMsg & MB_TYPEMASK) == MB_OK) && iRetVal)
    01133         iRetVal = IDOK;
    01134
    01135
    01136     //
    01137     // Restore the previous cursor
    01138     //
    01139     if (hcurOld)
    01140         NtUserSetCursor(hcurOld);
    01141
    01142 SMB_Exit:
    01143     if (hTemplate)
    01144         UserLocalFree(hTemplate);
    01145
    01146     if (hCaption) {
    01147         UserLocalFree(hCaption);
    01148     }
    01149
    01150     if (hText) {
    01151         UserLocalFree(hText);
    01152     }
    01153
    01154     return(iRetVal);
    01155 }

__inline UINT StringLength | ( | PVOID | p,
|  | ULONG | bAnsi
| ) |

Definition at line 480 of file inc/user.h.

References strlen(), and UINT.

Referenced by ECSetText().

    00481 {
    00482     return (bAnsi ? strlen((LPSTR)p) : wcslen((LPWSTR)p));
    00483 }

DWORD strncpycch | ( | LPSTR | pszDest,
|  | LPCSTR | pszSrc,
|  | DWORD | cch
| ) |

Definition at line 184 of file w32/ntuser/rtl/random.c.

References DWORD.

Referenced by CopyOutputString(), and xxxInterSendMsgEx().

    00189 {
    00190         LPSTR start = dest;
    00191
    00192         while (count && (*dest++ = *source++))    /* copy string */
    00193                 count--;
    00194
    00195         return (DWORD)(dest - start);
    00196 }

BOOL TestWindowProcess | ( | PWND | pwnd | ) |

Definition at line 551 of file winmgrc.c.

References BOOL, GETPROCESSID, GETPTI, GetWindowProcess, HW, PpiCurrent, PtiCurrent, and TRUE.

Referenced by _GetWindowLongPtr(), _SetWindowLongPtr(), ChildWindowFromPoint(), GetWindowData(), GetWindowText(), GetWindowTextLength(), ImmConfigureIMEA(), ImmConfigureIMEW(), ImmGetSaveContext(), and SetWindowText().

    00553 {
    00554     /*
    00555      * If the threads are the same, don't bother going to the kernel
    00556      * to get the window's process id.
    00557      */
    00558     if (GETPTI(pwnd) == PtiCurrent()) {
    00559         return TRUE;
    00560     }
    00561
    00562     return (GetWindowProcess(HW(pwnd)) == GETPROCESSID());
    00563 }

LPWSTR TextAlloc | ( | LPCWSTR | lpsz | ) |

Definition at line 164 of file w32/ntuser/client/random.c.

References DWORD, NULL, and UserLocalAlloc.

Referenced by MDIClientWndProcWorker(), MessageBoxWorker(), and xxxSetFrameTitle().

    00166 {
    00167     LPWSTR pszT;
    00168     DWORD  cbString;
    00169
    00170     if (lpszSrc == NULL)
    00171         return NULL;
    00172
    00173     cbString = (wcslen(lpszSrc) + 1) * sizeof(WCHAR);
    00174
    00175     if (pszT = (LPWSTR)UserLocalAlloc(HEAP_ZERO_MEMORY, cbString)) {
    00176
    00177         RtlCopyMemory(pszT, lpszSrc, cbString);
    00178     }
    00179
    00180     return pszT;
    00181 }

UINT TextCopy | ( | PLARGE_UNICODE_STRING | pstr,
|  | LPWSTR | lpstr,
|  | UINT | size
| ) |

Definition at line 108 of file w32/ntuser/rtl/random.c.

References _LARGE_UNICODE_STRING::Buffer, _LARGE_UNICODE_STRING::Length, min, and UINT.

Referenced by _GetAltTabInfo(), DlgDirSelectHelper(), DrawSwitchWndHilite(), NtUserInternalGetWindowText(), xxxDefWindowProc(), xxxDrawCaptionTemp(), and xxxSetFrameTitle().

    00112 {
    00113     if (cchMax != 0) {
    00114         cchMax = min(pstr->Length / sizeof(WCHAR), cchMax - 1);
    00115         RtlCopyMemory(pszDst, (PVOID)pstr->Buffer, cchMax * sizeof(WCHAR));
    00116         pszDst[cchMax] = 0;
    00117     }
    00118
    00119     return cchMax;
    00120 }

BOOL User32InitializeImmEntryTable | ( | DWORD | dwMagic | ) |

Definition at line 344 of file fareast.c.

References _InitializeImmEntryTable(), bImmInitializing, BOOL, fakeImm_wd2(), FALSE, fpImmRegisterClient, GetImmFileName(), ghImm32, gImmApiEntries, gSharedInfo, IMM_MAGIC_CALLER_ID, MAX_PATH, NULL, and TRUE.

Referenced by ImmDllInitialize().

    00345 {
    00346     if (magic != IMM_MAGIC_CALLER_ID) {
    00347         RIPMSG1(RIP_WARNING, "User32InitializeImmEntryTable: magic # does not match: 0x%08x", magic);
    00348         return FALSE;
    00349     }
    00350
    00351     if (((PVOID)gImmApiEntries.ImmWINNLSEnableIME) != ((PVOID)fakeImm_wd2)) {
    00352         // already initialized
    00353         return TRUE;
    00354     }
    00355
    00356     _InitializeImmEntryTable();
    00357
    00358     if (ghImm32 == NULL) {
    00359         if (!bImmInitializing) {
    00360             // increment the load counter of IMM32.DLL; application may call FreeLibrary later
    00361             WCHAR wszImmFile[MAX_PATH];
    00362             GetImmFileName(wszImmFile);
    00363             ghImm32 = LoadLibraryW(wszImmFile);
    00364         }
    00365     }
    00366     // for IMM initialization
    00367     return fpImmRegisterClient(&gSharedInfo, ghImm32);
    00368 }

WORD VersionFromWindowFlag | ( | PWND | pwnd | ) |

DWORD wcsncpycch | ( | LPWSTR | pwsDest,
|  | LPCWSTR | pwszSrc,
|  | DWORD | cch
| ) |

Definition at line 146 of file w32/ntuser/rtl/random.c.

References DWORD.

Referenced by _GetKeyNameText(), CopyOutputString(), CreateDlgFont(), FixupDlgFaceName(), GetActiveKeyboardName(), GetDefaultWallpaperName(), LoadKeyboardLayoutFile(), NtUserCreateWindowStation(), NtUserGetKeyboardLayoutName(), xxxInterSendMsgEx(), and xxxShowTooltip().

    00151 {
    00152         LPWSTR start = dest;
    00153
    00154         while (count && (*dest++ = *source++))    /* copy string */
    00155                 count--;
    00156
    00157         return (DWORD)(dest - start);
    00158 }

PMENU xxxGetSysMenuHandle | ( | PWND | pwnd | ) |

Definition at line 270 of file menuc.c.

    00272 {
    00273     PMENU pMenu;
    00274
    00275     if (TestWF(pwnd, WFSYSMENU)) {
    00276         pMenu = pwnd->spmenuSys;
    00277
    00278         /*
    00279          * If the window doesn't have a System Menu, use the default one.
    00280          */
    00281         if (pMenu == NULL) {
    00282
    00283             /*
    00284              * Change owner so this app can access this menu.
    00285              */
    00286             pMenu = (PMENU)NtUserCallHwndLock(HWq(pwnd), SFI_XXXGETSYSMENUHANDLE);
    00287         }
    00288     } else {
    00289         pMenu = NULL;
    00290     }
    00291
    00292     return pMenu;
    00293 }

RTLMENU xxxLoadSysMenu | ( | UINT | uMenuId | ) |

Definition at line 117 of file ntuser/rtl/menu.c.

References hmodUser, ID_DIALOGSYSMENU, NULL, RtlInitUnicodeStringOrId(), RTLMENU, ThreadLockAlways, ThreadUnlock, xxxClientLoadMenu(), xxxRtlSetMenuInfo, and xxxRtlSetMenuItemInfo.

Referenced by CreateMDIChild(), xxxGetSystemMenu(), and xxxLoadSysDesktopMenu().

    00118 {
    00119     RTLMENU rtlMenu;
    00120     MENUINFO mi;
    00121     MENUITEMINFO mii;
    00122     TL tlMenu;
    00123
    00124 #ifdef _USERK_
    00125     UNICODE_STRING strMenuName;
    00126     RtlInitUnicodeStringOrId(&strMenuName, MAKEINTRESOURCE(uMenuId));
    00127     rtlMenu = xxxClientLoadMenu(NULL, &strMenuName);
    00128 #else
    00129     rtlMenu = LoadMenu(hmodUser, MAKEINTRESOURCE(uMenuId));
    00130 #endif
    00131
    00132     if (rtlMenu == NULL) {
    00133         RIPMSG1(RIP_WARNING, "xxxLoadSysMenu failed to load:%#lx", uMenuId);
    00134         return NULL;
    00135     }
    00136
    00137     ThreadLockAlways(rtlMenu, &tlMenu);
    00138     /*
    00139      * Add the checkorbmp style. (draw bitmaps and checkmarks on the
    00140      *  same column)
    00141      */
    00142     mi.cbSize = sizeof(mi);
    00143     mi.fMask = MIM_STYLE | MIM_APPLYTOSUBMENUS;
    00144     mi.dwStyle = MNS_CHECKORBMP;
    00145     xxxRtlSetMenuInfo(rtlMenu, &mi);
    00146     /*
    00147      * Add the bitmaps for close, minimize, maximize and restore items.
    00148      */
    00149     mii.cbSize = sizeof(mii);
    00150     mii.fMask = MIIM_BITMAP;
    00151     mii.hbmpItem = HBMMENU_POPUP_CLOSE;
    00152     xxxRtlSetMenuItemInfo (rtlMenu, SC_CLOSE, &mii);
    00153     if (uMenuId != ID_DIALOGSYSMENU) {
    00154         mii.hbmpItem = HBMMENU_POPUP_MINIMIZE;
    00155         xxxRtlSetMenuItemInfo (rtlMenu, SC_MINIMIZE, &mii);
    00156         mii.hbmpItem = HBMMENU_POPUP_MAXIMIZE;
    00157         xxxRtlSetMenuItemInfo (rtlMenu, SC_MAXIMIZE, &mii);
    00158         mii.hbmpItem = HBMMENU_POPUP_RESTORE;
    00159         xxxRtlSetMenuItemInfo (rtlMenu, SC_RESTORE, &mii);
    00160     }
    00161
    00162     ThreadUnlock(&tlMenu);
    00163     return rtlMenu;
    00164 }

BOOL xxxMNCanClose | ( | PWND | pwnd | ) |

Definition at line 78 of file ntuser/rtl/menu.c.

References BOOL, CFNOCLOSE, CheckLock, FALSE, MNLookUpItem(), NULL, REBASEALWAYS, REBASEPTR, TestCF2, TestMFS, and xxxGetSysMenuHandle().

Referenced by DefFrameProcWorker(), MDIAddSysMenu(), xxxCalcCaptionButton(), xxxDrawCaptionBar(), and xxxGetTitleBarInfo().

    00079 {
    00080     PMENU   pMenu;
    00081     PITEM   pItem;
    00082     PCLS pcls;
    00083
    00084     CheckLock(pwnd);
    00085
    00086     pcls = (PCLS)REBASEALWAYS(pwnd, pcls);
    00087     if ( TestCF2(pcls, CFNOCLOSE) )
    00088         return FALSE;
    00089
    00090     pMenu = xxxGetSysMenuHandle(pwnd);
    00091     if (!pMenu || !(pMenu = REBASEPTR(pwnd, pMenu)))
    00092         return(FALSE);
    00093
    00094     /*
    00095      * Note how this parallels the code in SetCloseDefault--we check for
    00096      *  3 different IDs.
    00097      */
    00098     pItem = MNLookUpItem(pMenu, SC_CLOSE, FALSE, NULL);
    00099
    00100     if (!(pItem))
    00101         pItem = MNLookUpItem(pMenu, SC_CLOSE-0x7000, FALSE, NULL);
    00102
    00103     if (!(pItem))
    00104         pItem = MNLookUpItem(pMenu, 0xC070, FALSE, NULL);
    00105
    00106     return((pItem) && !TestMFS(pItem, MFS_GRAYED));
    00107 }

## Variable Documentation

PWND _GetDesktopWindow(VOID)

PWND _GetMessageWindow(VOID)

FPLPKDRAWTEXTEX fpLpkDrawTextEx

| Definition at line 3345 of file inc/user.h. Referenced by DT_InitDrawTextInfo(), and InitializeLpkHooks().

PLPKEDITCALLOUT fpLpkEditControl

| Definition at line 3420 of file inc/user.h. Referenced by ECCreate(), and InitializeLpkHooks().

FPLPKPSMTEXTOUT fpLpkPSMTextOut

| Definition at line 3344 of file inc/user.h. Referenced by InitializeLpkHooks().

FPLPKTABBEDTEXTOUT fpLpkTabbedTextOut

| Definition at line 3343 of file inc/user.h. Referenced by InitializeLpkHooks().

HBRUSH ghbrBlack

| Definition at line 3487 of file inc/user.h.

HBRUSH ghbrWhite

| Definition at line 3486 of file inc/user.h.

CONST MSG_TABLE_ENTRY MessageTable[]

| Definition at line 3672 of file inc/user.h.

typedef PVWPL

| Referenced by VWPLAdd(), and VWPLRemove().