playlist_CreateNode(): add an argument to specify an input_item_t to be linked with...
[vlc.git] / modules / services_discovery / upnp_intel.cpp
index 2d19418..7e0c247 100644 (file)
@@ -29,7 +29,6 @@
   \TODO: Change names to VLC standard ???
 */
 
-#include <stdlib.h>
 
 #include <vector>
 #include <string>
@@ -39,8 +38,7 @@
 
 #undef PACKAGE_NAME
 #include <vlc/vlc.h>
-#include <vlc/intf.h>
-
+#include <vlc_playlist.h>
 #include "vlc_strings.h"
 
 
@@ -467,11 +465,11 @@ static int Callback( Upnp_EventType eventType, void* event, void* pCookie )
     case UPNP_EVENT_SUBSCRIBE_COMPLETE:
         msg_Warn( cookie->serviceDiscovery, "subscription complete" );
         break;
-        
     case UPNP_DISCOVERY_SEARCH_TIMEOUT:
         msg_Warn( cookie->serviceDiscovery, "search timeout" );
         break;
-        
     default:
     msg_Dbg( cookie->serviceDiscovery, "%s:%d: DEBUG: UNHANDLED EVENT ( TYPE=%d )", __FILE__, __LINE__, eventType );
     break;
@@ -855,7 +853,7 @@ void MediaServer::_buildPlaylist( Container* parent )
         playlist_item_t* parentNode = parent->getPlaylistNode();
 
         char* title = strdup( container->getTitle() );
-        playlist_item_t* node = playlist_NodeCreate( p_playlist, title, parentNode );
+        playlist_item_t* node = playlist_NodeCreate( p_playlist, title, parentNode, 0, NULL );
         free( title );
 
         container->setPlaylistNode( node );
@@ -872,7 +870,8 @@ void MediaServer::_buildPlaylist( Container* parent )
                                                item->getTitle() );
         int i_cat;
         playlist_BothAddInput( p_playlist, p_input, parentNode,
-                               PLAYLIST_APPEND, PLAYLIST_END, &i_cat, NULL );
+                               PLAYLIST_APPEND, PLAYLIST_END, &i_cat, NULL,
+                               VLC_FALSE );
         /* TODO: do this better by storing ids */
         playlist_item_t *p_node = playlist_ItemGetById( p_playlist, i_cat, VLC_FALSE );
         assert( p_node );
@@ -917,7 +916,7 @@ bool MediaServerList::addServer( MediaServer* s )
     char* name = strdup( s->getFriendlyName() );
     playlist_item_t* node = playlist_NodeCreate( pl_Get( _cookie->serviceDiscovery ),
                                                  name,
-                                          _cookie->serviceDiscovery->p_sys->p_node_cat );
+                                          _cookie->serviceDiscovery->p_sys->p_node_cat, 0, NULL );
     free( name );
     s->setPlaylistNode( node );