forked from AuroraMiddleware/gtk
Merge branch 'wip/keep-scale-3-24' into 'gtk-3-24'
wayland/window: Only update the scale if on any outputs See merge request GNOME/gtk!4353
This commit is contained in:
commit
dac9baf3b1
@ -753,12 +753,23 @@ window_update_scale (GdkWindow *window)
|
||||
return;
|
||||
}
|
||||
|
||||
scale = 1;
|
||||
for (l = impl->display_server.outputs; l != NULL; l = l->next)
|
||||
if (!impl->display_server.outputs)
|
||||
{
|
||||
guint32 output_scale =
|
||||
_gdk_wayland_screen_get_output_scale (display_wayland->screen, l->data);
|
||||
scale = MAX (scale, output_scale);
|
||||
scale = impl->scale;
|
||||
}
|
||||
else
|
||||
{
|
||||
scale = 1;
|
||||
for (l = impl->display_server.outputs; l != NULL; l = l->next)
|
||||
{
|
||||
struct wl_output *output = l->data;
|
||||
uint32_t output_scale;
|
||||
|
||||
output_scale =
|
||||
_gdk_wayland_screen_get_output_scale (display_wayland->screen,
|
||||
output);
|
||||
scale = MAX (scale, output_scale);
|
||||
}
|
||||
}
|
||||
|
||||
/* Notify app that scale changed */
|
||||
|
Loading…
Reference in New Issue
Block a user