]> git.sesse.net Git - kdenlive/blobdiff - src/customtrackview.h
Cleanup & fix selected effect sometimes not showing selected state
[kdenlive] / src / customtrackview.h
index 64c0ddbb8968a33ee0dbfdfd71497600787aed67..f4175ab3f3d9ba96018652a7751ae63e4090ca96 100644 (file)
@@ -76,7 +76,7 @@ public:
     void slotAddGroupEffect(QDomElement effect, AbstractGroupItem *group);
     void addEffect(int track, GenTime pos, QDomElement effect);
     void deleteEffect(int track, GenTime pos, QDomElement effect);
-    void updateEffect(int track, GenTime pos, QDomElement insertedEffect, int ix, bool triggeredByUser = true);
+    void updateEffect(int track, GenTime pos, QDomElement insertedEffect, int ix, bool refreshEffectStack = false);
     void moveEffect(int track, GenTime pos, int oldPos, int newPos);
     void addTransition(ItemInfo transitionInfo, int endTrack, QDomElement params, bool refresh);
     void deleteTransition(ItemInfo transitionInfo, int endTrack, QDomElement params, bool refresh);
@@ -174,7 +174,7 @@ public:
     *
     * Inserts at the position of timeline cursor and selected track. */
     void insertClipCut(DocClipBase *clip, int in, int out);
-    void clearSelection();
+    void clearSelection(bool emitInfo = true);
     void editItemDuration();
     void buildGuidesMenu(QMenu *goMenu) const;
     /** update the timeline objects when palette changes */
@@ -194,7 +194,7 @@ public slots:
     void slotDeleteEffect(ClipItem *clip, int track, QDomElement effect, bool affectGroup = true);
     void slotChangeEffectState(ClipItem *clip, int track, int effectPos, bool disable);
     void slotChangeEffectPosition(ClipItem *clip, int track, int currentPos, int newPos);
-    void slotUpdateClipEffect(ClipItem *clip, int track, QDomElement oldeffect, QDomElement effect, int ix);
+    void slotUpdateClipEffect(ClipItem *clip, int track, QDomElement oldeffect, QDomElement effect, int ix, bool refreshEffectStack = true);
     void slotUpdateClipRegion(ClipItem *clip, int ix, QString region);
     void slotRefreshEffects(ClipItem *clip);
     void setDuration(int duration);
@@ -262,12 +262,18 @@ public slots:
     * @param effect The new effect xml
     * @param ix The track index */
     void slotAddTrackEffect(const QDomElement &effect, int ix);
+    /** @brief Select all clips in selected track. */
+    void slotSelectClipsInTrack();
+    /** @brief Select all clips in timeline. */
+    void slotSelectAllClips();
 
     /** @brief Update the list of snap points (sticky timeline hotspots).
     * @param selected The currently selected clip if any
     * @param offsetList The list of points that should also snap (for example when movin a clip, start and end points should snap
     * @param skipSelectedItems if true, the selected item start and end points will not be added to snap list */
     void updateSnapPoints(AbstractClipItem *selected, QList <GenTime> offsetList = QList <GenTime> (), bool skipSelectedItems = false);
+    
+    void slotAddEffect(ClipItem *clip, QDomElement effect);
 
 protected:
     virtual void drawBackground(QPainter * painter, const QRectF & rect);
@@ -311,6 +317,7 @@ private:
     ClipItem *getClipItemAt(GenTime pos, int track);
     ClipItem *getClipItemAtEnd(GenTime pos, int track);
     ClipItem *getClipItemAtStart(GenTime pos, int track);
+    Transition *getTransitionItem(TransitionInfo info);
     Transition *getTransitionItemAt(int pos, int track);
     Transition *getTransitionItemAt(GenTime pos, int track);
     Transition *getTransitionItemAtEnd(GenTime pos, int track);
@@ -435,6 +442,9 @@ private:
      * @param fromStart false = resize from end
      * @param command Used as a parent for EditEffectCommand */
     void adjustEffects(ClipItem *item, ItemInfo oldInfo, QUndoCommand *command);
+    
+    /** @brief Prepare an add clip command for an effect */
+    void processEffect(ClipItem *item, QDomElement effect, QUndoCommand *effectCommand);
 
 private slots:
     void slotRefreshGuides();
@@ -451,6 +461,9 @@ private slots:
      *  @param id The clip's Id string.
      *  @param resetThumbs Should we recreate the timeline thumbnails. */
     void slotRefreshThumbs(const QString &id, bool resetThumbs);
+    /** @brief A Filter job producer results. */
+    void slotGotFilterJobResults(const QString &id, int startPos, int track, const QString &filter, stringMap filterParams);
+
 
 signals:
     void cursorMoved(int, int);
@@ -459,15 +472,14 @@ signals:
     void mousePosition(int);
     /** @brief A clip was selected in timeline, update the effect stack
      *  @param clip The clip
-     *  @param ix The index of currently selected effect
      *  @param raise If true, the effect stack widget will be raised (come to front). */
-    void clipItemSelected(ClipItem *clip, int ix = -1, bool raise = true);
+    void clipItemSelected(ClipItem *clip, bool raise = true);
     void transitionItemSelected(Transition*, int track = 0, QPoint p = QPoint(), bool update = false);
     void activateDocumentMonitor();
     void trackHeightChanged();
     void tracksChanged();
     void displayMessage(const QString &, MessageType);
-    void showClipFrame(DocClipBase *, QPoint, const int);
+    void showClipFrame(DocClipBase *, QPoint, bool, const int);
     void doTrackLock(int, bool);
     void updateClipMarkers(DocClipBase *);
     void updateTrackHeaders();