summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorQuentin Glidic <sardemff7+git@sardemff7.net>2016-08-16 10:55:02 +0200
committerQuentin Glidic <sardemff7+git@sardemff7.net>2016-08-16 11:10:41 +0200
commitf6636a8dec24340b9ec4ec5a1171d3efabf3904a (patch)
treeaf8219f7859e8e09a17f3e7e3ebe791299dd9436
parentf01ecee75ae435e50910ca852819ee11b22e3b1a (diff)
libweston-desktop/xwayland: Actually destroy the view
Signed-off-by: Quentin Glidic <sardemff7+git@sardemff7.net> Reviewed-by: Jonas Ã…dahl <jadahl@gmail.com>
-rw-r--r--libweston-desktop/xwayland.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/libweston-desktop/xwayland.c b/libweston-desktop/xwayland.c
index 927afab1..da04f7f8 100644
--- a/libweston-desktop/xwayland.c
+++ b/libweston-desktop/xwayland.c
@@ -81,6 +81,7 @@ weston_desktop_xwayland_surface_change_state(struct weston_desktop_xwayland_surf
if (surface->state != state) {
if (surface->state == XWAYLAND) {
weston_desktop_surface_unlink_view(surface->view);
+ weston_view_destroy(surface->view);
surface->view = NULL;
}
@@ -149,11 +150,13 @@ weston_desktop_xwayland_surface_destroy(struct weston_desktop_surface *dsurface,
wl_list_remove(&surface->resource_destroy_listener.link);
weston_desktop_surface_unset_relative_to(surface->surface);
- if (surface->added)
+ if (surface->added) {
weston_desktop_api_surface_removed(surface->desktop,
surface->surface);
- else if (surface->state == XWAYLAND)
+ } else if (surface->state == XWAYLAND) {
weston_desktop_surface_unlink_view(surface->view);
+ weston_view_destroy(surface->view);
+ }
free(surface);
}