[Player-cvs] common/gtk hxbin.cpp,1.9,1.10

[Player-cvs] common/gtk hxbin.cpp,1.9,1.10

nhart at helixcommunity.org nhart at helixcommunity.org
Thu Jul 22 16:59:41 PDT 2004


Update of /cvsroot/player/common/gtk
In directory cvs-new:/tmp/cvs-serv7956

Modified Files:
	hxbin.cpp 
Log Message:
play the first file in a drag & drop


Index: hxbin.cpp
===================================================================
RCS file: /cvsroot/player/common/gtk/hxbin.cpp,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -d -r1.9 -r1.10
--- hxbin.cpp	9 Jul 2004 18:24:08 -0000	1.9
+++ hxbin.cpp	22 Jul 2004 23:59:39 -0000	1.10
@@ -384,8 +384,17 @@
 
     /* XXXRGG: we need to parse this into a playlist if
        multiple files are being dropped */
-    hx_player_open_url(HX_PLAYER(player), (gchar*)selection_data->data);
+    gchar** pURLs = g_strsplit((gchar*)selection_data->data, "\r\n", 0xffff);
+    if (pURLs)
+    {
+	// XXXNH: for now just use the first URL, later we'll turn them into
+	// a playlist
+	hx_player_open_url(HX_PLAYER(player), pURLs[0]);
     hx_player_play(HX_PLAYER(player));
+
+	// cleanup
+	g_strfreev(pURLs);
+    }
 }
 
 void




More information about the Player-cvs mailing list
 

Site Map   |   Terms of Use   |   Privacy Policy   |   Contact Us

Copyright © 1995-2007 RealNetworks, Inc. All rights reserved. RealNetworks and Helix are trademarks of RealNetworks.
All other trademarks or registered trademarks are the property of their respective holders.