layout: Set active output NULL when displaying background 55/25355/1
authorWalter Lozano <walter.lozano@collabora.com>
Wed, 23 Sep 2020 12:41:49 +0000 (12:41 +0000)
committerWalter Lozano <walter.lozano@collabora.com>
Mon, 28 Sep 2020 15:17:42 +0000 (12:17 -0300)
Currently agl-compositor keeps track of the active app and uses this
information to to also keep track of the previous one. This is useful
to allow to show the previous activated app when deactivating the
current one.

However, when deactivating all the apps, for instance the background,
this information is not saved, which causes that when activating and
deactivating and new app, instead of the background a different app
shows.

This patch sets  output->previous_active = NULL when displaying the
background to overcome this issue.

Signed-off-by: Walter Lozano <walter.lozano@collabora.com>
Change-Id: I29c3f8972d6055d2387e0fdcbb28574d3d2e38a7

src/layout.c

index dd7e75f..1895a07 100644 (file)
@@ -824,6 +824,7 @@ ivi_layout_deactivate(struct ivi_compositor *ivi, const char *app_id)
 
                                weston_layer_entry_remove(&view->layer_link);
                                weston_output_damage(ivi_output->output);
+                               ivi_output->active = NULL;
                        }
                } else {
                        struct weston_desktop_surface *dsurface;