]> git.sesse.net Git - kdenlive/blobdiff - src/mainwindow.h
Notes widget: context menu now allows to insert clickable timecode to make easy refer...
[kdenlive] / src / mainwindow.h
index 723ca769c73c15ac172e212d8403ba82e1c995d1..778b8777e5da907e660b043daac4efff169488d1 100644 (file)
 #include <KRecentFilesAction>
 #include <KComboBox>
 #include <kautosavefile.h>
+#include <KActionCategory>
 
 #include "effectslist.h"
 #include "gentime.h"
 #include "definitions.h"
 #include "statusbarmessagelabel.h"
 #include "dvdwizard.h"
+#include "stopmotion/stopmotion.h"
+#include "noteswidget.h"
 
 class KdenliveDoc;
 class TrackView;
@@ -57,6 +60,7 @@ class CustomTrackView;
 class RenderWidget;
 #ifndef NO_JOGSHUTTLE
 class JogShuttle;
+class JogShuttleAction;
 #endif /* NO_JOGSHUTTLE */
 class DocClipBase;
 class Render;
@@ -67,6 +71,9 @@ class Waveform;
 class RGBParade;
 class KActionCollection;
 class AudioSignal;
+class AbstractAudioScopeWidget;
+class AudioSpectrum;
+class Spectrogram;
 
 class MainWindow : public KXmlGuiWindow
 {
@@ -143,7 +150,7 @@ private:
     //KListWidget *m_effectList;
 
     QDockWidget *m_notesDock;
-    KTextEdit *m_notesWidget;
+    NotesWidget *m_notesWidget;
 
     QDockWidget *m_effectStackDock;
     EffectStackView *m_effectStack;
@@ -175,6 +182,12 @@ private:
     QDockWidget *m_audiosignalDock;
     AudioSignal *m_audiosignal;
 
+    QDockWidget *m_audioSpectrumDock;
+    AudioSpectrum *m_audioSpectrum;
+
+    QDockWidget *m_spectrogramDock;
+    Spectrogram *m_spectrogram;
+
     QDockWidget *m_undoViewDock;
     QUndoView *m_undoView;
     QUndoGroup *m_commandStack;
@@ -182,17 +195,24 @@ private:
     KComboBox *m_timecodeFormat;
 
     /** This list holds all the scopes used in Kdenlive, allowing to manage some global settings */
-    QList <QDockWidget *> m_scopesList;
+    QList <QDockWidget *> m_gfxScopesList;
+    QList <AbstractAudioScopeWidget *> m_audioScopesList;
 
-    QMenu *m_videoEffectsMenu;
-    QMenu *m_audioEffectsMenu;
-    QMenu *m_customEffectsMenu;
+    KActionCategory *m_effectActions;
+    QMenu *m_effectsMenu;
     QMenu *m_transitionsMenu;
     QMenu *m_timelineContextMenu;
     QMenu *m_timelineContextClipMenu;
     QMenu *m_timelineContextTransitionMenu;
     KUrl m_startUrl;
 
+    /** Actions used in the stopmotion widget */
+    KActionCategory *m_stopmotion_actions;
+    
+    /** Action names that can be used in the slotDoAction() slot, with their i18n() names */
+    QStringList m_action_names;
+
+
     /** @brief Shortcut to remove the focus from any element.
      *
      * It allows to get out of e.g. text input fields and to press another
@@ -203,6 +223,7 @@ private:
 
 #ifndef NO_JOGSHUTTLE
     JogShuttle *m_jogProcess;
+    JogShuttleAction* m_jogShuttle;
 #endif /* NO_JOGSHUTTLE */
 
     KRecentFilesAction *m_fileOpenRecent;
@@ -234,6 +255,7 @@ private:
     KAction *m_loopZone;
     KAction *m_playZone;
     KAction *m_loopClip;
+    KSelectAction *m_loadLayout;
     StatusBarMessageLabel *m_messageLabel;
     QActionGroup *m_clipTypeGroup;
     KActionCollection *m_effectsActionCollection;
@@ -246,7 +268,6 @@ private:
     void saveOptions();
 #ifndef NO_JOGSHUTTLE
     void activateShuttleDevice();
-    void slotShuttleAction(int code);
 #endif /* NO_JOGSHUTTLE */
     void connectDocumentInfo(KdenliveDoc *doc);
     void findAhead();
@@ -281,6 +302,8 @@ private:
     /** @brief Populates the "load layout" menu. */
     void loadLayouts();
 
+    StopmotionWidget *m_stopmotion;
+
 public slots:
     /** @brief Prepares opening @param url.
     *
@@ -294,7 +317,6 @@ public slots:
 
 private slots:
     void newFile(bool showProjectSettings = true, bool force = false);
-    void queryQuit();
     void activateDocument();
     void connectDocument(TrackView*, KdenliveDoc*);
 
@@ -369,6 +391,13 @@ private slots:
     void slotDeleteClipMarker();
     void slotDeleteAllClipMarkers();
     void slotEditClipMarker();
+
+    /** @brief Adds marker or auide at the current position without showing the marker dialog.
+     *
+     * Adds a marker if clip monitor is active, otherwise a guide.
+     * The comment is set to the current position (therefore not dialog).
+     * This can be useful to mark something during playback. */
+    void slotAddMarkerGuideQuickly();
     void slotCutTimelineClip();
     void slotInsertClipOverwrite();
     void slotSelectTimelineClip();
@@ -378,16 +407,11 @@ private slots:
     void slotSelectAddTimelineClip();
     void slotSelectAddTimelineTransition();
     void slotAddVideoEffect(QAction *result);
-    void slotAddAudioEffect(QAction *result);
-    void slotAddCustomEffect(QAction *result);
     void slotAddTransition(QAction *result);
     void slotAddProjectClip(KUrl url);
-#ifndef NO_JOGSHUTTLE
-    void slotShuttleButton(int code);
-#endif /* NO_JOGSHUTTLE */
     void slotShowClipProperties(DocClipBase *clip);
     void slotShowClipProperties(QList <DocClipBase *>cliplist, QMap<QString, QString> commonproperties);
-    void slotActivateEffectStackView();
+    void slotActivateEffectStackView(ClipItem* item = NULL, int ix = -1, bool raise = true);
     void slotActivateTransitionView(Transition *);
     void slotChangeTool(QAction * action);
     void slotChangeEdit(QAction * action);
@@ -438,7 +462,6 @@ private slots:
     /** @brief Lets the sampleplugin create a generator.  */
     void generateClip();
     void slotZoneMoved(int start, int end);
-    void slotUpdatePreviewSettings();
     void slotDvdWizard(const QString &url = QString(), const QString &profile = "dv_pal");
     void slotGroupClips();
     void slotUnGroupClips();
@@ -482,6 +505,12 @@ private slots:
     /** @brief Update the capture folder if user asked a change. */
     void slotUpdateCaptureFolder();
 
+    /** @brief Apply new properties to a clip */
+    void slotApplyNewClipProperties(const QString id, QMap <QString, QString> props, QMap <QString, QString> newprops, bool refresh, bool reload);
+
+    /** @brief Delete a clip from current project */
+    void slotDeleteClip(const QString &id);
+
     /** @brief Saves the widgets layout */
     void slotSaveLayout(QAction*);
     void slotLoadLayout(QAction*);
@@ -489,12 +518,23 @@ private slots:
     /** @brief The monitor informs that it needs (or not) to have frames sent by the renderer. */
     void slotMonitorRequestRenderFrame(bool request);
     /** @brief Check if someone needs the render frame sent. */
-    void slotUpdateScopeFrameRequest();
+    void slotUpdateGfxScopeFrameRequest();
     /** @brief Check if someone needs the render frame sent. */
-    void slotDoUpdateScopeFrameRequest();
+    void slotDoUpdateGfxScopeFrameRequest();
+    void slotUpdateAudioScopeFrameRequest();
+    void slotDoUpdateAudioScopeFrameRequest();
     /** @brief When switching between monitors, update the visible scopes. */
     void slotUpdateColorScopes();
-
+    /** @brief Switch current monitor to fullscreen. */
+    void slotSwitchFullscreen();
+    /** @brief Open the stopmotion dialog. */
+    void slotOpenStopmotion();
+    /** @brief Implements all the actions that are int he ActionsCollection. */
+    void slotDoAction(const QString& action_name);
+    /** @brief Update project because the use of proxy clips was enabled / disabled. */
+    void slotUpdateProxySettings();
+    /** @brief Insert current project's timecode into the notes widget. */
+    void slotInsertNotesTimecode();
 signals:
     Q_SCRIPTABLE void abortRenderJob(const QString &url);
 };