]> git.sesse.net Git - kdenlive/blobdiff - src/projectlist.cpp
Fix proxy clips reloaded twice on project opening:
[kdenlive] / src / projectlist.cpp
index 37b9bdb23ee5e17cedd9eb24ed4317068931d598..03f05f84d7726282c07afe5787b428d950862ab5 100644 (file)
@@ -1074,7 +1074,7 @@ void ProjectList::slotAddClip(DocClipBase *clip, bool getProperties)
 
 void ProjectList::slotGotProxy(const QString &proxyPath)
 {
-    if (proxyPath.isEmpty()) return;
+    if (proxyPath.isEmpty() || !m_refreshed) return;
     QTreeWidgetItemIterator it(m_listView);
     ProjectItem *item;
 
@@ -1090,7 +1090,7 @@ void ProjectList::slotGotProxy(const QString &proxyPath)
 
 void ProjectList::slotGotProxy(ProjectItem *item)
 {
-    if (item == NULL) return;
+    if (item == NULL || !m_refreshed) return;
     DocClipBase *clip = item->referencedClip();
     // Proxy clip successfully created
     QDomElement e = clip->toXML().cloneNode().toElement();
@@ -1558,10 +1558,12 @@ QDomElement ProjectList::producersList()
 
 void ProjectList::slotCheckForEmptyQueue()
 {
-    if (!m_refreshed && m_processingClips.isEmpty() && m_thumbnailQueue.isEmpty() && m_infoQueue.isEmpty()) {
+    if (m_processingClips.isEmpty() && m_thumbnailQueue.isEmpty() && m_infoQueue.isEmpty()) {
+        if (!m_refreshed) {
+            emit loadingIsOver();
+            emit displayMessage(QString(), -1);
+        }
         m_refreshed = true;
-        emit loadingIsOver();
-        emit displayMessage(QString(), -1);
         m_listView->blockSignals(false);
         m_listView->setEnabled(true);
         updateButtons();