[totem] browser-plugin: Queue SetPlaylist calls



commit f5e5ce98597b9544d3d835a36af099abfd6a7295
Author: Bastien Nocera <hadess hadess net>
Date:   Sun Dec 4 16:25:03 2011 +0100

    browser-plugin: Queue SetPlaylist calls

 browser-plugin/totemPlugin.cpp |   11 +++++++++++
 browser-plugin/totemPlugin.h   |    3 ++-
 2 files changed, 13 insertions(+), 1 deletions(-)
---
diff --git a/browser-plugin/totemPlugin.cpp b/browser-plugin/totemPlugin.cpp
index d87243a..780a228 100644
--- a/browser-plugin/totemPlugin.cpp
+++ b/browser-plugin/totemPlugin.cpp
@@ -775,6 +775,17 @@ totemPlugin::ViewerReady ()
 		case TOTEM_QUEUE_TYPE_CLEAR_PLAYLIST:
 			ClearPlaylist();
 			break;
+		case TOTEM_QUEUE_TYPE_SET_PLAYLIST:
+			assert (mViewerProxy);
+
+			D ("SetPlaylist '%s'", cmd->add_item.uri);
+			totem_dbus_proxy_call_no_reply (mViewerProxy,
+							"SetPlaylist",
+							g_variant_new ("(sss)",
+								       "",
+								       cmd->add_item.uri,
+								       ""));
+			break;
 		case TOTEM_QUEUE_TYPE_ADD_ITEM:
 			assert (mViewerProxy);
 
diff --git a/browser-plugin/totemPlugin.h b/browser-plugin/totemPlugin.h
index 73ccac7..485d1f6 100644
--- a/browser-plugin/totemPlugin.h
+++ b/browser-plugin/totemPlugin.h
@@ -51,7 +51,8 @@ typedef enum {
 	TOTEM_QUEUE_TYPE_CLEAR_PLAYLIST,
 	TOTEM_QUEUE_TYPE_ADD_ITEM,
 	TOTEM_QUEUE_TYPE_SET_BOOLEAN,
-	TOTEM_QUEUE_TYPE_SET_STRING
+	TOTEM_QUEUE_TYPE_SET_STRING,
+	TOTEM_QUEUE_TYPE_SET_PLAYLIST
 } TotemQueueCommandType;
 
 typedef struct {



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