]> git.sesse.net Git - kdenlive/blobdiff - src/kdenlivedoc.h
load & save guides
[kdenlive] / src / kdenlivedoc.h
index a3de7ba12df60ce699a14f46e922546953dee9df..463e4cda78af699bdd5c0642ee2d995d2bde7446 100644 (file)
 class Render;
 class ClipManager;
 class DocClipBase;
+class MainWindow;
 
 class KdenliveDoc: public QObject {
 Q_OBJECT public:
 
-    KdenliveDoc(const KUrl &url, const KUrl &projectFolder, MltVideoProfile profile, QUndoGroup *undoGroup, QWidget *parent = 0);
+    KdenliveDoc(const KUrl &url, const KUrl &projectFolder, MltVideoProfile profile, QUndoGroup *undoGroup, MainWindow *parent = 0);
     ~KdenliveDoc();
     QDomNodeList producersList();
     double fps() const;
@@ -77,13 +78,13 @@ Q_OBJECT public:
     void deleteProjectClip(QList <int> ids);
     void deleteProjectFolder(QMap <QString, int> map);
     /** Inform application of the audio thumbnails generation progress */
-    void setThumbsProgress(KUrl url, int progress);
+    void setThumbsProgress(const QString &message, int progress);
     QString profilePath() const;
     QString description() const;
     /** Returns the document format: PAL or NTSC */
     QString getDocumentStandard();
     void setUrl(KUrl url);
-    QDomElement documentInfoXml();
+    QDomElement documentInfoXml(QDomElement timelineInfo);
     void setProfilePath(QString path);
     /** Set to true if document needs saving, false otherwise */
     void setModified(bool mod);
@@ -92,12 +93,15 @@ Q_OBJECT public:
     bool isModified() const;
     /** Returns project folder, used to store project files (titles, effects,...) */
     KUrl projectFolder() const;
-
+    /** Used to inform main app of the current document loading progress */
+    void loadingProgressed();
 private:
     KUrl m_url;
     QDomDocument m_document;
     QString m_projectName;
     double m_fps;
+    /** Cursor position at document opening */
+    int m_startPos;
     int m_width;
     int m_height;
     Timecode m_timecode;
@@ -111,6 +115,9 @@ private:
     bool m_modified;
     /** Project folder, used to store project files (titles, effects,...) */
     KUrl m_projectFolder;
+    double m_documentLoadingStep;
+    double m_documentLoadingProgress;
+    void convertDocument(double version);
 
 public slots:
     void slotCreateTextClip(QString group, int groupId);
@@ -121,7 +128,7 @@ signals:
     void signalDeleteProjectClip(int);
     void updateClipDisplay(int);
     void deletTimelineClip(int);
-    void thumbsProgress(KUrl, int);
+    void progressInfo(const QString &, int);
     /** emited when the document state has been modified (= needs saving or not) */
     void docModified(bool);
     void refreshClipThumbnail(int);