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
a82f7cf4
Commit
a82f7cf4
authored
May 09, 2011
by
David Hedberg
Committed by
Alexandre Julliard
May 09, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winspool.drv: Add stubs for IsValidDevmodeW and IsValidDevmodeA.
parent
5920de5f
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
57 additions
and
0 deletions
+57
-0
info.c
dlls/winspool.drv/info.c
+32
-0
info.c
dlls/winspool.drv/tests/info.c
+23
-0
winspool.drv.spec
dlls/winspool.drv/winspool.drv.spec
+2
-0
No files found.
dlls/winspool.drv/info.c
View file @
a82f7cf4
...
...
@@ -1775,6 +1775,38 @@ LONG WINAPI DocumentPropertiesW(HWND hWnd, HANDLE hPrinter,
return
ret
;
}
/*****************************************************************************
* IsValidDevmodeA [WINSPOOL.@]
*
* Validate a DEVMODE structure and fix errors if possible.
*
*/
BOOL
WINAPI
IsValidDevmodeA
(
PDEVMODEA
*
pDevMode
,
SIZE_T
size
)
{
FIXME
(
"(%p,%ld): stub
\n
"
,
pDevMode
,
size
);
if
(
!
pDevMode
)
return
FALSE
;
return
TRUE
;
}
/*****************************************************************************
* IsValidDevmodeW [WINSPOOL.@]
*
* Validate a DEVMODE structure and fix errors if possible.
*
*/
BOOL
WINAPI
IsValidDevmodeW
(
PDEVMODEW
*
pDevMode
,
SIZE_T
size
)
{
FIXME
(
"(%p,%ld): stub
\n
"
,
pDevMode
,
size
);
if
(
!
pDevMode
)
return
FALSE
;
return
TRUE
;
}
/******************************************************************
* OpenPrinterA [WINSPOOL.@]
*
...
...
dlls/winspool.drv/tests/info.c
View file @
a82f7cf4
...
...
@@ -75,6 +75,7 @@ static BOOL (WINAPI * pGetPrinterDriverW)(HANDLE, LPWSTR, DWORD, LPBYTE, DWORD,
static
BOOL
(
WINAPI
*
pGetPrinterW
)(
HANDLE
,
DWORD
,
LPBYTE
,
DWORD
,
LPDWORD
);
static
BOOL
(
WINAPI
*
pSetDefaultPrinterA
)(
LPCSTR
);
static
DWORD
(
WINAPI
*
pXcvDataW
)(
HANDLE
,
LPCWSTR
,
PBYTE
,
DWORD
,
PBYTE
,
DWORD
,
PDWORD
,
PDWORD
);
static
BOOL
(
WINAPI
*
pIsValidDevmodeW
)(
PDEVMODEW
,
SIZE_T
);
/* ################################ */
...
...
@@ -2852,6 +2853,26 @@ static void test_DeviceCapabilities(void)
GlobalFree
(
prn_dlg
.
hDevNames
);
}
static
void
test_IsValidDevmodeW
(
void
)
{
BOOL
br
;
if
(
!
pIsValidDevmodeW
)
{
win_skip
(
"IsValidDevmodeW not implemented.
\n
"
);
return
;
}
br
=
pIsValidDevmodeW
(
NULL
,
0
);
ok
(
br
==
FALSE
,
"Got %d
\n
"
,
br
);
br
=
pIsValidDevmodeW
(
NULL
,
1
);
ok
(
br
==
FALSE
,
"Got %d
\n
"
,
br
);
br
=
pIsValidDevmodeW
(
NULL
,
sizeof
(
DEVMODEW
));
ok
(
br
==
FALSE
,
"Got %d
\n
"
,
br
);
}
START_TEST
(
info
)
{
hwinspool
=
GetModuleHandleA
(
"winspool.drv"
);
...
...
@@ -2863,6 +2884,7 @@ START_TEST(info)
pGetPrinterW
=
(
void
*
)
GetProcAddress
(
hwinspool
,
"GetPrinterW"
);
pSetDefaultPrinterA
=
(
void
*
)
GetProcAddress
(
hwinspool
,
"SetDefaultPrinterA"
);
pXcvDataW
=
(
void
*
)
GetProcAddress
(
hwinspool
,
"XcvDataW"
);
pIsValidDevmodeW
=
(
void
*
)
GetProcAddress
(
hwinspool
,
"IsValidDevmodeW"
);
on_win9x
=
check_win9x
();
if
(
on_win9x
)
...
...
@@ -2898,6 +2920,7 @@ START_TEST(info)
test_SetDefaultPrinter
();
test_XcvDataW_MonitorUI
();
test_XcvDataW_PortIsValid
();
test_IsValidDevmodeW
();
/* Cleanup our temporary file */
DeleteFileA
(
tempfileA
);
...
...
dlls/winspool.drv/winspool.drv.spec
View file @
a82f7cf4
...
...
@@ -145,6 +145,8 @@
@ stdcall GetPrinterDriverDirectoryW(wstr wstr long ptr long ptr)
@ stdcall GetPrinterDriverW(long wstr long ptr long ptr)
@ stdcall GetPrinterW(long long ptr long ptr)
@ stdcall IsValidDevmodeA(ptr long)
@ stdcall IsValidDevmodeW(ptr long)
@ stdcall OpenPrinterA(str ptr ptr)
@ stdcall OpenPrinterW(wstr ptr ptr)
@ stub PlayGdiScriptOnPrinterIC
...
...
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