src: Don't attempt to split background role window 54/29654/3
authorMarius Vlad <marius.vlad@collabora.com>
Wed, 7 Feb 2024 15:46:15 +0000 (17:46 +0200)
committerMarius Vlad <marius.vlad@collabora.com>
Thu, 22 Feb 2024 13:51:33 +0000 (13:51 +0000)
If that window is a background one, this patch avoids doing that. The
background surface role needs to always be available. Discovered while
testing it out with flutter embedder.

Bug-AGL: SPEC-4839
Signed-off-by: Marius Vlad <marius.vlad@collabora.com>
Change-Id: Ia46b7ae590ea4feafa8a67efeb8ad540f6d2dfa0

src/layout.c
src/shell.c

index 0ab7e7c..95d3e54 100644 (file)
@@ -1050,7 +1050,7 @@ ivi_layout_reset_split_surfaces(struct ivi_compositor *ivi)
                return;
 
        output = ivisurf->current_completed_output;
-       if (output->previous_active) {
+       if (output->previous_active && output->background != output->previous_active) {
                struct weston_view *ev = output->previous_active->view;
                struct weston_output *woutput = output->output;
 
index cce4dec..a44dddf 100644 (file)
@@ -1921,7 +1921,7 @@ void shell_set_app_split(struct wl_client *client, struct wl_resource *res,
                return;
        }
 
-       if (output->previous_active) {
+       if (output->previous_active && output->background != output->previous_active) {
                struct weston_view *ev = output->previous_active->view;
 
                if (!weston_view_is_mapped(ev))