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
d35fc436
Commit
d35fc436
authored
Aug 29, 2012
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
user32: Always go through set_window_pos when the WS_VISIBLE style is changed.
parent
4890964e
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
15 deletions
+20
-15
win.c
dlls/user32/win.c
+18
-1
window.c
dlls/winex11.drv/window.c
+2
-14
No files found.
dlls/user32/win.c
View file @
d35fc436
...
...
@@ -641,8 +641,16 @@ ULONG WIN_SetStyle( HWND hwnd, ULONG set_bits, ULONG clear_bits )
WIN_ReleasePtr
(
win
);
if
(
ok
)
{
if
((
style
.
styleOld
^
style
.
styleNew
)
&
WS_VISIBLE
)
{
RECT
window_rect
,
client_rect
;
UINT
flags
=
style
.
styleNew
&
WS_VISIBLE
?
SWP_SHOWWINDOW
:
0
;
/* we don't hide it */
WIN_GetRectangles
(
hwnd
,
COORDS_PARENT
,
&
window_rect
,
&
client_rect
);
set_window_pos
(
hwnd
,
0
,
SWP_NOSIZE
|
SWP_NOMOVE
|
SWP_NOCLIENTSIZE
|
SWP_NOCLIENTMOVE
|
SWP_NOZORDER
|
SWP_NOACTIVATE
|
flags
,
&
window_rect
,
&
client_rect
,
NULL
);
}
USER_Driver
->
pSetWindowStyle
(
hwnd
,
GWL_STYLE
,
&
style
);
if
((
style
.
styleOld
^
style
.
styleNew
)
&
WS_VISIBLE
)
invalidate_dce
(
hwnd
,
NULL
);
}
return
style
.
styleOld
;
}
...
...
@@ -2334,6 +2342,15 @@ LONG_PTR WIN_SetWindowLong( HWND hwnd, INT offset, UINT size, LONG_PTR newval, B
{
style
.
styleOld
=
retval
;
style
.
styleNew
=
newval
;
if
(
offset
==
GWL_STYLE
&&
((
style
.
styleOld
^
style
.
styleNew
)
&
WS_VISIBLE
))
{
RECT
window_rect
,
client_rect
;
UINT
flags
=
style
.
styleNew
&
WS_VISIBLE
?
SWP_SHOWWINDOW
:
0
;
/* we don't hide it */
WIN_GetRectangles
(
hwnd
,
COORDS_PARENT
,
&
window_rect
,
&
client_rect
);
set_window_pos
(
hwnd
,
0
,
SWP_NOSIZE
|
SWP_NOMOVE
|
SWP_NOCLIENTSIZE
|
SWP_NOCLIENTMOVE
|
SWP_NOZORDER
|
SWP_NOACTIVATE
|
flags
,
&
window_rect
,
&
client_rect
,
NULL
);
}
USER_Driver
->
pSetWindowStyle
(
hwnd
,
offset
,
&
style
);
SendMessageW
(
hwnd
,
WM_STYLECHANGED
,
offset
,
(
LPARAM
)
&
style
);
}
...
...
dlls/winex11.drv/window.c
View file @
d35fc436
...
...
@@ -1807,22 +1807,10 @@ void CDECL X11DRV_SetWindowStyle( HWND hwnd, INT offset, STYLESTRUCT *style )
DWORD
changed
;
if
(
hwnd
==
GetDesktopWindow
())
return
;
changed
=
style
->
styleNew
^
style
->
styleOld
;
/* if WS_VISIBLE was set through WM_SETREDRAW, map the window if it's the first time */
if
(
offset
==
GWL_STYLE
&&
(
changed
&
WS_VISIBLE
)
&&
(
style
->
styleNew
&
WS_VISIBLE
)
&&
!
data
)
{
if
(
!
(
data
=
X11DRV_create_win_data
(
hwnd
)))
return
;
if
(
data
->
whole_window
&&
is_window_rect_mapped
(
&
data
->
window_rect
))
{
Display
*
display
=
thread_display
();
set_wm_hints
(
display
,
data
);
if
(
!
data
->
mapped
)
map_window
(
display
,
data
,
style
->
styleNew
);
}
}
if
(
!
data
||
!
data
->
whole_window
)
return
;
changed
=
style
->
styleNew
^
style
->
styleOld
;
if
(
offset
==
GWL_STYLE
&&
(
changed
&
WS_DISABLED
))
set_wm_hints
(
thread_display
(),
data
);
...
...
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