Commit ec09dcf8 authored by Zhiyi Zhang's avatar Zhiyi Zhang Committed by Alexandre Julliard

winex11.drv: Add virtual desktop display device handler.

The virtual desktop display device handler is actually the Xinerama handler, but with a much higher priority. So that it will be preferred in virtual desktop mode when other display device handlers are introduced, e.g., the XRandR handler. Signed-off-by: 's avatarZhiyi Zhang <zzhang@codeweavers.com> Signed-off-by: 's avatarHuw Davies <huw@codeweavers.com> Signed-off-by: 's avatarAlexandre Julliard <julliard@winehq.org>
parent efbbe666
......@@ -304,6 +304,7 @@ void xinerama_init( unsigned int width, unsigned int height )
{
struct x11drv_display_device_handler handler;
MONITORINFOEXW *primary;
BOOL desktop_mode = FALSE;
int i;
RECT rect;
......@@ -318,6 +319,7 @@ void xinerama_init( unsigned int width, unsigned int height )
query_desktop_work_area( &default_monitor.rcWork );
nb_monitors = 1;
monitors = &default_monitor;
desktop_mode = TRUE;
}
primary = get_primary();
......@@ -334,8 +336,8 @@ void xinerama_init( unsigned int width, unsigned int height )
(monitors[i].dwFlags & MONITORINFOF_PRIMARY) ? " (primary)" : "" );
}
handler.name = "Xinerama";
handler.priority = 100;
handler.name = desktop_mode ? "Desktop" : "Xinerama";
handler.priority = desktop_mode ? 1000 : 100;
handler.pGetGpus = xinerama_get_gpus;
handler.pGetAdapters = xinerama_get_adapters;
handler.pGetMonitors = xinerama_get_monitors;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment