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

TracksView: Fixing bad mouse releasing behaviour.

parent 5b0a8057
...@@ -1137,16 +1137,16 @@ TracksView::mouseReleaseEvent( QMouseEvent *event ) ...@@ -1137,16 +1137,16 @@ TracksView::mouseReleaseEvent( QMouseEvent *event )
{ {
const AbstractGraphicsMediaItem *container = effectItem->container(); const AbstractGraphicsMediaItem *container = effectItem->container();
if ( container != NULL && container->startPos() + effectItem->begin() == effectItem->startPos() ) if ( container != NULL && container->startPos() + effectItem->begin() == effectItem->startPos() )
return ; goto out;
else if ( container == NULL && effectItem->startPos() == effectItem->begin() ) else if ( container == NULL && effectItem->startPos() == effectItem->begin() )
return ; goto out;
} }
} }
else else
{ {
if ( m_actionItem->m_oldTrack == m_actionItem->track()->trackWorkflow() && if ( m_actionItem->m_oldTrack == m_actionItem->track()->trackWorkflow() &&
m_actionItem->startPos() == m_actionItem->track()->trackWorkflow()->getClipPosition( m_actionItem->uuid() ) ) m_actionItem->startPos() == m_actionItem->track()->trackWorkflow()->getClipPosition( m_actionItem->uuid() ) )
return ; goto out;
} }
updateDuration(); updateDuration();
...@@ -1213,6 +1213,7 @@ TracksView::mouseReleaseEvent( QMouseEvent *event ) ...@@ -1213,6 +1213,7 @@ TracksView::mouseReleaseEvent( QMouseEvent *event )
m_actionItem = NULL; m_actionItem = NULL;
} }
out:
m_action = TracksView::None; m_action = TracksView::None;
//setDragMode( QGraphicsView::NoDrag ); //setDragMode( QGraphicsView::NoDrag );
QGraphicsView::mouseReleaseEvent( event ); QGraphicsView::mouseReleaseEvent( event );
......
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