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
967ec70f
Commit
967ec70f
authored
Jun 26, 1999
by
Abey George
Committed by
Alexandre Julliard
Jun 26, 1999
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
The system menu icon on a MDI child window was corrupted when the
child frame window is maximized within the main frame when the wine look is Windows 95.
parent
359a748d
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
39 additions
and
3 deletions
+39
-3
mdi.c
windows/mdi.c
+38
-1
sysmetrics.c
windows/sysmetrics.c
+1
-2
No files found.
windows/mdi.c
View file @
967ec70f
...
...
@@ -808,6 +808,7 @@ static BOOL MDI_AugmentFrameMenu( MDICLIENTINFO* ci, WND *frame,
{
WND
*
child
=
WIN_FindWndPtr
(
hChild
);
HMENU
hSysPopup
=
0
;
HBITMAP
hSysMenuBitmap
=
0
;
TRACE
(
mdi
,
"frame %p,child %04x
\n
"
,
frame
,
hChild
);
...
...
@@ -831,8 +832,44 @@ static BOOL MDI_AugmentFrameMenu( MDICLIENTINFO* ci, WND *frame,
AppendMenuA
(
frame
->
wIDmenu
,
MF_HELP
|
MF_BITMAP
,
SC_RESTORE
,
(
LPSTR
)(
DWORD
)
HBMMENU_MBAR_RESTORE
);
/* In Win 95 look, the system menu is replaced by the child icon */
if
(
TWEAK_WineLook
>
WIN31_LOOK
)
{
HICON
hIcon
=
GetClassLongA
(
hChild
,
GCL_HICONSM
);
if
(
!
hIcon
)
hIcon
=
GetClassLongA
(
hChild
,
GCL_HICON
);
if
(
hIcon
)
{
HDC
hMemDC
;
HBITMAP
hBitmap
,
hOldBitmap
;
HBRUSH
hBrush
;
HDC
hdc
=
GetDC
(
hChild
);
if
(
hdc
)
{
int
cx
,
cy
;
cx
=
GetSystemMetrics
(
SM_CXSMICON
);
cy
=
GetSystemMetrics
(
SM_CYSMICON
);
hMemDC
=
CreateCompatibleDC
(
hdc
);
hBitmap
=
CreateCompatibleBitmap
(
hdc
,
cx
,
cy
);
hOldBitmap
=
SelectObject
(
hMemDC
,
hBitmap
);
SetMapMode
(
hMemDC
,
MM_TEXT
);
hBrush
=
CreateSolidBrush
(
GetSysColor
(
COLOR_MENU
));
DrawIconEx
(
hMemDC
,
0
,
0
,
hIcon
,
cx
,
cy
,
0
,
hBrush
,
DI_NORMAL
);
SelectObject
(
hMemDC
,
hOldBitmap
);
DeleteObject
(
hBrush
);
DeleteDC
(
hMemDC
);
ReleaseDC
(
hChild
,
hdc
);
hSysMenuBitmap
=
hBitmap
;
}
}
}
else
hSysMenuBitmap
=
hBmpClose
;
if
(
!
InsertMenuA
(
frame
->
wIDmenu
,
0
,
MF_BYPOSITION
|
MF_BITMAP
|
MF_POPUP
,
hSysPopup
,
(
LPSTR
)(
DWORD
)
h
BmpClose
))
hSysPopup
,
(
LPSTR
)(
DWORD
)
h
SysMenuBitmap
))
{
TRACE
(
mdi
,
"not inserted
\n
"
);
DestroyMenu
(
hSysPopup
);
...
...
windows/sysmetrics.c
View file @
967ec70f
...
...
@@ -117,8 +117,7 @@ void SYSMETRICS_Init(void)
sysMetrics
[
SM_CYEDGE
]
=
sysMetrics
[
SM_CXEDGE
];
sysMetrics
[
SM_CXMINSPACING
]
=
160
;
sysMetrics
[
SM_CYMINSPACING
]
=
24
;
sysMetrics
[
SM_CXSMICON
]
=
sysMetrics
[
SM_CYSIZE
]
-
(
sysMetrics
[
SM_CYSIZE
]
%
2
)
-
2
;
sysMetrics
[
SM_CXSMICON
]
=
sysMetrics
[
SM_CYSIZE
]
-
(
sysMetrics
[
SM_CYSIZE
]
%
2
);
sysMetrics
[
SM_CYSMICON
]
=
sysMetrics
[
SM_CXSMICON
];
sysMetrics
[
SM_CYSMCAPTION
]
=
16
;
sysMetrics
[
SM_CXSMSIZE
]
=
15
;
...
...
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