# HG changeset patch # User albeu # Date 1016620047 0 # Node ID 3e7152b383cab2ca15b725fa6a1abc75b33222a4 # Parent 228971e444eae52619d463111e6d1dd3358fa1b5 Set the params given to a playlist url to the playlist diff -r 228971e444ea -r 3e7152b383ca mplayer.c --- a/mplayer.c Wed Mar 20 09:48:47 2002 +0000 +++ b/mplayer.c Wed Mar 20 10:27:27 2002 +0000 @@ -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; diff -r 228971e444ea -r 3e7152b383ca playtree.c --- a/playtree.c Wed Mar 20 09:48:47 2002 +0000 +++ b/playtree.c Wed Mar 20 10:27:27 2002 +0000 @@ -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; diff -r 228971e444ea -r 3e7152b383ca playtree.h --- a/playtree.h Wed Mar 20 09:48:47 2002 +0000 +++ b/playtree.h Wed Mar 20 10:27:27 2002 +0000 @@ -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