[vlc-devel] [PATCH] Qt4 Playlist fix: when moving items keep their original order...

Jakob Leben jakob.leben at gmail.com
Fri Jul 31 10:12:22 CEST 2009


2009/7/30 Rémi Denis-Courmont <remi at remlab.net>>

> +                int i;
> +                for( i = 0 ; i< p_parent->i_children ; i++ )
>
> You could move i into the loop, I guess.
>

Nope, because:

int i;
for( i = 0 ; i< p_parent->i_children ; i++ )
    if( p_parent->pp_children[i] == p_target ) break;
playlist_TreeMove( p_playlist, p_src, p_parent, *i *+ 1 ); // !!!


However, there was a ugly bug in the patch that I sent, sorry. Forgot to
include the change of name of an argument to dropMimeData().

Attached is the corrected patch.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20090731/20ff4f2c/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Qt4-playlist-keep-item-order-when-moving.patch
Type: application/octet-stream
Size: 5537 bytes
Desc: not available
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20090731/20ff4f2c/attachment.obj>


More information about the vlc-devel mailing list