Author: jimtabor
Date: Tue Jul 4 00:04:17 2006
New Revision: 22803
URL:
http://svn.reactos.org/svn/reactos?rev=22803&view=rev
Log:
Restored sequence for setting WindowObject and callers styles.
Modified:
trunk/reactos/subsystems/win32/win32k/ntuser/window.c
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/window.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/nt…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/ntuser/window.c (original)
+++ trunk/reactos/subsystems/win32/win32k/ntuser/window.c Tue Jul 4 00:04:17 2006
@@ -1692,11 +1692,19 @@
dwExStyle |= WS_EX_WINDOWEDGE;
else
dwExStyle &= ~WS_EX_WINDOWEDGE;
-/*
- These affect only the style loading into the WindowObject structure.
-*/
- Window->ExStyle = dwExStyle;
- Window->Style = dwStyle & ~WS_VISIBLE;
+
+ /* Correct the window style. */
+ if (!(dwStyle & WS_CHILD))
+ {
+ dwStyle |= WS_CLIPSIBLINGS;
+ DPRINT("3: Style is now %lx\n", dwStyle);
+ if (!(dwStyle & WS_POPUP))
+ {
+ dwStyle |= WS_CAPTION;
+ Window->Flags |= WINDOWOBJECT_NEED_SIZE;
+ DPRINT("4: Style is now %lx\n", dwStyle);
+ }
+ }
/* create system menu */
if((dwStyle & WS_SYSMENU) &&
@@ -1709,23 +1717,6 @@
IntReleaseMenuObject(SystemMenu);
}
}
-
- /* Correct the window style. */
- if (!(Window->Style & WS_CHILD))
- {
- Window->Style |= WS_CLIPSIBLINGS;
- if (!(Window->Style & WS_POPUP))
- {
- Window->Style |= WS_CAPTION;
- Window->Flags |= WINDOWOBJECT_NEED_SIZE;
- }
- }
-
- if ((Window->ExStyle & WS_EX_DLGMODALFRAME) ||
- (Window->Style & (WS_DLGFRAME | WS_THICKFRAME)))
- Window->ExStyle |= WS_EX_WINDOWEDGE;
- else
- Window->ExStyle &= ~WS_EX_WINDOWEDGE;
/* Insert the window into the thread's window list. */
InsertTailList (&PsGetWin32Thread()->WindowListHead,
&Window->ThreadListEntry);
@@ -1741,6 +1732,9 @@
Pos.y = y;
Size.cx = nWidth;
Size.cy = nHeight;
+
+ Window->ExStyle = dwExStyle;
+ Window->Style = dwStyle & ~WS_VISIBLE;
/* call hook */
Cs.lpCreateParams = lpParam;