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
46c80c88
Commit
46c80c88
authored
Nov 11, 2002
by
Dmitry Timoshkov
Committed by
Alexandre Julliard
Nov 11, 2002
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix copy/paste bug. Make MessageBox without an icon look better.
parent
b6c3d0cb
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
3 deletions
+9
-3
msgbox.c
windows/msgbox.c
+9
-3
No files found.
windows/msgbox.c
View file @
46c80c88
...
...
@@ -70,7 +70,7 @@ static HFONT MSGBOX_OnInit(HWND hwnd, LPMSGBOXPARAMSW lpmb)
}
else
{
if
(
LoadStringW
(
0
,
IDS_ERROR
,
buf
,
256
))
if
(
LoadStringW
(
GetModuleHandleA
(
"user32.dll"
)
,
IDS_ERROR
,
buf
,
256
))
SetWindowTextW
(
hwnd
,
buf
);
}
}
...
...
@@ -158,6 +158,11 @@ static HFONT MSGBOX_OnInit(HWND hwnd, LPMSGBOXPARAMSW lpmb)
/* Get the icon height */
GetWindowRect
(
GetDlgItem
(
hwnd
,
MSGBOX_IDICON
),
&
rect
);
MapWindowPoints
(
0
,
hwnd
,
(
LPPOINT
)
&
rect
,
2
);
if
(
!
(
lpmb
->
dwStyle
&
MB_ICONMASK
))
{
rect
.
bottom
=
rect
.
top
;
rect
.
right
=
rect
.
left
;
}
iheight
=
rect
.
bottom
-
rect
.
top
;
ileft
=
rect
.
left
;
iwidth
=
rect
.
right
-
ileft
;
...
...
@@ -198,7 +203,8 @@ static HFONT MSGBOX_OnInit(HWND hwnd, LPMSGBOXPARAMSW lpmb)
DrawTextW
(
hdc
,
lpszText
,
-
1
,
&
rect
,
DT_LEFT
|
DT_EXPANDTABS
|
DT_WORDBREAK
|
DT_CALCRECT
);
/* Min text width corresponds to space for the buttons */
tleft
=
2
*
ileft
+
iwidth
;
tleft
=
ileft
;
if
(
iwidth
)
tleft
+=
ileft
+
iwidth
;
twidth
=
max
((
bw
+
bspace
)
*
buttons
+
bspace
-
tleft
,
rect
.
right
);
theight
=
rect
.
bottom
;
...
...
@@ -407,7 +413,7 @@ INT WINAPI MessageBoxIndirectA( LPMSGBOXPARAMSA msgbox )
if
(
HIWORD
(
msgbox
->
lpszIcon
))
RtlCreateUnicodeStringFromAsciiz
(
&
iconW
,
msgbox
->
lpszIcon
);
else
capti
onW
.
Buffer
=
(
LPWSTR
)
msgbox
->
lpszIcon
;
ic
onW
.
Buffer
=
(
LPWSTR
)
msgbox
->
lpszIcon
;
msgboxW
.
cbSize
=
sizeof
(
msgboxW
);
msgboxW
.
hwndOwner
=
msgbox
->
hwndOwner
;
...
...
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