diff options
author | emersion <contact@emersion.fr> | 2018-11-27 21:13:08 +0100 |
---|---|---|
committer | emersion <contact@emersion.fr> | 2018-11-27 21:13:08 +0100 |
commit | 1d30b7c0f6068629760e692e594172e9972edf93 (patch) | |
tree | 2eb1edc9d9aefe95848b94ff0a25166023f13323 /sway | |
parent | Handle destroyed subsurfaces (diff) | |
download | sway-1d30b7c0f6068629760e692e594172e9972edf93.tar.gz sway-1d30b7c0f6068629760e692e594172e9972edf93.tar.zst sway-1d30b7c0f6068629760e692e594172e9972edf93.zip |
Damage view child when destroyed
Diffstat (limited to 'sway')
-rw-r--r-- | sway/tree/view.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/sway/tree/view.c b/sway/tree/view.c index c56b96f9..f7af841c 100644 --- a/sway/tree/view.c +++ b/sway/tree/view.c | |||
@@ -713,9 +713,6 @@ static void subsurface_handle_destroy(struct wl_listener *listener, | |||
713 | struct sway_subsurface *subsurface = | 713 | struct sway_subsurface *subsurface = |
714 | wl_container_of(listener, subsurface, destroy); | 714 | wl_container_of(listener, subsurface, destroy); |
715 | struct sway_view_child *child = &subsurface->child; | 715 | struct sway_view_child *child = &subsurface->child; |
716 | if (child->view->container != NULL) { | ||
717 | view_child_damage(child, true); | ||
718 | } | ||
719 | view_child_destroy(child); | 716 | view_child_destroy(child); |
720 | } | 717 | } |
721 | 718 | ||
@@ -812,6 +809,10 @@ void view_child_init(struct sway_view_child *child, | |||
812 | } | 809 | } |
813 | 810 | ||
814 | void view_child_destroy(struct sway_view_child *child) { | 811 | void view_child_destroy(struct sway_view_child *child) { |
812 | if (child->view->container != NULL) { | ||
813 | view_child_damage(child, true); | ||
814 | } | ||
815 | |||
815 | wl_list_remove(&child->surface_commit.link); | 816 | wl_list_remove(&child->surface_commit.link); |
816 | wl_list_remove(&child->surface_destroy.link); | 817 | wl_list_remove(&child->surface_destroy.link); |
817 | 818 | ||