[vlc-commits] playlist: remove useless parameter

Rémi Denis-Courmont git at videolan.org
Sat Nov 19 12:35:45 CET 2016


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Sat Nov 19 12:04:08 2016 +0200| [e5652b3354a6f560bc3f7e2abf92da3b74800ca9] | committer: Rémi Denis-Courmont

playlist: remove useless parameter

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=e5652b3354a6f560bc3f7e2abf92da3b74800ca9
---

 src/playlist/item.c              | 15 ++++++---------
 src/playlist/playlist_internal.h |  3 +--
 src/playlist/tree.c              |  2 +-
 3 files changed, 8 insertions(+), 12 deletions(-)

diff --git a/src/playlist/item.c b/src/playlist/item.c
index ce05f8a..fdb9e7d 100644
--- a/src/playlist/item.c
+++ b/src/playlist/item.c
@@ -37,7 +37,7 @@
 #include "playlist_internal.h"
 
 static void AddItem( playlist_t *p_playlist, playlist_item_t *p_item,
-                     playlist_item_t *p_node, int i_mode, int i_pos );
+                     playlist_item_t *p_node, int i_pos );
 static void GoAndPreparse( playlist_t *p_playlist, int i_mode,
                            playlist_item_t * );
 static void ChangeToNode( playlist_t *p_playlist, playlist_item_t *p_item );
@@ -551,7 +551,7 @@ playlist_item_t * playlist_NodeAddInput( playlist_t *p_playlist,
     playlist_item_t *p_item = playlist_ItemNewFromInput( p_playlist, p_input );
     if( likely(p_item != NULL) )
     {
-        AddItem( p_playlist, p_item, p_parent, i_mode, i_pos );
+        AddItem( p_playlist, p_item, p_parent, i_pos );
         GoAndPreparse( p_playlist, i_mode, p_item );
     }
     return p_item;
@@ -744,18 +744,15 @@ int playlist_TreeMoveMany( playlist_t *p_playlist,
  * \param p_playlist the playlist object
  * \param i_item_id id of the item added
  * \param i_node_id id of the node in which the item was added
- * \param b_signal TRUE if the function must send a signal
  * \return nothing
  */
-void playlist_SendAddNotify( playlist_t *p_playlist, playlist_item_t *item,
-                             bool b_signal )
+void playlist_SendAddNotify( playlist_t *p_playlist, playlist_item_t *item )
 {
     playlist_private_t *p_sys = pl_priv(p_playlist);
     PL_ASSERT_LOCKED;
 
     p_sys->b_reset_currently_playing = true;
-    if( b_signal )
-        vlc_cond_signal( &p_sys->signal );
+    vlc_cond_signal( &p_sys->signal );
 
     var_SetAddress( p_playlist, "playlist-item-append", item );
 }
@@ -816,13 +813,13 @@ static void GoAndPreparse( playlist_t *p_playlist, int i_mode,
 
 /* Add the playlist item to the requested node and fire a notification */
 static void AddItem( playlist_t *p_playlist, playlist_item_t *p_item,
-                     playlist_item_t *p_node, int i_mode, int i_pos )
+                     playlist_item_t *p_node, int i_pos )
 {
     PL_ASSERT_LOCKED;
     ARRAY_APPEND(p_playlist->items, p_item);
 
     playlist_NodeInsert( p_playlist, p_item, p_node, i_pos );
-    playlist_SendAddNotify( p_playlist, p_item, true );
+    playlist_SendAddNotify( p_playlist, p_item );
 }
 
 /* Actually convert an item to a node */
diff --git a/src/playlist/playlist_internal.h b/src/playlist/playlist_internal.h
index 1395466..6aa7209 100644
--- a/src/playlist/playlist_internal.h
+++ b/src/playlist/playlist_internal.h
@@ -118,8 +118,7 @@ int playlist_MLDump( playlist_t *p_playlist );
  * Item management
  **********************************************************************/
 
-void playlist_SendAddNotify( playlist_t *p_playlist, playlist_item_t *item,
-                             bool b_signal );
+void playlist_SendAddNotify( playlist_t *p_playlist, playlist_item_t *item );
 
 int playlist_InsertInputItemTree ( playlist_t *,
         playlist_item_t *, input_item_node_t *, int, bool );
diff --git a/src/playlist/tree.c b/src/playlist/tree.c
index 2d07cfb..4d589c6 100644
--- a/src/playlist/tree.c
+++ b/src/playlist/tree.c
@@ -76,7 +76,7 @@ playlist_item_t * playlist_NodeCreate( playlist_t *p_playlist,
 
     if( p_parent != NULL )
         playlist_NodeInsert( p_playlist, p_item, p_parent, i_pos );
-    playlist_SendAddNotify( p_playlist, p_item, true );
+    playlist_SendAddNotify( p_playlist, p_item );
 
     p_item->i_flags |= i_flags;
 



More information about the vlc-commits mailing list