+void Playtree::onUpdate( int id )
+{
+ Iterator it = findById( id );
+ if( it != end() )
+ {
+ // Update the item
+ playlist_item_t* pNode = (playlist_item_t*)(it->m_pData);
+ UString *pName = new UString( getIntf(), pNode->input.psz_name );
+ it->m_cString = UStringPtr( pName );
+ it->m_playing = m_pPlaylist->status.p_item == pNode;
+ }
+ else
+ {
+ msg_Warn(getIntf(), "Cannot find node with id %d", id );
+ }
+ // TODO update only the right node
+ notify();
+}
+
+void Playtree::buildNode( playlist_item_t *pNode, VarTree &rTree )