forked from AuroraMiddleware/gtk
GDK W32: Init display scale to the global Windows scale, not 1
This affects gdk_device_query_state() for the virtual device. It has no window, and is forced to query the display itself, and display defaults its scale to 1 even for HiDPI desktops. Use the same "query scale of a NULL monitor" trick that we use in other places to get the global desktop scale. https://bugzilla.gnome.org/show_bug.cgi?id=773299
This commit is contained in:
parent
6bdb004dfd
commit
6b50788901
@ -972,7 +972,7 @@ gdk_win32_display_init (GdkWin32Display *display)
|
||||
display->has_fixed_scale = TRUE;
|
||||
}
|
||||
else
|
||||
display->surface_scale = 1;
|
||||
display->surface_scale = _gdk_win32_display_get_monitor_scale_factor (display, NULL, NULL, NULL);
|
||||
|
||||
_gdk_win32_display_init_cursors (display);
|
||||
gdk_win32_display_check_composited (display);
|
||||
|
Loading…
Reference in New Issue
Block a user