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
6ce6194f
Commit
6ce6194f
authored
Jan 22, 2009
by
Huw Davies
Committed by
Alexandre Julliard
Jan 23, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
comdlg32: Remove ugly macro.
parent
e2f81f1b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
13 deletions
+9
-13
printdlg.c
dlls/comdlg32/printdlg.c
+9
-13
No files found.
dlls/comdlg32/printdlg.c
View file @
6ce6194f
...
...
@@ -3432,14 +3432,12 @@ PRINTDLG_PS_WMCommandW(
/***********************************************************************
*
DefaultPagePaintH
ook
*
default_page_paint_h
ook
* Default hook paint procedure that receives WM_PSD_* messages from the dialog box
* whenever the sample page is redrawn.
*/
static
UINT_PTR
PRINTDLG_DefaultPagePaintHook
(
HWND
hwndDlg
,
UINT
uMsg
,
WPARAM
wParam
,
LPARAM
lParam
,
const
pagesetup_data
*
data
)
*/
static
UINT_PTR
default_page_paint_hook
(
HWND
hwndDlg
,
UINT
uMsg
,
WPARAM
wParam
,
LPARAM
lParam
,
const
pagesetup_data
*
data
)
{
LPRECT
lprc
=
(
LPRECT
)
lParam
;
HDC
hdc
=
(
HDC
)
wParam
;
...
...
@@ -3547,7 +3545,6 @@ PRINTDLG_PagePaintProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
pagesetup_data
*
data
;
int
papersize
=
0
,
orientation
=
0
;
/* FIXME: set this values for user paint hook */
double
scalx
,
scaly
;
#define CALLPAINTHOOK(msg,lprc) PRINTDLG_DefaultPagePaintHook( hWnd, msg, (WPARAM)hdc, (LPARAM)lprc, data)
if
(
uMsg
!=
WM_PAINT
)
return
CallWindowProcA
(
lpfnStaticWndProc
,
hWnd
,
uMsg
,
wParam
,
lParam
);
...
...
@@ -3558,7 +3555,7 @@ PRINTDLG_PagePaintProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
WARN
(
"__WINE_PAGESETUPDLGDATA prop not set?
\n
"
);
return
FALSE
;
}
if
(
PRINTDLG_DefaultPagePaintH
ook
(
hWnd
,
WM_PSD_PAGESETUPDLG
,
MAKELONG
(
papersize
,
orientation
),
(
LPARAM
)
data
->
dlga
,
data
))
if
(
default_page_paint_h
ook
(
hWnd
,
WM_PSD_PAGESETUPDLG
,
MAKELONG
(
papersize
,
orientation
),
(
LPARAM
)
data
->
dlga
,
data
))
return
FALSE
;
hdc
=
BeginPaint
(
hWnd
,
&
ps
);
...
...
@@ -3577,8 +3574,8 @@ PRINTDLG_PagePaintProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
rcMargin
.
left
=
min
(
rcMargin
.
left
,
rcMargin
.
right
);
rcMargin
.
top
=
min
(
rcMargin
.
top
,
rcMargin
.
bottom
);
if
(
!
CALLPAINTHOOK
(
WM_PSD_FULLPAGERECT
,
&
rcClient
)
&&
!
CALLPAINTHOOK
(
WM_PSD_MINMARGINRECT
,
&
rcMargin
)
)
if
(
!
default_page_paint_hook
(
hWnd
,
WM_PSD_FULLPAGERECT
,
(
WPARAM
)
hdc
,
(
LPARAM
)
&
rcClient
,
data
)
&&
!
default_page_paint_hook
(
hWnd
,
WM_PSD_MINMARGINRECT
,
(
WPARAM
)
hdc
,
(
LPARAM
)
&
rcMargin
,
data
)
)
{
/* fill background */
hbrush
=
GetSysColorBrush
(
COLOR_3DHIGHLIGHT
);
...
...
@@ -3610,7 +3607,7 @@ PRINTDLG_PagePaintProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
DeleteObject
(
SelectObject
(
hdc
,
holdpen
));
DeleteObject
(
SelectObject
(
hdc
,
holdbrush
));
CALLPAINTHOOK
(
WM_PSD_MARGINRECT
,
&
rcMargin
);
default_page_paint_hook
(
hWnd
,
WM_PSD_MARGINRECT
,
(
WPARAM
)
hdc
,
(
LPARAM
)
&
rcMargin
,
data
);
/* give text a bit of a space from the frame */
rcMargin
.
left
+=
2
;
...
...
@@ -3622,12 +3619,11 @@ PRINTDLG_PagePaintProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
rcMargin
.
left
=
min
(
rcMargin
.
left
,
rcMargin
.
right
);
rcMargin
.
top
=
min
(
rcMargin
.
top
,
rcMargin
.
bottom
);
CALLPAINTHOOK
(
WM_PSD_GREEKTEXTRECT
,
&
rcMargin
);
default_page_paint_hook
(
hWnd
,
WM_PSD_GREEKTEXTRECT
,
(
WPARAM
)
hdc
,
(
LPARAM
)
&
rcMargin
,
data
);
}
EndPaint
(
hWnd
,
&
ps
);
return
FALSE
;
#undef CALLPAINTHOOK
}
/*******************************************************
...
...
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