[banshee] Muinshee: Make double-click on an album do the same as the Play button



commit 4ab87cec6e8e5ea6e3cfbaa3ed26afc5b6d91922
Author: Adam Lofts <Adam Lofts gmail com>
Date:   Tue Oct 18 14:23:42 2011 +0100

    Muinshee: Make double-click on an album do the same as the Play button
    
    Fixes bgo#619857.
    
    Signed-off-by: Bertrand Lorentz <bertrand lorentz gmail com>

 src/Clients/Muinshee/Muinshee/AlbumDialog.cs |    9 ++++++++-
 src/Clients/Muinshee/Muinshee/BaseDialog.cs  |    2 +-
 2 files changed, 9 insertions(+), 2 deletions(-)
---
diff --git a/src/Clients/Muinshee/Muinshee/AlbumDialog.cs b/src/Clients/Muinshee/Muinshee/AlbumDialog.cs
index c1b644b..b29ea75 100644
--- a/src/Clients/Muinshee/Muinshee/AlbumDialog.cs
+++ b/src/Clients/Muinshee/Muinshee/AlbumDialog.cs
@@ -80,8 +80,10 @@ namespace Muinshee
 
         protected override Widget GetItemWidget ()
         {
-            AlbumListView album_view = new AlbumListView ();
+            AlbumListView album_view = new MuinsheeAlbumView ();
             album_view.SetModel (album_model);
+
+            album_view.RowActivated += OnRowActivated;
             return album_view;
         }
 
@@ -100,5 +102,10 @@ namespace Muinshee
             base.Destroy ();
         }
 
+        protected void OnRowActivated (object o, EventArgs args)
+        {
+            Play ();
+            Destroy ();
+        }
     }
 }
diff --git a/src/Clients/Muinshee/Muinshee/BaseDialog.cs b/src/Clients/Muinshee/Muinshee/BaseDialog.cs
index e48e7c0..d879b77 100644
--- a/src/Clients/Muinshee/Muinshee/BaseDialog.cs
+++ b/src/Clients/Muinshee/Muinshee/BaseDialog.cs
@@ -110,7 +110,7 @@ namespace Muinshee
             Music.FilterQuery = search_entry.Query;
         }
 
-        private void Play ()
+        protected void Play ()
         {
             TrackInfo to_play = FirstTrack;
             Hyena.Log.InformationFormat  ("first to play is {0}", to_play);



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