Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
aef7723c
Commit
aef7723c
authored
Sep 16, 2008
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
user32: Don't reinitialize the window placement even if the window rect is empty.
parent
01584fb3
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
19 additions
and
31 deletions
+19
-31
win.c
dlls/user32/win.c
+3
-0
winpos.c
dlls/user32/winpos.c
+16
-31
No files found.
dlls/user32/win.c
View file @
aef7723c
...
...
@@ -1072,6 +1072,9 @@ static HWND WIN_CreateWindowEx( CREATESTRUCTA *cs, LPCWSTR className, UINT flags
wndPtr
->
hSysMenu
=
0
;
wndPtr
->
flags
|=
(
flags
&
WIN_ISWIN32
);
wndPtr
->
min_pos
.
x
=
wndPtr
->
min_pos
.
y
=
-
1
;
wndPtr
->
max_pos
.
x
=
wndPtr
->
max_pos
.
y
=
-
1
;
if
(
wndPtr
->
dwStyle
&
WS_SYSMENU
)
SetSystemMenu
(
hwnd
,
0
);
/*
...
...
dlls/user32/winpos.c
View file @
aef7723c
...
...
@@ -582,36 +582,6 @@ BOOL WINAPI MoveWindow( HWND hwnd, INT x, INT y, INT cx, INT cy,
return
SetWindowPos
(
hwnd
,
0
,
x
,
y
,
cx
,
cy
,
flags
);
}
/***********************************************************************
* WINPOS_InitPlacement
*/
static
void
WINPOS_InitPlacement
(
WND
*
wnd
)
{
if
(
IsRectEmpty
(
&
wnd
->
normal_rect
))
{
/* this happens when the window is minimized/maximized
* for the first time (rectWindow is not adjusted yet) */
wnd
->
normal_rect
=
wnd
->
rectWindow
;
wnd
->
min_pos
.
x
=
wnd
->
min_pos
.
y
=
-
1
;
wnd
->
max_pos
.
x
=
wnd
->
max_pos
.
y
=
-
1
;
}
if
(
wnd
->
dwStyle
&
WS_MINIMIZE
)
{
wnd
->
min_pos
.
x
=
wnd
->
rectWindow
.
left
;
wnd
->
min_pos
.
y
=
wnd
->
rectWindow
.
top
;
}
else
if
(
wnd
->
dwStyle
&
WS_MAXIMIZE
)
{
wnd
->
max_pos
.
x
=
wnd
->
rectWindow
.
left
;
wnd
->
max_pos
.
y
=
wnd
->
rectWindow
.
top
;
}
else
{
wnd
->
normal_rect
=
wnd
->
rectWindow
;
}
}
/***********************************************************************
* WINPOS_RedrawIconTitle
...
...
@@ -1201,7 +1171,22 @@ BOOL WINAPI GetWindowPlacement( HWND hwnd, WINDOWPLACEMENT *wndpl )
return
FALSE
;
}
WINPOS_InitPlacement
(
pWnd
);
/* update the placement according to the current style */
if
(
pWnd
->
dwStyle
&
WS_MINIMIZE
)
{
pWnd
->
min_pos
.
x
=
pWnd
->
rectWindow
.
left
;
pWnd
->
min_pos
.
y
=
pWnd
->
rectWindow
.
top
;
}
else
if
(
pWnd
->
dwStyle
&
WS_MAXIMIZE
)
{
pWnd
->
max_pos
.
x
=
pWnd
->
rectWindow
.
left
;
pWnd
->
max_pos
.
y
=
pWnd
->
rectWindow
.
top
;
}
else
{
pWnd
->
normal_rect
=
pWnd
->
rectWindow
;
}
wndpl
->
length
=
sizeof
(
*
wndpl
);
if
(
pWnd
->
dwStyle
&
WS_MINIMIZE
)
wndpl
->
showCmd
=
SW_SHOWMINIMIZED
;
...
...
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