From 6d9281372ca07b0c19fd19c50a1c668aeac7f969 Mon Sep 17 00:00:00 2001 From: Till Theato Date: Thu, 28 Oct 2010 21:05:25 +0000 Subject: [PATCH] Fix keyframes in timeline cannot be dragged to beginning of clip. Also fixes painting of keyframes while one keyframe is dragged. svn path=/trunk/kdenlive/; revision=5055 --- src/abstractclipitem.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/abstractclipitem.cpp b/src/abstractclipitem.cpp index c6f879fd..b78aed2e 100644 --- a/src/abstractclipitem.cpp +++ b/src/abstractclipitem.cpp @@ -343,9 +343,9 @@ void AbstractClipItem::updateSelectedKeyFrame() QRectF br = sceneBoundingRect(); double maxw = br.width() / cropDuration().frames(m_fps); double maxh = br.height() / 100.0 * m_keyframeFactor; - update(br.x() + maxw *(m_selectedKeyframe - cropStart().frames(m_fps)) - 3, br.bottom() - m_keyframes[m_selectedKeyframe] * maxh - 3, 12, 12); + update(br.x() + maxw *(m_selectedKeyframe - cropStart().frames(m_fps)) - 3, br.bottom() - m_keyframes.value(m_selectedKeyframe) * maxh - 3, 12, 12); m_selectedKeyframe = m_editedKeyframe; - update(br.x() + maxw *(m_selectedKeyframe - cropStart().frames(m_fps)) - 3, br.bottom() - m_keyframes[m_selectedKeyframe] * maxh - 3, 12, 12); + update(br.x() + maxw *(m_selectedKeyframe - cropStart().frames(m_fps)) - 3, br.bottom() - m_keyframes.value(m_selectedKeyframe) * maxh - 3, 12, 12); } int AbstractClipItem::editedKeyFramePos() const -- 2.39.2