From 8b43adebc047ac432f38296eec2e9b2dd7a5f051 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Fri, 28 Feb 2014 21:47:44 -0600 Subject: When removing disconnect as well --- src/sound-menu.vala | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/sound-menu.vala b/src/sound-menu.vala index 6d36731..701930e 100644 --- a/src/sound-menu.vala +++ b/src/sound-menu.vala @@ -111,7 +111,12 @@ class SoundMenu: Object public void remove_player (MediaPlayer player) { this.remove_player_section (player); - this.notify_handlers.remove (player); + + var id = this.notify_handlers.lookup(player); + if (id != 0) { + player.disconnect(id); + this.notify_handlers.remove (player); + } } Menu root; -- cgit v1.2.3