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
18307391
Commit
18307391
authored
Dec 10, 2011
by
Dmitry Timoshkov
Committed by
Alexandre Julliard
Dec 12, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
user32: Strip WS_CAPTION|WS_SYSMENU when a dialog has DS_CONTROL style set.
parent
2e42ab15
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
41 additions
and
0 deletions
+41
-0
dialog.c
dlls/user32/dialog.c
+3
-0
win.c
dlls/user32/tests/win.c
+38
-0
No files found.
dlls/user32/dialog.c
View file @
18307391
...
...
@@ -557,6 +557,9 @@ static HWND DIALOG_CreateIndirect( HINSTANCE hInst, LPCVOID dlgTemplate,
rect
.
left
=
rect
.
top
=
0
;
rect
.
right
=
MulDiv
(
template
.
cx
,
xBaseUnit
,
4
);
rect
.
bottom
=
MulDiv
(
template
.
cy
,
yBaseUnit
,
8
);
if
(
template
.
style
&
DS_CONTROL
)
template
.
style
&=
~
(
WS_CAPTION
|
WS_SYSMENU
);
template
.
style
|=
DS_3DLOOK
;
if
(
template
.
style
&
DS_MODALFRAME
)
template
.
exStyle
|=
WS_EX_DLGMODALFRAME
;
...
...
dlls/user32/tests/win.c
View file @
18307391
...
...
@@ -3903,6 +3903,16 @@ static void test_dialog_styles(void)
check_dialog_style
(
WS_DLGFRAME
,
WS_EX_STATICEDGE
,
WS_CLIPSIBLINGS
|
WS_CAPTION
,
WS_EX_WINDOWEDGE
|
WS_EX_STATICEDGE
|
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_THICKFRAME
,
WS_EX_STATICEDGE
,
WS_THICKFRAME
|
WS_CLIPSIBLINGS
|
WS_CAPTION
,
WS_EX_WINDOWEDGE
|
WS_EX_STATICEDGE
|
WS_EX_CONTROLPARENT
);
check_dialog_style
(
DS_CONTROL
,
0
,
WS_CLIPSIBLINGS
|
WS_CAPTION
|
DS_CONTROL
,
WS_EX_WINDOWEDGE
|
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_CAPTION
,
0
,
WS_CAPTION
|
WS_CLIPSIBLINGS
,
WS_EX_WINDOWEDGE
|
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_BORDER
,
0
,
WS_CAPTION
|
WS_CLIPSIBLINGS
,
WS_EX_WINDOWEDGE
|
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_DLGFRAME
,
0
,
WS_CAPTION
|
WS_CLIPSIBLINGS
,
WS_EX_WINDOWEDGE
|
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_BORDER
|
DS_CONTROL
,
0
,
WS_CAPTION
|
DS_CONTROL
|
WS_CLIPSIBLINGS
,
WS_EX_WINDOWEDGE
|
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_DLGFRAME
|
DS_CONTROL
,
0
,
WS_CAPTION
|
DS_CONTROL
|
WS_CLIPSIBLINGS
,
WS_EX_WINDOWEDGE
|
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_CAPTION
|
WS_SYSMENU
,
0
,
WS_CAPTION
|
WS_SYSMENU
|
WS_CLIPSIBLINGS
,
WS_EX_WINDOWEDGE
|
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_SYSMENU
,
0
,
WS_CAPTION
|
WS_SYSMENU
|
WS_CLIPSIBLINGS
,
WS_EX_WINDOWEDGE
|
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_CAPTION
|
DS_CONTROL
,
0
,
WS_CAPTION
|
DS_CONTROL
|
WS_CLIPSIBLINGS
,
WS_EX_WINDOWEDGE
|
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_SYSMENU
|
DS_CONTROL
,
0
,
WS_CAPTION
|
DS_CONTROL
|
WS_CLIPSIBLINGS
,
WS_EX_WINDOWEDGE
|
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_CAPTION
|
WS_SYSMENU
|
DS_CONTROL
,
0
,
WS_CAPTION
|
DS_CONTROL
|
WS_CLIPSIBLINGS
,
WS_EX_WINDOWEDGE
|
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_OVERLAPPEDWINDOW
,
0
,
WS_CLIPSIBLINGS
|
WS_OVERLAPPEDWINDOW
,
WS_EX_WINDOWEDGE
|
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_CHILD
,
0
,
WS_CHILD
,
0
);
check_dialog_style
(
WS_CHILD
|
WS_DLGFRAME
,
0
,
WS_CHILD
|
WS_DLGFRAME
,
WS_EX_WINDOWEDGE
);
...
...
@@ -3911,7 +3921,15 @@ static void test_dialog_styles(void)
check_dialog_style
(
WS_CHILD
|
WS_THICKFRAME
,
WS_EX_STATICEDGE
,
WS_CHILD
|
WS_THICKFRAME
,
WS_EX_STATICEDGE
);
check_dialog_style
(
WS_CHILD
|
DS_CONTROL
,
0
,
WS_CHILD
|
DS_CONTROL
,
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_CHILD
|
WS_CAPTION
,
0
,
WS_CHILD
|
WS_CAPTION
,
WS_EX_WINDOWEDGE
);
check_dialog_style
(
WS_CHILD
|
WS_BORDER
,
0
,
WS_CHILD
|
WS_BORDER
,
0
);
check_dialog_style
(
WS_CHILD
|
WS_DLGFRAME
,
0
,
WS_CHILD
|
WS_DLGFRAME
,
WS_EX_WINDOWEDGE
);
check_dialog_style
(
WS_CHILD
|
WS_BORDER
|
DS_CONTROL
,
0
,
WS_CHILD
|
DS_CONTROL
,
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_CHILD
|
WS_DLGFRAME
|
DS_CONTROL
,
0
,
WS_CHILD
|
DS_CONTROL
,
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_CHILD
|
WS_CAPTION
|
WS_SYSMENU
,
0
,
WS_CHILD
|
WS_CAPTION
|
WS_SYSMENU
,
WS_EX_WINDOWEDGE
);
check_dialog_style
(
WS_CHILD
|
WS_SYSMENU
,
0
,
WS_CHILD
|
WS_SYSMENU
,
0
);
check_dialog_style
(
WS_CHILD
|
WS_CAPTION
|
DS_CONTROL
,
0
,
WS_CHILD
|
DS_CONTROL
,
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_CHILD
|
WS_SYSMENU
|
DS_CONTROL
,
0
,
WS_CHILD
|
DS_CONTROL
,
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_CHILD
|
WS_CAPTION
|
WS_SYSMENU
|
DS_CONTROL
,
0
,
WS_CHILD
|
DS_CONTROL
,
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_CHILD
,
WS_EX_WINDOWEDGE
,
WS_CHILD
,
0
);
check_dialog_style
(
WS_CHILD
,
WS_EX_DLGMODALFRAME
,
WS_CHILD
,
WS_EX_WINDOWEDGE
|
WS_EX_DLGMODALFRAME
);
check_dialog_style
(
WS_CHILD
,
WS_EX_DLGMODALFRAME
|
WS_EX_STATICEDGE
,
WS_CHILD
,
WS_EX_STATICEDGE
|
WS_EX_WINDOWEDGE
|
WS_EX_DLGMODALFRAME
);
...
...
@@ -3921,6 +3939,16 @@ static void test_dialog_styles(void)
check_dialog_style
(
WS_CHILD
|
WS_POPUP
|
WS_DLGFRAME
,
WS_EX_STATICEDGE
,
WS_CHILD
|
WS_POPUP
|
WS_DLGFRAME
|
WS_CLIPSIBLINGS
,
WS_EX_STATICEDGE
);
check_dialog_style
(
WS_CHILD
|
WS_POPUP
|
WS_THICKFRAME
,
WS_EX_STATICEDGE
,
WS_CHILD
|
WS_POPUP
|
WS_THICKFRAME
|
WS_CLIPSIBLINGS
,
WS_EX_STATICEDGE
);
check_dialog_style
(
WS_CHILD
|
WS_POPUP
|
DS_CONTROL
,
0
,
WS_CHILD
|
WS_POPUP
|
WS_CLIPSIBLINGS
|
DS_CONTROL
,
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_CHILD
|
WS_POPUP
|
WS_CAPTION
,
0
,
WS_CHILD
|
WS_POPUP
|
WS_CAPTION
|
WS_CLIPSIBLINGS
,
WS_EX_WINDOWEDGE
);
check_dialog_style
(
WS_CHILD
|
WS_POPUP
|
WS_BORDER
,
0
,
WS_CHILD
|
WS_POPUP
|
WS_BORDER
|
WS_CLIPSIBLINGS
,
0
);
check_dialog_style
(
WS_CHILD
|
WS_POPUP
|
WS_DLGFRAME
,
0
,
WS_CHILD
|
WS_POPUP
|
WS_DLGFRAME
|
WS_CLIPSIBLINGS
,
WS_EX_WINDOWEDGE
);
check_dialog_style
(
WS_CHILD
|
WS_POPUP
|
WS_BORDER
|
DS_CONTROL
,
0
,
WS_CHILD
|
WS_POPUP
|
DS_CONTROL
|
WS_CLIPSIBLINGS
,
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_CHILD
|
WS_POPUP
|
WS_DLGFRAME
|
DS_CONTROL
,
0
,
WS_CHILD
|
WS_POPUP
|
DS_CONTROL
|
WS_CLIPSIBLINGS
,
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_CHILD
|
WS_POPUP
|
WS_CAPTION
|
WS_SYSMENU
,
0
,
WS_CHILD
|
WS_POPUP
|
WS_CAPTION
|
WS_SYSMENU
|
WS_CLIPSIBLINGS
,
WS_EX_WINDOWEDGE
);
check_dialog_style
(
WS_CHILD
|
WS_POPUP
|
WS_SYSMENU
,
0
,
WS_CHILD
|
WS_POPUP
|
WS_SYSMENU
|
WS_CLIPSIBLINGS
,
0
);
check_dialog_style
(
WS_CHILD
|
WS_POPUP
|
WS_CAPTION
|
DS_CONTROL
,
0
,
WS_CHILD
|
WS_POPUP
|
DS_CONTROL
|
WS_CLIPSIBLINGS
,
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_CHILD
|
WS_POPUP
|
WS_SYSMENU
|
DS_CONTROL
,
0
,
WS_CHILD
|
WS_POPUP
|
DS_CONTROL
|
WS_CLIPSIBLINGS
,
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_CHILD
|
WS_POPUP
|
WS_CAPTION
|
WS_SYSMENU
|
DS_CONTROL
,
0
,
WS_CHILD
|
WS_POPUP
|
DS_CONTROL
|
WS_CLIPSIBLINGS
,
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_CHILD
|
WS_POPUP
,
WS_EX_APPWINDOW
,
WS_CHILD
|
WS_POPUP
|
WS_CLIPSIBLINGS
,
WS_EX_APPWINDOW
);
check_dialog_style
(
WS_CHILD
|
WS_POPUP
,
WS_EX_WINDOWEDGE
,
WS_CHILD
|
WS_POPUP
|
WS_CLIPSIBLINGS
,
0
);
check_dialog_style
(
WS_CHILD
,
WS_EX_WINDOWEDGE
,
WS_CHILD
,
0
);
...
...
@@ -3932,6 +3960,16 @@ static void test_dialog_styles(void)
check_dialog_style
(
WS_POPUP
|
WS_DLGFRAME
,
WS_EX_STATICEDGE
,
WS_POPUP
|
WS_DLGFRAME
|
WS_CLIPSIBLINGS
,
WS_EX_STATICEDGE
|
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_POPUP
|
WS_THICKFRAME
,
WS_EX_STATICEDGE
,
WS_POPUP
|
WS_THICKFRAME
|
WS_CLIPSIBLINGS
,
WS_EX_STATICEDGE
|
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_POPUP
|
DS_CONTROL
,
0
,
WS_POPUP
|
WS_CLIPSIBLINGS
|
DS_CONTROL
,
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_POPUP
|
WS_CAPTION
,
0
,
WS_POPUP
|
WS_CAPTION
|
WS_CLIPSIBLINGS
,
WS_EX_WINDOWEDGE
|
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_POPUP
|
WS_BORDER
,
0
,
WS_POPUP
|
WS_BORDER
|
WS_CLIPSIBLINGS
,
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_POPUP
|
WS_DLGFRAME
,
0
,
WS_POPUP
|
WS_DLGFRAME
|
WS_CLIPSIBLINGS
,
WS_EX_WINDOWEDGE
|
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_POPUP
|
WS_BORDER
|
DS_CONTROL
,
0
,
WS_POPUP
|
DS_CONTROL
|
WS_CLIPSIBLINGS
,
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_POPUP
|
WS_DLGFRAME
|
DS_CONTROL
,
0
,
WS_POPUP
|
DS_CONTROL
|
WS_CLIPSIBLINGS
,
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_POPUP
|
WS_CAPTION
|
WS_SYSMENU
,
0
,
WS_POPUP
|
WS_CAPTION
|
WS_SYSMENU
|
WS_CLIPSIBLINGS
,
WS_EX_WINDOWEDGE
|
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_POPUP
|
WS_SYSMENU
,
0
,
WS_POPUP
|
WS_SYSMENU
|
WS_CLIPSIBLINGS
,
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_POPUP
|
WS_CAPTION
|
DS_CONTROL
,
0
,
WS_POPUP
|
DS_CONTROL
|
WS_CLIPSIBLINGS
,
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_POPUP
|
WS_SYSMENU
|
DS_CONTROL
,
0
,
WS_POPUP
|
DS_CONTROL
|
WS_CLIPSIBLINGS
,
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_POPUP
|
WS_CAPTION
|
WS_SYSMENU
|
DS_CONTROL
,
0
,
WS_POPUP
|
DS_CONTROL
|
WS_CLIPSIBLINGS
,
WS_EX_CONTROLPARENT
);
check_dialog_style
(
WS_CAPTION
,
WS_EX_STATICEDGE
,
WS_CLIPSIBLINGS
|
WS_CAPTION
,
WS_EX_STATICEDGE
|
WS_EX_WINDOWEDGE
|
WS_EX_CONTROLPARENT
);
check_dialog_style
(
0
,
WS_EX_APPWINDOW
,
WS_CLIPSIBLINGS
|
WS_CAPTION
,
WS_EX_APPWINDOW
|
WS_EX_WINDOWEDGE
|
WS_EX_CONTROLPARENT
);
...
...
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