]> git.sesse.net Git - kdenlive/blobdiff - src/monitormanager.cpp
Looks like I finally got the profile switching work!
[kdenlive] / src / monitormanager.cpp
index 3cad95b4e229bac35a37859efef29934323e2a6f..1765fa86cc4567ef0be401c32891741332050bf4 100644 (file)
@@ -59,13 +59,28 @@ void MonitorManager::activateMonitor(QString name) {
     m_activeMonitor = name;
 }
 
+void MonitorManager::switchMonitors() {
+    if (m_activeMonitor == "clip") {
+        m_clipMonitor->stop();
+        m_projectMonitor->start();
+        m_projectMonitor->raise();
+        m_activeMonitor = m_projectMonitor->name();
+        emit raiseClipMonitor(false);
+    } else {
+        m_projectMonitor->stop();
+        m_clipMonitor->start();
+        m_activeMonitor = m_clipMonitor->name();
+        emit raiseClipMonitor(true);
+    }
+}
+
 void MonitorManager::slotPlay() {
     if (m_activeMonitor == "clip") m_clipMonitor->slotPlay();
     else m_projectMonitor->slotPlay();
 }
 
 void MonitorManager::resetProfiles(QString prof) {
-    //m_clipMonitor->resetProfile(prof);
+    m_clipMonitor->resetProfile(prof);
     m_projectMonitor->resetProfile(prof);
 }