From cbc47b258bd6782788a8dcff14b9cbdad334ecf8 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Mardelle Date: Tue, 8 Nov 2011 12:02:14 +0100 Subject: [PATCH] Fix updating of monitor timecode, solving offset between timeline and monitor timecode --- src/monitor.cpp | 7 +++++-- src/monitormanager.cpp | 12 ++---------- 2 files changed, 7 insertions(+), 12 deletions(-) diff --git a/src/monitor.cpp b/src/monitor.cpp index 50727b9c..4e017b54 100644 --- a/src/monitor.cpp +++ b/src/monitor.cpp @@ -879,7 +879,10 @@ void Monitor::resetProfile(const QString &profile) { m_timePos->updateTimeCode(m_monitorManager->timecode()); if (render == NULL) return; - render->resetProfile(profile); + if (!render->hasProfile(profile)) { + activateMonitor(); + render->resetProfile(profile); + } if (m_effectWidget) m_effectWidget->resetProfile(render); } @@ -1003,8 +1006,8 @@ void Monitor::slotEffectScene(bool show) emit requestFrameForAnalysis(show); if (show) { m_effectWidget->getScene()->slotZoomFit(); - render->doRefresh(); } + render->doRefresh(); } } diff --git a/src/monitormanager.cpp b/src/monitormanager.cpp index 8d0d2341..1b0a7c6f 100644 --- a/src/monitormanager.cpp +++ b/src/monitormanager.cpp @@ -187,16 +187,8 @@ void MonitorManager::slotResetProfiles() if (m_projectMonitor == NULL || m_clipMonitor == NULL) return; blockSignals(true); QString active = m_activeMonitor ? m_activeMonitor->name() : QString(); - if (!m_clipMonitor->render->hasProfile(KdenliveSettings::current_profile())) { - activateMonitor("clip"); - m_clipMonitor->resetProfile(KdenliveSettings::current_profile()); - m_clipMonitor->updateTimecodeFormat(); - } - if (!m_projectMonitor->render->hasProfile(KdenliveSettings::current_profile())) { - activateMonitor("project"); - m_projectMonitor->resetProfile(KdenliveSettings::current_profile()); - m_projectMonitor->updateTimecodeFormat(); - } + m_clipMonitor->resetProfile(KdenliveSettings::current_profile()); + m_projectMonitor->resetProfile(KdenliveSettings::current_profile()); if (!active.isEmpty()) activateMonitor(active); blockSignals(false); if (m_activeMonitor) m_activeMonitor->parentWidget()->raise(); -- 2.39.2