X-Git-Url: https://cloud.milkyroute.net/gitweb/dolphin.git/blobdiff_plain/bcde430bd532436db31a16f6efff46b32ab38bc1..aeb704851d3b33f88eb601d597c2b0743d4e08df:/src/dolphinmainwindow.h diff --git a/src/dolphinmainwindow.h b/src/dolphinmainwindow.h index 551e28192..62f8ceb6e 100644 --- a/src/dolphinmainwindow.h +++ b/src/dolphinmainwindow.h @@ -12,6 +12,7 @@ #include "config-dolphin.h" #include "dolphintabwidget.h" #include "selectionmode/bottombar.h" +#include #include #include #include @@ -20,6 +21,7 @@ #include "panels/information/informationpanel.h" #endif +#include #include #include #include @@ -116,6 +118,14 @@ public: */ void setViewsToHomeIfMountPathOpen(const QString &mountPath); + /** + * Enables or disables the session autosaving feature. + * + * @param enable If true, saves the session automatically after a fixed + * time interval from the last state change. + */ + void setSessionAutoSaveEnabled(bool enable); + bool isFoldersPanelEnabled() const; bool isInformationPanelEnabled() const; bool isSplitViewEnabledInCurrentTab() const; @@ -334,6 +344,13 @@ private Q_SLOTS: */ void toggleSplitView(); + /** + * Pops out a split view. + * The active view will be popped out, unless the view is not split, + * in which case nothing will happen. + */ + void popoutSplitView(); + /** Dedicated action to open the stash:/ ioslave in split view. */ void toggleSplitStash(); @@ -619,6 +636,11 @@ private Q_SLOTS: */ void slotKeyBindings(); + /** + * Saves the session. + */ + void slotSaveSession(); + private: /** * Sets up the various menus and actions and connects them. @@ -648,7 +670,7 @@ private: * otherwise the text is set to "Join". The icon * is updated to match with the text and the currently active view. */ - void updateSplitAction(); + void updateSplitActions(); /** * Sets the window sides the toolbar may be moved to based on toolbar contents. @@ -714,10 +736,16 @@ private: KToolBarPopupAction *m_backAction; KToolBarPopupAction *m_forwardAction; + KActionMenu *m_splitViewAction; + QAction *m_splitViewMenuAction; QMenu m_searchTools; KFileItemActions m_fileItemActions; + QTimer *m_sessionSaveTimer; + QFutureWatcher *m_sessionSaveWatcher; + bool m_sessionSaveScheduled; + friend class DolphinMainWindowTest; };