From 4e498903df24e86b3f737533b36b3291d6763b3d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?K=C3=A9vin=20Commaille?= Date: Thu, 9 Nov 2023 14:45:25 +0100 Subject: [PATCH] video-player: Flush message bus on dispose Otherwise we might leak the GstPlay --- src/components/video_player.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/components/video_player.rs b/src/components/video_player.rs index 7e4f8431..2a52656f 100644 --- a/src/components/video_player.rs +++ b/src/components/video_player.rs @@ -105,6 +105,10 @@ mod imp { .unwrap(); self.bus_guard.set(bus_guard).unwrap(); } + + fn dispose(&self) { + self.player.message_bus().set_flushing(true); + } } impl WidgetImpl for VideoPlayer {}