X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=src%2Fmainwindow.h;h=629b1519e01679724a31a0ceafae02de8a802eae;hb=8c70676956d344c5276004dd7e59f55b51207e7f;hp=568fa1042426209e020b0d298ebc45e9d90d495d;hpb=5e4dd00319872931c201fc28b7a6462ab84ad96c;p=kdenlive diff --git a/src/mainwindow.h b/src/mainwindow.h index 568fa104..629b1519 100644 --- a/src/mainwindow.h +++ b/src/mainwindow.h @@ -53,7 +53,9 @@ class Monitor; class RecMonitor; class CustomTrackView; class RenderWidget; +#ifndef NO_JOGSHUTTLE class JogShuttle; +#endif /* NO_JOGSHUTTLE */ class DocClipBase; class Render; @@ -61,8 +63,16 @@ class MainWindow : public KXmlGuiWindow { Q_OBJECT public: - MainWindow(QWidget *parent = 0); - void parseProfiles(); + /** Constructor + * \param MltPath path to MLT environment + * \param Url Url to open + * \param parent Std. widget parent + * + * The constructor inits the main window. If Url is present, it will be opened. + * If Url is not present, and openLastproject is set, last project will be set + * If no file is open after trying this, a default "newfile" will be created. */ + MainWindow(const QString &MltPath = QString(), const KUrl & Url = KUrl(), QWidget *parent = 0); + void parseProfiles(const QString &mltPath = QString()); static EffectsList videoEffects; static EffectsList audioEffects; @@ -72,6 +82,8 @@ protected: virtual bool queryClose(); virtual void customEvent(QEvent * e); virtual void keyPressEvent(QKeyEvent *ke); + /** Override hideEvent to get events when the mainwindow gets hidden */ + virtual void hideEvent(QHideEvent *e); bool eventFilter(QObject *obj, QEvent *ev); /** * This function is called when it is time for the app to save its @@ -132,21 +144,25 @@ private: RenderWidget *m_renderWidget; +#ifndef NO_JOGSHUTTLE JogShuttle *m_jogProcess; +#endif /* NO_JOGSHUTTLE */ KRecentFilesAction *m_fileOpenRecent; KAction *m_projectSearch; KAction *m_projectSearchNext; - QAction *m_buttonAudioThumbs; - QAction *m_buttonVideoThumbs; - QAction *m_buttonShowMarkers; - QAction *m_buttonFitZoom; - QAction *m_buttonSelectTool; - QAction *m_buttonRazorTool; - QAction *m_buttonSnap; + KAction *m_buttonAudioThumbs; + KAction *m_buttonVideoThumbs; + KAction *m_buttonShowMarkers; + KAction *m_buttonFitZoom; + KAction *m_buttonSelectTool; + KAction *m_buttonRazorTool; + KAction *m_buttonSpacerTool; + KAction *m_buttonSnap; QActionGroup *m_toolGroup; - QAction *m_saveAction; + KAction *m_saveAction; + KAction *m_closeAction; QSlider *m_zoomSlider; StatusBarMessageLabel *m_messageLabel; @@ -157,8 +173,10 @@ private: void readOptions(); void saveOptions(); +#ifndef NO_JOGSHUTTLE void activateShuttleDevice(); void slotShuttleAction(int code); +#endif /* NO_JOGSHUTTLE */ void connectDocumentInfo(KdenliveDoc *doc); void findAhead(); void doOpenFile(const KUrl &url, KAutoSaveFile *stale); @@ -169,15 +187,15 @@ public slots: void slotGotProgressInfo(const QString &message, int progress); private slots: - void newFile(); + void newFile(bool showProjectSettings = true); void queryQuit(); void activateDocument(); void connectDocument(TrackView*, KdenliveDoc*); void openFile(); void openLastFile(); - void saveFile(); - void saveFileAs(); - void saveFileAs(const QString &outputFileName); + bool saveFile(); + bool saveFileAs(); + bool saveFileAs(const QString &outputFileName); void slotPreferences(int page = -1, int option = -1); void updateConfiguration(); void slotConnectMonitors(); @@ -211,7 +229,9 @@ private slots: 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 slotActivateEffectStackView(); void slotActivateTransitionView(); @@ -225,6 +245,8 @@ private slots: void findTimeout(); void slotFindNext(); + void slotInsertSpace(); + void slotRemoveSpace(); void slotAddGuide(); void slotEditGuide(); void slotDeleteGuide(); @@ -240,6 +262,16 @@ private slots: void slotAdjustClipMonitor(); void slotAdjustProjectMonitor(); void slotSaveZone(Render *render, QPoint zone); + + void slotSetInPoint(); + void slotSetOutPoint(); + void configureNotifications(); + void slotInsertTrack(int ix = 0); + void slotDeleteTrack(int ix = 0); + void slotChangeTrack(int ix = 0); + void slotGetNewStuff(); + void slotAutoTransition(); + void slotRunWizard(); };