[Mplayer-cvslog] CVS: main playtree.c,1.11,1.12 playtree.h,1.3,1.4 mplayer.c,1.442,1.443

Alban Bedel CVS albeu at mplayer.dev.hu
Wed Mar 20 11:27:30 CET 2002


Update of /cvsroot/mplayer/main
In directory mplayer:/var/tmp.root/cvs-serv28638

Modified Files:
	playtree.c playtree.h mplayer.c 
Log Message:
Set the params given to a playlist url to the playlist


Index: playtree.c
===================================================================
RCS file: /cvsroot/mplayer/main/playtree.c,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -r1.11 -r1.12
--- playtree.c	7 Mar 2002 11:57:24 -0000	1.11
+++ playtree.c	20 Mar 2002 10:27:27 -0000	1.12
@@ -382,6 +382,23 @@
   return 1;
 }
 
+void
+play_tree_set_params_from(play_tree_t* dest,play_tree_t* src) {
+  int i;
+
+#ifdef MP_DEBUG
+  assert(dest != NULL);
+  assert(src != NULL);
+#endif
+
+  if(!src->params)
+    return;
+
+  for(i = 0; src->params[i].name != NULL ; i++)
+    play_tree_set_param(dest,src->params[i].name,src->params[i].value);
+
+}
+
 static void 
 play_tree_iter_push_params(play_tree_iter_t* iter) {
   int n;

Index: playtree.h
===================================================================
RCS file: /cvsroot/mplayer/main/playtree.h,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- playtree.h	17 Jan 2002 20:24:28 -0000	1.3
+++ playtree.h	20 Mar 2002 10:27:27 -0000	1.4
@@ -117,6 +117,9 @@
 int
 play_tree_unset_param(play_tree_t* pt, char* name);
 
+// Set all paramter of source in dest
+void
+play_tree_set_params_from(play_tree_t* dest,play_tree_t* src);
 
 /// Iterator
 

Index: mplayer.c
===================================================================
RCS file: /cvsroot/mplayer/main/mplayer.c,v
retrieving revision 1.442
retrieving revision 1.443
diff -u -r1.442 -r1.443
--- mplayer.c	20 Mar 2002 09:48:47 -0000	1.442
+++ mplayer.c	20 Mar 2002 10:27:27 -0000	1.443
@@ -937,6 +937,7 @@
       goto goto_next_file;
     }
     play_tree_insert_entry(playtree_iter->tree,entry);
+    play_tree_set_params_from(entry,playtree_iter->tree);
     entry = playtree_iter->tree;
     if(play_tree_iter_step(playtree_iter,1,0) != PLAY_TREE_ITER_ENTRY) {
       eof = PT_NEXT_ENTRY;




More information about the MPlayer-cvslog mailing list