Commit 50ad59bb authored by Ilkka Ollakka's avatar Ilkka Ollakka

qt4: little tweaking on PLModel::flags on playlist-locking

parent ed7b4fcd
...@@ -156,16 +156,18 @@ Qt::ItemFlags PLModel::flags( const QModelIndex &index ) const ...@@ -156,16 +156,18 @@ Qt::ItemFlags PLModel::flags( const QModelIndex &index ) const
|| item->p_input == ml_input) || item->p_input == ml_input)
flags |= Qt::ItemIsDropEnabled; flags |= Qt::ItemIsDropEnabled;
} }
else else if( rootItem->p_input == pl_input ||
rootItem->p_input == ml_input )
{ {
PL_LOCK; PL_LOCK;
playlist_item_t *plItem = playlist_item_t *plItem =
playlist_ItemGetById( p_playlist, item->i_id ); playlist_ItemGetById( p_playlist, item->i_id );
if ( plItem && ( plItem->i_children > -1 ) &&
( rootItem->p_input == pl_input || if ( plItem && ( plItem->i_children > -1 ) )
rootItem->p_input == ml_input ) ) flags |= Qt::ItemIsDropEnabled;
flags |= Qt::ItemIsDropEnabled;
PL_UNLOCK; PL_UNLOCK;
flags |= Qt::ItemIsDragEnabled; flags |= Qt::ItemIsDragEnabled;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment