[gtk3/wayland] Fix GdkMonitor sizes on Mutter without fractional scaling.
This is the gtk3 version of !6722. This fixes a problem that is apparent in https://bugzilla.mozilla.org/show_bug.cgi?id=1869724, but that also reproduces on any GTK application as described in https://bugzilla.mozilla.org/show_bug.cgi?id=1869724#c16. xdg_output sizes might be physical if the compositor doesn't scale them, it seems. So to report the correct logical geometry in GDK pixels, we need to detect this case. We do this by checking whether the wl_output size matches the xdg_output size.
This commit is contained in:
		| @ -31,11 +31,10 @@ struct _GdkWaylandMonitor { | ||||
|   struct wl_output *output; | ||||
|  | ||||
|   struct zxdg_output_v1 *xdg_output; | ||||
|   /* Size and position, can be either from wl_output or xdg_output */ | ||||
|   int32_t x; | ||||
|   int32_t y; | ||||
|   int32_t width; | ||||
|   int32_t height; | ||||
|   /* Raw wl_output data */ | ||||
|   GdkRectangle output_geometry; | ||||
|   /* Raw xdg_output data */ | ||||
|   GdkRectangle xdg_output_geometry; | ||||
|   char *name; | ||||
|   gboolean wl_output_done; | ||||
|   gboolean xdg_output_done; | ||||
|  | ||||
		Reference in New Issue
	
	Block a user
	 Emilio Cobos Álvarez
					Emilio Cobos Álvarez