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
dcd8cf72
Commit
dcd8cf72
authored
Nov 20, 2008
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
user32/tests: Fix the monitor tests on NT4.
parent
bda507fb
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
6 deletions
+8
-6
monitor.c
dlls/user32/tests/monitor.c
+8
-6
No files found.
dlls/user32/tests/monitor.c
View file @
dcd8cf72
...
...
@@ -88,7 +88,6 @@ static void test_enumdisplaydevices(void)
BOOL
ret
;
HDC
dc
;
ret
=
pEnumDisplayDevicesA
(
NULL
,
num
,
&
dd
,
0
);
ok
(
ret
||
num
!=
0
,
"EnumDisplayDevices fails with num == 0
\n
"
);
if
(
!
ret
)
break
;
if
(
dd
.
StateFlags
&
DISPLAY_DEVICE_PRIMARY_DEVICE
)
{
...
...
@@ -104,11 +103,10 @@ static void test_enumdisplaydevices(void)
}
num
++
;
}
ok
(
primary_num
!=
-
1
,
"Didn't get the primary device
\n
"
);
if
(
!
pEnumDisplayMonitors
||
!
pGetMonitorInfoA
)
if
(
primary_num
==
-
1
||
!
pEnumDisplayMonitors
||
!
pGetMonitorInfoA
)
{
skip
(
"EnumDisplayMonitors or GetMonitorInfoA are not available
\n
"
);
win_
skip
(
"EnumDisplayMonitors or GetMonitorInfoA are not available
\n
"
);
return
;
}
...
...
@@ -172,7 +170,8 @@ static void test_ChangeDisplaySettingsEx(void)
res
=
ChangeDisplaySettingsA
(
&
dm
,
CDS_TEST
);
ok
(
res
==
DISP_CHANGE_SUCCESSFUL
,
"ChangeDisplaySettingsA returned %d, expected DISP_CHANGE_SUCCESSFUL
\n
"
,
res
);
ok
(
dm
.
dmDriverExtra
==
0
,
"ChangeDisplaySettingsA didn't reset dmDriverExtra to 0
\n
"
);
ok
(
dm
.
dmDriverExtra
==
0
||
broken
(
dm
.
dmDriverExtra
==
1
)
/* win9x */
,
"ChangeDisplaySettingsA didn't reset dmDriverExtra to 0
\n
"
);
/* crashes under XP SP3 for large dmDriverExtra values */
dm
.
dmDriverExtra
=
1
;
...
...
@@ -225,8 +224,9 @@ static void test_ChangeDisplaySettingsEx(void)
res
=
pChangeDisplaySettingsExW
(
NULL
,
&
dmW
,
NULL
,
CDS_TEST
,
NULL
);
if
(
GetLastError
()
!=
ERROR_CALL_NOT_IMPLEMENTED
)
ok
(
res
==
DISP_CHANGE_FAILED
||
res
==
DISP_CHANGE_BADPARAM
||
/* NT4 */
res
==
DISP_CHANGE_BADMODE
/* XP SP3 */
,
"ChangeDisplaySettingsExW returned %d
, expected DISP_CHANGE_FAILED or DISP_CHANGE_BADMODE
\n
"
,
res
);
"ChangeDisplaySettingsExW returned %d
\n
"
,
res
);
memset
(
&
dm
,
0
,
sizeof
(
dm
));
dm
.
dmSize
=
sizeof
(
dm
);
...
...
@@ -249,6 +249,8 @@ static void test_ChangeDisplaySettingsEx(void)
RECT
r
,
r1
,
virt
;
SetRect
(
&
virt
,
0
,
0
,
GetSystemMetrics
(
SM_CXVIRTUALSCREEN
),
GetSystemMetrics
(
SM_CYVIRTUALSCREEN
));
if
(
IsRectEmpty
(
&
virt
))
/* NT4 doesn't have SM_CX/YVIRTUALSCREEN */
SetRect
(
&
virt
,
0
,
0
,
GetSystemMetrics
(
SM_CXSCREEN
),
GetSystemMetrics
(
SM_CYSCREEN
));
OffsetRect
(
&
virt
,
GetSystemMetrics
(
SM_XVIRTUALSCREEN
),
GetSystemMetrics
(
SM_YVIRTUALSCREEN
));
/* Resolution change resets clip rect */
...
...
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