Commit b4d29496 authored by Hugo Beauzée-Luyssen's avatar Hugo Beauzée-Luyssen

TracksView: Initialize GraphicsEffectItem m_tracksView field.

parent 9118145e
......@@ -321,6 +321,8 @@ TracksView::effectDragEnterEvent( QDragEnterEvent *event )
if ( effect != NULL )
{
m_dragEffectItem = new GraphicsEffectItem( effect );
m_dragEffectItem->setHeight( m_dragEffectItem->itemHeight() );
m_dragEffectItem->m_tracksView = this;
}
else
qWarning() << "Can't find effect name" << event->mimeData()->data( "vlmc/effect_name");
......@@ -382,7 +384,6 @@ TracksView::dragMoveEvent( QDragMoveEvent *event )
AbstractGraphicsMediaItem *item = itemList.first();
m_dragEffectItem->setWidth( item->clipHelper()->length() );
m_dragEffectItem->setStartPos( item->startPos() );
m_dragEffectItem->setHeight( m_dragEffectItem->itemHeight() );
m_dragEffectItem->setTrack( getTrack( m_dragEffectItem->trackType(), 0 ) );
m_dragEffectItem->setZValue( 100 );
}
......@@ -396,7 +397,6 @@ TracksView::dragMoveEvent( QDragMoveEvent *event )
{
m_dragEffectItem->setWidth( track->maximumWidth() );
m_dragEffectItem->setStartPos( 0 );
m_dragEffectItem->setHeight( m_dragEffectItem->itemHeight() );
m_dragEffectItem->setTrack( track );
break ;
}
......
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