┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src/dolphintabwidget.h
diff options
context:
space:
mode:
authorKai Uwe Broulik <[email protected]>2022-10-02 13:08:54 +0200
committerKai Uwe Broulik <[email protected]>2022-10-06 12:21:15 +0000
commit8402b989957a5b9e44274b17b1cba289fc3544f0 (patch)
treecaa7ea404cd0090759d80e118e357f67df3aa9d0 /src/dolphintabwidget.h
parent57f694453ae43b4cc3c3c8462e1a9afbee71d4eb (diff)
DolphinTabWidget: Allow specifying new tab position in openNewTab
Diffstat (limited to 'src/dolphintabwidget.h')
-rw-r--r--src/dolphintabwidget.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/dolphintabwidget.h b/src/dolphintabwidget.h
index 7905912da..28c51024c 100644
--- a/src/dolphintabwidget.h
+++ b/src/dolphintabwidget.h
@@ -29,6 +29,15 @@ public:
explicit DolphinTabWidget(DolphinNavigatorsWidgetAction *navigatorsWidget, QWidget *parent);
/**
+ * Where a newly opened tab should be placed.
+ */
+ enum class NewTabPosition {
+ FollowSetting, ///< Honor openNewTabAfterLastTab setting
+ AfterCurrent, ///< After the current tab
+ AtEnd, ///< At the end of the tab bar
+ };
+
+ /**
* @return Tab page at the current index (can be 0 if tabs count is smaller than 1)
*/
DolphinTabPage* currentTabPage() const;
@@ -113,7 +122,7 @@ public Q_SLOTS:
* Opens a new tab in the background showing the URL \a primaryUrl and the
* optional URL \a secondaryUrl.
*/
- void openNewTab(const QUrl &primaryUrl, const QUrl &secondaryUrl = QUrl());
+ void openNewTab(const QUrl &primaryUrl, const QUrl &secondaryUrl = QUrl(), NewTabPosition position = NewTabPosition::FollowSetting);
/**
* Opens each directory in \p dirs in a separate tab unless it is already open.