[banshee/gst#] [gst#] Fix switching songs



commit 5e716aacae624d0a78c4e34cfff730d07eaccd41
Author: Gabriel Burt <gabriel burt gmail com>
Date:   Sat Mar 13 14:47:09 2010 -0800

    [gst#] Fix switching songs

 .../Banshee.GStreamerSharp/PlayerEngine.cs         |    3 +++
 src/Backends/Banshee.GStreamerSharp/Makefile.am    |    2 ++
 2 files changed, 5 insertions(+), 0 deletions(-)
---
diff --git a/src/Backends/Banshee.GStreamerSharp/Banshee.GStreamerSharp/PlayerEngine.cs b/src/Backends/Banshee.GStreamerSharp/Banshee.GStreamerSharp/PlayerEngine.cs
index 5c913d6..66a7050 100644
--- a/src/Backends/Banshee.GStreamerSharp/Banshee.GStreamerSharp/PlayerEngine.cs
+++ b/src/Backends/Banshee.GStreamerSharp/Banshee.GStreamerSharp/PlayerEngine.cs
@@ -74,6 +74,9 @@ namespace Banshee.GStreamerSharp
         protected override void OpenUri (SafeUri uri)
         {
             Console.WriteLine ("Gst# PlayerEngine OpenUri: {0}", uri);
+            if (pipeline.CurrentState == State.Playing) {
+                pipeline.SetState (Gst.State.Null);
+            }
             playbin.Uri = uri.AbsoluteUri;
         }
 
diff --git a/src/Backends/Banshee.GStreamerSharp/Makefile.am b/src/Backends/Banshee.GStreamerSharp/Makefile.am
index 358ea1b..650f8eb 100644
--- a/src/Backends/Banshee.GStreamerSharp/Makefile.am
+++ b/src/Backends/Banshee.GStreamerSharp/Makefile.am
@@ -7,6 +7,8 @@ SOURCES =  \
 RESOURCES = Banshee.GStreamerSharp.addin.xml
 INSTALL_DIR = $(BACKENDS_INSTALL_DIR)
 
+BUILD_DEFINES="-define:HAVE_GST_SHARP"
+
 include $(top_srcdir)/build/build.mk
 
 if ENABLE_GAPLESS



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