Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-fonts
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
Aleksandr Isakov
wine-fonts
Commits
0f96698b
Commit
0f96698b
authored
Jul 05, 2022
by
Rémi Bernon
Committed by
Alexandre Julliard
Jul 06, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
win32u: Add invisible winstation virtual monitor outside of nulldrv.
Signed-off-by:
Rémi Bernon
<
rbernon@codeweavers.com
>
parent
5414f648
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
15 deletions
+13
-15
driver.c
dlls/win32u/driver.c
+0
-1
sysparams.c
dlls/win32u/sysparams.c
+13
-14
No files found.
dlls/win32u/driver.c
View file @
0f96698b
...
...
@@ -767,7 +767,6 @@ static BOOL nulldrv_EnumDisplaySettingsEx( LPCWSTR name, DWORD num, LPDEVMODEW m
static
void
nulldrv_UpdateDisplayDevices
(
const
struct
gdi_device_manager
*
manager
,
BOOL
force
,
void
*
param
)
{
manager
->
add_monitor
(
NULL
,
param
);
/* use virtual monitor */
}
static
BOOL
nulldrv_CreateDesktopWindow
(
HWND
hwnd
)
...
...
dlls/win32u/sysparams.c
View file @
0f96698b
...
...
@@ -192,8 +192,6 @@ static const WCHAR guid_devinterface_monitorW[] =
{
'{'
,
'E'
,
'6'
,
'F'
,
'0'
,
'7'
,
'B'
,
'5'
,
'F'
,
'-'
,
'E'
,
'E'
,
'9'
,
'7'
,
'-'
,
'4'
,
'A'
,
'9'
,
'0'
,
'-'
,
'B'
,
'0'
,
'7'
,
'6'
,
'-'
,
'3'
,
'3'
,
'F'
,
'5'
,
'7'
,
'B'
,
'F'
,
'4'
,
'E'
,
'A'
,
'A'
,
'7'
,
'}'
,
0
};
#define NULLDRV_DEFAULT_HMONITOR ((HMONITOR)(UINT_PTR)(0x10000 + 1))
/* Cached display device information */
struct
display_device
{
...
...
@@ -233,9 +231,10 @@ static pthread_mutex_t display_lock = PTHREAD_MUTEX_INITIALIZER;
BOOL
enable_thunk_lock
=
FALSE
;
#define VIRTUAL_HMONITOR ((HMONITOR)(UINT_PTR)(0x10000 + 1))
static
struct
monitor
virtual_monitor
=
{
.
handle
=
NULLDRV_DEFAULT
_HMONITOR
,
.
handle
=
VIRTUAL
_HMONITOR
,
.
flags
=
MONITORINFOF_PRIMARY
,
.
rc_monitor
.
right
=
1024
,
.
rc_monitor
.
bottom
=
768
,
...
...
@@ -804,7 +803,6 @@ struct device_manager_ctx
WCHAR
gpu_guid
[
64
];
LUID
gpu_luid
;
HKEY
adapter_key
;
BOOL
virtual_monitor
;
};
static
void
link_device
(
const
WCHAR
*
instance
,
const
WCHAR
*
class
)
...
...
@@ -1078,12 +1076,6 @@ static void add_monitor( const struct gdi_monitor *monitor, void *param )
static
const
WCHAR
default_monitorW
[]
=
{
'M'
,
'O'
,
'N'
,
'I'
,
'T'
,
'O'
,
'R'
,
'\\'
,
'D'
,
'e'
,
'f'
,
'a'
,
'u'
,
'l'
,
't'
,
'_'
,
'M'
,
'o'
,
'n'
,
'i'
,
't'
,
'o'
,
'r'
,
0
,
0
};
if
(
!
monitor
)
{
ctx
->
virtual_monitor
=
TRUE
;
return
;
}
TRACE
(
"%s %s %s
\n
"
,
debugstr_w
(
monitor
->
name
),
wine_dbgstr_rect
(
&
monitor
->
rc_monitor
),
wine_dbgstr_rect
(
&
monitor
->
rc_work
)
);
...
...
@@ -1319,17 +1311,24 @@ static BOOL update_display_cache_from_registry(void)
static
BOOL
update_display_cache
(
void
)
{
struct
device_manager_ctx
ctx
=
{
0
};
HWINSTA
winstation
=
NtUserGetProcessWindowStation
();
struct
device_manager_ctx
ctx
=
{
0
};
USEROBJECTFLAGS
flags
;
user_driver
->
pUpdateDisplayDevices
(
&
device_manager
,
FALSE
,
&
ctx
);
release_display_manager_ctx
(
&
ctx
);
if
(
ctx
.
virtual_monitor
)
/* services do not have any adapters, only a virtual monitor */
if
(
NtUserGetObjectInformation
(
winstation
,
UOI_FLAGS
,
&
flags
,
sizeof
(
flags
),
NULL
)
&&
!
(
flags
.
dwFlags
&
WSF_VISIBLE
)
)
{
pthread_mutex_lock
(
&
display_lock
);
clear_display_devices
();
list_add_tail
(
&
monitors
,
&
virtual_monitor
.
entry
);
pthread_mutex_unlock
(
&
display_lock
);
return
TRUE
;
}
user_driver
->
pUpdateDisplayDevices
(
&
device_manager
,
FALSE
,
&
ctx
);
release_display_manager_ctx
(
&
ctx
);
if
(
update_display_cache_from_registry
())
return
TRUE
;
if
(
ctx
.
gpu_count
)
{
...
...
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