[banshee] [LastfmActions] Unsubscribe from events when disposing (bgo#607347)



commit 452453b3280ee3d88bee7818a7ca9964ca2a6720
Author: Bertrand Lorentz <bertrand lorentz gmail com>
Date:   Mon Jan 18 22:38:08 2010 +0100

    [LastfmActions] Unsubscribe from events when disposing (bgo#607347)

 .../Banshee.Lastfm.Radio/LastfmActions.cs          |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/src/Extensions/Banshee.Lastfm/Banshee.Lastfm.Radio/LastfmActions.cs b/src/Extensions/Banshee.Lastfm/Banshee.Lastfm.Radio/LastfmActions.cs
index b3eae79..e1e8ca1 100644
--- a/src/Extensions/Banshee.Lastfm/Banshee.Lastfm.Radio/LastfmActions.cs
+++ b/src/Extensions/Banshee.Lastfm/Banshee.Lastfm.Radio/LastfmActions.cs
@@ -179,6 +179,9 @@ namespace Banshee.Lastfm.Radio
         {
             Actions.UIManager.RemoveUi (actions_id);
             Actions.RemoveActionGroup (this);
+            lastfm.Connection.StateChanged -= HandleConnectionStateChanged;
+            Actions.SourceActions ["SourcePropertiesAction"].Activated -= OnSourceProperties;
+            ServiceManager.PlaybackController.SourceChanged -= OnPlaybackSourceChanged;
             ServiceManager.PlayerEngine.DisconnectEvent (OnPlayerEvent);
             base.Dispose ();
         }



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]