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
cd337174
Commit
cd337174
authored
Jul 30, 2008
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
user32: Return a proper rectangle from WINPOS_MinMaximize.
parent
ee120e01
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
8 deletions
+9
-8
win.c
dlls/user32/win.c
+2
-1
winpos.c
dlls/user32/winpos.c
+7
-7
No files found.
dlls/user32/win.c
View file @
cd337174
...
...
@@ -1249,7 +1249,8 @@ static HWND WIN_CreateWindowEx( CREATESTRUCTA *cs, LPCWSTR className, UINT flags
swFlag
=
WINPOS_MinMaximize
(
hwnd
,
swFlag
,
&
newPos
);
swFlag
|=
SWP_FRAMECHANGED
;
/* Frame always gets changed */
if
(
!
(
style
&
WS_VISIBLE
)
||
(
style
&
WS_CHILD
)
||
GetActiveWindow
())
swFlag
|=
SWP_NOACTIVATE
;
SetWindowPos
(
hwnd
,
0
,
newPos
.
left
,
newPos
.
top
,
newPos
.
right
,
newPos
.
bottom
,
swFlag
);
SetWindowPos
(
hwnd
,
0
,
newPos
.
left
,
newPos
.
top
,
newPos
.
right
-
newPos
.
left
,
newPos
.
bottom
-
newPos
.
top
,
swFlag
);
}
/* Notify the parent window only */
...
...
dlls/user32/winpos.c
View file @
cd337174
...
...
@@ -905,7 +905,8 @@ UINT WINPOS_MinMaximize( HWND hwnd, UINT cmd, LPRECT rect )
if
(
!
(
old_style
&
WS_MINIMIZE
))
swpFlags
|=
SWP_STATECHANGED
;
SetRect
(
rect
,
wpl
.
ptMinPosition
.
x
,
wpl
.
ptMinPosition
.
y
,
GetSystemMetrics
(
SM_CXICON
),
GetSystemMetrics
(
SM_CYICON
)
);
wpl
.
ptMinPosition
.
x
+
GetSystemMetrics
(
SM_CXICON
),
wpl
.
ptMinPosition
.
y
+
GetSystemMetrics
(
SM_CYICON
)
);
swpFlags
|=
SWP_NOCOPYBITS
;
break
;
...
...
@@ -919,7 +920,8 @@ UINT WINPOS_MinMaximize( HWND hwnd, UINT cmd, LPRECT rect )
if
(
old_style
&
WS_MINIMIZE
)
WINPOS_ShowIconTitle
(
hwnd
,
FALSE
);
if
(
!
(
old_style
&
WS_MAXIMIZE
))
swpFlags
|=
SWP_STATECHANGED
;
SetRect
(
rect
,
wpl
.
ptMaxPosition
.
x
,
wpl
.
ptMaxPosition
.
y
,
size
.
x
,
size
.
y
);
SetRect
(
rect
,
wpl
.
ptMaxPosition
.
x
,
wpl
.
ptMaxPosition
.
y
,
wpl
.
ptMaxPosition
.
x
+
size
.
x
,
wpl
.
ptMaxPosition
.
y
+
size
.
y
);
break
;
case
SW_SHOWNOACTIVATE
:
...
...
@@ -941,7 +943,8 @@ UINT WINPOS_MinMaximize( HWND hwnd, UINT cmd, LPRECT rect )
WINPOS_GetMinMaxInfo
(
hwnd
,
&
size
,
&
wpl
.
ptMaxPosition
,
NULL
,
NULL
);
WIN_SetStyle
(
hwnd
,
WS_MAXIMIZE
,
0
);
swpFlags
|=
SWP_STATECHANGED
;
SetRect
(
rect
,
wpl
.
ptMaxPosition
.
x
,
wpl
.
ptMaxPosition
.
y
,
size
.
x
,
size
.
y
);
SetRect
(
rect
,
wpl
.
ptMaxPosition
.
x
,
wpl
.
ptMaxPosition
.
y
,
wpl
.
ptMaxPosition
.
x
+
size
.
x
,
wpl
.
ptMaxPosition
.
y
+
size
.
y
);
break
;
}
}
...
...
@@ -952,9 +955,6 @@ UINT WINPOS_MinMaximize( HWND hwnd, UINT cmd, LPRECT rect )
/* Restore to normal position */
*
rect
=
wpl
.
rcNormalPosition
;
rect
->
right
-=
rect
->
left
;
rect
->
bottom
-=
rect
->
top
;
break
;
}
...
...
@@ -1055,7 +1055,7 @@ static BOOL show_window( HWND hwnd, INT cmd )
}
else
SetWindowPos
(
hwnd
,
HWND_TOP
,
newPos
.
left
,
newPos
.
top
,
newPos
.
right
,
newPos
.
bottom
,
LOWORD
(
swp
)
);
newPos
.
right
-
newPos
.
left
,
newPos
.
bottom
-
newPos
.
top
,
swp
);
if
(
cmd
==
SW_HIDE
)
{
...
...
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