]> git.sesse.net Git - kdenlive/blobdiff - src/projectlist.h
Fix crash when closing doc / app while proxy are generated
[kdenlive] / src / projectlist.h
index 63c8f7450f4321e1b3a2884c5e8bc8e948b48687..4b4ba236ac3d687a119dbefefe7d8097a231520d 100644 (file)
@@ -31,6 +31,7 @@
 #include <QTimer>
 #include <QApplication>
 #include <QFuture>
+#include <QFutureSynchronizer>
 
 #include <KTreeWidgetSearchLine>
 #include <KUrl>
@@ -52,6 +53,13 @@ namespace Mlt
 class Producer;
 };
 
+struct PROXYINFO {
+    QString dest;
+    QString src;
+    CLIPTYPE type;
+    int exif;
+};
+
 class ProjectItem;
 class ProjectListView;
 class Render;
@@ -274,6 +282,9 @@ private:
     /** @brief Holds a list of proxy urls that are currently being created. */
     QStringList m_processingProxy;
     QMutex m_mutex;
+    bool m_abortAllProxies;
+    QList <PROXYINFO> m_proxyList;
+    QFutureSynchronizer<void> m_proxyThreads;
     
     void requestClipThumbnail(const QString id);
 
@@ -340,7 +351,7 @@ private slots:
     /** @brief Stop creation of this clip's proxy. */
     void slotAbortProxy(const QString id, const QString path);
     /** @brief Start creation of proxy clip. */
-    void slotGenerateProxy(const QString destPath, const QString sourcePath, int clipType, int exif);
+    void slotGenerateProxy();//const QString destPath, const QString sourcePath, int clipType, int exif);
 
 signals:
     void clipSelected(DocClipBase *, QPoint zone = QPoint());