]> git.sesse.net Git - kdenlive/commitdiff
Fix crash when resizing clip that is playing:
authorJean-Baptiste Mardelle <jb@kdenlive.org>
Thu, 26 Feb 2009 22:17:05 +0000 (22:17 +0000)
committerJean-Baptiste Mardelle <jb@kdenlive.org>
Thu, 26 Feb 2009 22:17:05 +0000 (22:17 +0000)
http://www.kdenlive.org:80/mantis/view.php?id=692

svn path=/branches/KDE4/; revision=3078

src/customtrackview.cpp

index c2779a70760cc5bf40a0e31e0642ea55ca401842..00cf0ac2d04b45d2cee9a33641f9858849f33ab1 100644 (file)
@@ -270,9 +270,11 @@ void CustomTrackView::mouseMoveEvent(QMouseEvent * event) {
 
             } else if (m_operationMode == RESIZESTART && move) {
                 double snappedPos = getSnapPointForPos(mappedXPos);
+                m_document->renderer()->pause();
                 m_dragItem->resizeStart((int)(snappedPos));
             } else if (m_operationMode == RESIZEEND && move) {
                 double snappedPos = getSnapPointForPos(mappedXPos);
+                m_document->renderer()->pause();
                 m_dragItem->resizeEnd((int)(snappedPos));
             } else if (m_operationMode == FADEIN && move) {
                 ((ClipItem*) m_dragItem)->setFadeIn((int)(mappedXPos - m_dragItem->startPos().frames(m_document->fps())));
@@ -656,6 +658,7 @@ void CustomTrackView::mousePressEvent(QMouseEvent * event) {
         }
         AbstractClipItem *clip = static_cast <AbstractClipItem *>(m_dragItem);
         RazorClipCommand* command = new RazorClipCommand(this, clip->info(), GenTime((int)(mapToScene(event->pos()).x()), m_document->fps()), true);
+        m_document->renderer()->pause();
         m_commandStack->push(command);
         m_document->setModified(true);
         m_dragItem = NULL;