mirror of
https://github.com/brl/mutter.git
synced 2024-12-23 03:22:04 +00:00
wayland/actor-surface: Do not set opaque region for XWayland clients
XWayland clients get their opaque region set from their window, not the surface. Doing both resulted in the surface constantly overwriting the opaque region - effectively disabling culling of XWayland clients. https://gitlab.gnome.org/GNOME/mutter/merge_requests/1049
This commit is contained in:
parent
98d7a542b0
commit
1981449776
@ -194,18 +194,22 @@ meta_wayland_actor_surface_real_sync_actor_state (MetaWaylandActorSurface *actor
|
||||
meta_surface_actor_set_input_region (surface_actor, NULL);
|
||||
}
|
||||
|
||||
if (surface->opaque_region)
|
||||
if (surface->window &&
|
||||
surface->window->client_type == META_WINDOW_CLIENT_TYPE_WAYLAND)
|
||||
{
|
||||
cairo_region_t *opaque_region;
|
||||
if (surface->opaque_region)
|
||||
{
|
||||
cairo_region_t *opaque_region;
|
||||
|
||||
opaque_region = cairo_region_copy (surface->opaque_region);
|
||||
cairo_region_intersect_rectangle (opaque_region, &surface_rect);
|
||||
meta_surface_actor_set_opaque_region (surface_actor, opaque_region);
|
||||
cairo_region_destroy (opaque_region);
|
||||
}
|
||||
else
|
||||
{
|
||||
meta_surface_actor_set_opaque_region (surface_actor, NULL);
|
||||
opaque_region = cairo_region_copy (surface->opaque_region);
|
||||
cairo_region_intersect_rectangle (opaque_region, &surface_rect);
|
||||
meta_surface_actor_set_opaque_region (surface_actor, opaque_region);
|
||||
cairo_region_destroy (opaque_region);
|
||||
}
|
||||
else
|
||||
{
|
||||
meta_surface_actor_set_opaque_region (surface_actor, NULL);
|
||||
}
|
||||
}
|
||||
|
||||
meta_surface_actor_set_transform (surface_actor, surface->buffer_transform);
|
||||
|
Loading…
Reference in New Issue
Block a user