5 typedef struct _WINDOW_OBJECT
*PWINDOW_OBJECT
;
7 #include <include/object.h>
8 #include <include/class.h>
9 #include <include/msgqueue.h>
10 #include <include/winsta.h>
11 #include <include/dce.h>
12 #include <include/prop.h>
13 #include <include/scroll.h>
15 extern ATOM AtomMessage
;
16 extern ATOM AtomWndObj
; /* WNDOBJ list */
18 BOOL FASTCALL
UserUpdateUiState(PWND Wnd
, WPARAM wParam
);
20 typedef struct _WINDOW_OBJECT
25 /* Pointer to the thread information */
26 PTHREADINFO pti
; // Use Wnd->head.pti
27 /* system menu handle. */
29 /* Handle for the window. */
30 HWND hSelf
; // Use Wnd->head.h
33 /* Handle of region of the window to be updated. */
35 /* Handle of the window region. */
37 struct _WINDOW_OBJECT
* spwndChild
;
38 struct _WINDOW_OBJECT
* spwndNext
;
39 struct _WINDOW_OBJECT
* spwndPrev
;
40 /* Handle to the parent window. */
41 struct _WINDOW_OBJECT
* spwndParent
;
42 /* Handle to the owner window. */
43 HWND hOwner
; // Use spwndOwner
47 PSBINFOEX pSBInfo
; // convert to PSBINFO
48 /* Entry in the list of thread windows. */
49 LIST_ENTRY ThreadListEntry
;
50 } WINDOW_OBJECT
; /* PWINDOW_OBJECT already declared at top of file */
53 #define WINDOWOBJECT_NEED_SIZE WNDS_SENDSIZEMOVEMSGS
54 #define WINDOWOBJECT_NEED_ERASEBKGND WNDS_ERASEBACKGROUND
55 #define WINDOWOBJECT_NEED_NCPAINT WNDS_SENDNCPAINT
56 #define WINDOWOBJECT_RESTOREMAX (0x00000020) // Set/Clr WS_MAXIMIZE && Clr/Set WS_EX2_VERTICALLYMAXIMIZEDLEFT/RIGHT
58 #define WINDOWSTATUS_DESTROYING WNDS2_INDESTROY
59 #define WINDOWSTATUS_DESTROYED WNDS_DESTROYED
61 #define HAS_DLGFRAME(Style, ExStyle) \
62 (((ExStyle) & WS_EX_DLGMODALFRAME) || \
63 (((Style) & WS_DLGFRAME) && (!((Style) & WS_THICKFRAME))))
65 #define HAS_THICKFRAME(Style, ExStyle) \
66 (((Style) & WS_THICKFRAME) && \
67 (!(((Style) & (WS_DLGFRAME | WS_BORDER)) == WS_DLGFRAME)))
69 #define HAS_THINFRAME(Style, ExStyle) \
70 (((Style) & WS_BORDER) || (!((Style) & (WS_CHILD | WS_POPUP))))
72 #define IntIsDesktopWindow(WndObj) \
73 (WndObj->spwndParent == NULL)
75 #define IntIsBroadcastHwnd(hWnd) \
76 (hWnd == HWND_BROADCAST || hWnd == HWND_TOPMOST)
79 #define IntWndBelongsToThread(WndObj, W32Thread) \
80 (((WndObj->pti->pEThread && WndObj->pti->pEThread->Tcb.Win32Thread)) && \
81 (WndObj->pti->pEThread->Tcb.Win32Thread == W32Thread))
82 // ((WndObj->head.pti) && (WndObj->head.pti == W32Thread))
84 #define IntGetWndThreadId(WndObj) \
85 WndObj->pti->pEThread->Cid.UniqueThread
86 // WndObj->head.pti->pEThread->Cid.UniqueThread
88 #define IntGetWndProcessId(WndObj) \
89 WndObj->pti->pEThread->ThreadsProcess->UniqueProcessId
90 // WndObj->head.pti->pEThread->ThreadsProcess->UniqueProcessId
93 IntIsWindow(HWND hWnd
);
96 IntWinListChildren(PWINDOW_OBJECT Window
);
99 InitWindowImpl (VOID
);
102 CleanupWindowImpl (VOID
);
105 IntGetClientRect (PWINDOW_OBJECT WindowObject
, RECTL
*Rect
);
108 IntGetActiveWindow (VOID
);
111 IntIsWindowVisible (PWINDOW_OBJECT Window
);
114 IntIsChildWindow (PWINDOW_OBJECT Parent
, PWINDOW_OBJECT Child
);
117 IntUnlinkWindow(PWINDOW_OBJECT Wnd
);
120 IntLinkWindow(PWINDOW_OBJECT Wnd
, PWINDOW_OBJECT WndParent
, PWINDOW_OBJECT WndPrevSibling
);
122 PWINDOW_OBJECT FASTCALL
123 IntGetAncestor(PWINDOW_OBJECT Wnd
, UINT Type
);
125 PWINDOW_OBJECT FASTCALL
126 IntGetParent(PWINDOW_OBJECT Wnd
);
128 PWINDOW_OBJECT FASTCALL
129 IntGetOwner(PWINDOW_OBJECT Wnd
);
133 IntGetWindowRgn(PWINDOW_OBJECT Window
, HRGN hRgn
);
136 IntGetWindowRgnBox(PWINDOW_OBJECT Window
, RECTL
*Rect
);
139 IntGetWindowInfo(PWINDOW_OBJECT WindowObject
, PWINDOWINFO pwi
);
142 IntGetWindowBorderMeasures(PWINDOW_OBJECT WindowObject
, UINT
*cx
, UINT
*cy
);
148 IntIsWindowInDestroy(PWINDOW_OBJECT Window
);
151 IntShowOwnedPopups( PWINDOW_OBJECT owner
, BOOL fShow
);
154 IntDefWindowProc( PWINDOW_OBJECT Window
, UINT Msg
, WPARAM wParam
, LPARAM lParam
, BOOL Ansi
);
156 VOID FASTCALL
IntNotifyWinEvent(DWORD
, PWND
, LONG
, LONG
);
158 PWND APIENTRY
co_IntCreateWindowEx(DWORD
,PUNICODE_STRING
,PLARGE_STRING
,DWORD
,LONG
,LONG
,LONG
,LONG
,HWND
,HMENU
,HINSTANCE
,LPVOID
,DWORD
,BOOL
);
159 WNDPROC FASTCALL
IntGetWindowProc(PWND
,BOOL
);