Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
1b6f8a1a
Commit
1b6f8a1a
authored
Oct 07, 2021
by
Piotr Caban
Committed by
Alexandre Julliard
Oct 07, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
user32: Fix style passed to HCBT_CREATEWND hook.
Signed-off-by:
Piotr Caban
<
piotr@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
08f60ee9
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
12 deletions
+6
-12
win.c
dlls/user32/tests/win.c
+6
-6
win.c
dlls/user32/win.c
+0
-6
No files found.
dlls/user32/tests/win.c
View file @
1b6f8a1a
...
...
@@ -1222,9 +1222,10 @@ static LRESULT CALLBACK cbt_hook_proc(int nCode, WPARAM wParam, LPARAM lParam)
/* WS_VISIBLE should be turned off yet */
style
=
createwnd
->
lpcs
->
style
&
~
WS_VISIBLE
;
ok
(
style
==
GetWindowLongA
(
hwnd
,
GWL_STYLE
),
"style of hwnd and style in the CREATESTRUCT do not match: %08x != %08x
\n
"
,
GetWindowLongA
(
hwnd
,
GWL_STYLE
),
style
);
todo_wine_if
(
!
(
style
&
WS_CLIPSIBLINGS
)
&&
(
!
(
style
&
WS_CHILD
)
||
(
style
&
WS_POPUP
)))
ok
(
style
==
GetWindowLongA
(
hwnd
,
GWL_STYLE
),
"style of hwnd and style in the CREATESTRUCT do not match: %08x != %08x
\n
"
,
GetWindowLongA
(
hwnd
,
GWL_STYLE
),
style
);
if
(
0
)
{
...
...
@@ -4444,9 +4445,8 @@ static LRESULT WINAPI cbt_proc(int ncode, WPARAM wparam, LPARAM lparam)
ts
=
c
->
lpcs
->
lpCreateParams
;
ok
(
ts
!=
NULL
,
"lpCreateParams not set
\n
"
);
todo_wine_if
(
!
(
ts
->
cs_style
&
WS_CHILD
)
||
(
ts
->
cs_style
&
WS_POPUP
))
ok
(
c
->
lpcs
->
style
==
ts
->
cs_style
,
"style = 0x%08x, expected 0x%08x
\n
"
,
c
->
lpcs
->
style
,
ts
->
cs_style
);
ok
(
c
->
lpcs
->
style
==
ts
->
cs_style
,
"style = 0x%08x, expected 0x%08x
\n
"
,
c
->
lpcs
->
style
,
ts
->
cs_style
);
ok
(
c
->
lpcs
->
dwExStyle
==
ts
->
cs_exstyle
,
"exstyle = 0x%08x, expected 0x%08x
\n
"
,
c
->
lpcs
->
dwExStyle
,
ts
->
cs_exstyle
);
...
...
dlls/user32/win.c
View file @
1b6f8a1a
...
...
@@ -1706,7 +1706,6 @@ HWND WIN_CreateWindowEx( CREATESTRUCTW *cs, LPCWSTR className, HINSTANCE module,
}
else
SetWindowLongPtrW
(
hwnd
,
GWLP_ID
,
(
ULONG_PTR
)
cs
->
hMenu
);
style
=
wndPtr
->
dwStyle
;
win_dpi
=
wndPtr
->
dpi
;
WIN_ReleasePtr
(
wndPtr
);
...
...
@@ -1716,12 +1715,7 @@ HWND WIN_CreateWindowEx( CREATESTRUCTW *cs, LPCWSTR className, HINSTANCE module,
/* call the WH_CBT hook */
/* the window style passed to the hook must be the real window style,
* rather than just the window style that the caller to CreateWindowEx
* passed in, so we have to copy the original CREATESTRUCT and get the
* the real style. */
cbcs
=
*
cs
;
cbcs
.
style
=
style
;
cbtc
.
lpcs
=
&
cbcs
;
cbtc
.
hwndInsertAfter
=
HWND_TOP
;
if
(
HOOK_CallHooks
(
WH_CBT
,
HCBT_CREATEWND
,
(
WPARAM
)
hwnd
,
(
LPARAM
)
&
cbtc
,
unicode
))
goto
failed
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment