- ARRAY_INSERT( p_mlist->items, p_md, index);
- notify_item_addition( p_mlist, p_md, index );
+/* LibVLC internal version */
+void _libvlc_media_list_insert_media(
+ libvlc_media_list_t * p_mlist,
+ libvlc_media_t * p_md,
+ int index,
+ libvlc_exception_t * p_e )
+{
+ VLC_UNUSED(p_e);
+ libvlc_media_retain( p_md );
+
+ notify_item_addition( p_mlist, p_md, index, EventWillHappen );
+ vlc_array_insert( &p_mlist->items, p_md, index );
+ notify_item_addition( p_mlist, p_md, index, EventDidHappen );