desktop-shell: Invalidate saved position when output is destroyed
If the saved position for a fullscreen or maximized output view is in an
output that has been unplugged, the coordinates don't make sense
anymore. In that case, invalidate them and use the initial position
algorithm when changing them back to the basic state.
Signed-off-by: Zhang, Xiong Y <xiong.y.zhang@intel.com>
Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com>
diff --git a/src/compositor.c b/src/compositor.c
index af33fda..c4ffb5e 100644
--- a/src/compositor.c
+++ b/src/compositor.c
@@ -409,6 +409,9 @@
}
weston_view_set_position(ev, x, y);
+
+ if (ev->surface->output_destroyed)
+ ev->surface->output_destroyed(ev->surface);
}
WL_EXPORT struct weston_view *