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
9561d6e2
Commit
9561d6e2
authored
Jan 03, 2006
by
Vitaliy Margolen
Committed by
Alexandre Julliard
Jan 03, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gdi: Device name returned from EnumDisplayDevices is valid for CreateDC.
parent
e74bda9d
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
1 deletion
+11
-1
driver.c
dlls/gdi/driver.c
+3
-1
monitor.c
dlls/user/tests/monitor.c
+8
-0
No files found.
dlls/gdi/driver.c
View file @
9561d6e2
...
...
@@ -263,11 +263,13 @@ const DC_FUNCTIONS *DRIVER_load_driver( LPCWSTR name )
HMODULE
module
;
struct
graphics_driver
*
driver
;
static
const
WCHAR
displayW
[]
=
{
'd'
,
'i'
,
's'
,
'p'
,
'l'
,
'a'
,
'y'
,
0
};
static
const
WCHAR
display1W
[]
=
{
'\\'
,
'\\'
,
'.'
,
'\\'
,
'D'
,
'I'
,
'S'
,
'P'
,
'L'
,
'A'
,
'Y'
,
'1'
,
0
};
EnterCriticalSection
(
&
driver_section
);
/* display driver is a special case */
if
(
!
strcmpiW
(
name
,
displayW
))
if
(
!
strcmpiW
(
name
,
displayW
)
||
!
strcmpiW
(
name
,
display1W
))
{
driver
=
load_display_driver
();
LeaveCriticalSection
(
&
driver_section
);
...
...
dlls/user/tests/monitor.c
View file @
9561d6e2
...
...
@@ -67,6 +67,7 @@ static void test_enumdisplaydevices(void)
while
(
1
)
{
BOOL
ret
;
HDC
dc
;
ret
=
pEnumDisplayDevicesA
(
NULL
,
num
,
&
dd
,
0
);
ok
(
ret
||
num
!=
0
,
"EnumDisplayDevices fails with num == 0
\n
"
);
if
(
!
ret
)
break
;
...
...
@@ -75,6 +76,13 @@ static void test_enumdisplaydevices(void)
strcpy
(
primary_device_name
,
dd
.
DeviceName
);
primary_num
=
num
;
}
if
(
dd
.
StateFlags
&
DISPLAY_DEVICE_ATTACHED_TO_DESKTOP
)
{
/* test creating DC */
dc
=
CreateDCA
(
dd
.
DeviceName
,
NULL
,
NULL
,
NULL
);
ok
(
dc
!=
NULL
,
"Failed to CreateDC(
\"
%s
\"
) err=%ld
\n
"
,
dd
.
DeviceName
,
GetLastError
());
DeleteDC
(
dc
);
}
num
++
;
}
ok
(
primary_num
!=
-
1
,
"Didn't get the primary device
\n
"
);
...
...
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