mirror of
https://github.com/brl/mutter.git
synced 2024-12-26 12:52:14 +00:00
window-actor/wayland: Only use scanout for opaque non-fullscreen windows
This could for example happen with the client window created by the desktop-icons-ng extension which spans the entire desktop, but is not a fullscreen window and uses transparency On Wayland only opaque surfaces or transparent surfaces of fullscreen windows can be used for direct scanout. Related: https://gitlab.gnome.org/GNOME/mutter/-/issues/2263 Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/2409>
This commit is contained in:
parent
dc43bb9f68
commit
54ba64b9f2
@ -93,6 +93,7 @@ meta_window_actor_wayland_get_scanout_candidate (MetaWindowActor *actor)
|
||||
{
|
||||
ClutterActor *child_actor;
|
||||
MetaSurfaceActor *topmost_surface_actor;
|
||||
MetaWindow *window;
|
||||
|
||||
child_actor = clutter_actor_get_last_child (CLUTTER_ACTOR (actor));
|
||||
if (!child_actor || !META_IS_SURFACE_ACTOR_WAYLAND (child_actor))
|
||||
@ -100,6 +101,11 @@ meta_window_actor_wayland_get_scanout_candidate (MetaWindowActor *actor)
|
||||
|
||||
topmost_surface_actor = META_SURFACE_ACTOR (child_actor);
|
||||
|
||||
window = meta_window_actor_get_meta_window (actor);
|
||||
if (!meta_window_is_fullscreen (window) &&
|
||||
!meta_surface_actor_is_opaque (topmost_surface_actor))
|
||||
return NULL;
|
||||
|
||||
return topmost_surface_actor;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user