From 3ec44cfd1d59b727b06ec550e8503e97d24226fa Mon Sep 17 00:00:00 2001 From: Bilal Elmoussaoui Date: Thu, 31 Mar 2022 14:51:41 +0200 Subject: [PATCH] Components: Unparent on dispose --- src/components/drag_overlay.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/components/drag_overlay.rs b/src/components/drag_overlay.rs index 93098dd1..5eca4546 100644 --- a/src/components/drag_overlay.rs +++ b/src/components/drag_overlay.rs @@ -97,6 +97,10 @@ mod imp { self.revealer.set_child(Some(&self.status)); } + + fn dispose(&self, _obj: &Self::Type) { + self.overlay.unparent(); + } } impl WidgetImpl for DragOverlay {} impl BinImpl for DragOverlay {}