Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
{
int i = getParentPosInLayout( event->pos() );
+ /* Workaround: do not let the item move to its current
+ position + 1 as it breaks the widgetList */
+ if ( i - 1 == i_dragIndex )
+ --i;
+
QByteArray data = event->mimeData()->data( "vlc/button-bar" );
QDataStream dataStream(&data, QIODevice::ReadOnly);
}
if( i == -1 ) return true;
+ i_dragIndex = i;
+
doubleInt *dI = widgetList.at( i );
int i_type = dI->i_type;
};
QRubberBand *rubberband;
QList <doubleInt *> widgetList;
+ int i_dragIndex;
int getParentPosInLayout( QPoint point);