summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/rekonq.kcfg3
-rw-r--r--src/settings/settings_tabs.ui7
-rw-r--r--src/tabwindow/rekonqwindow.cpp5
3 files changed, 15 insertions, 0 deletions
diff --git a/src/rekonq.kcfg b/src/rekonq.kcfg
index 0e083edf..6303dcde 100644
--- a/src/rekonq.kcfg
+++ b/src/rekonq.kcfg
@@ -119,6 +119,9 @@
<entry name="closeTabSelectPrevious" type="Bool">
<default>false</default>
</entry>
+ <entry name="openNewTabsNextToCurrent" type="Bool">
+ <default>true</default>
+ </entry>
</group>
diff --git a/src/settings/settings_tabs.ui b/src/settings/settings_tabs.ui
index df6db9ba..5b367a8d 100644
--- a/src/settings/settings_tabs.ui
+++ b/src/settings/settings_tabs.ui
@@ -215,6 +215,13 @@
</property>
</widget>
</item>
+ <item>
+ <widget class="QCheckBox" name="kcfg_openNewTabsNextToCurrent">
+ <property name="text">
+ <string>Open new tabs next to current tab</string>
+ </property>
+ </widget>
+ </item>
</layout>
</widget>
</item>
diff --git a/src/tabwindow/rekonqwindow.cpp b/src/tabwindow/rekonqwindow.cpp
index 1717403c..ee37eba9 100644
--- a/src/tabwindow/rekonqwindow.cpp
+++ b/src/tabwindow/rekonqwindow.cpp
@@ -27,6 +27,7 @@
// Self Includes
#include "rekonqwindow.h"
#include "rekonqwindow.moc"
+#include <rekonq.h>
// KDE Includes
#include <KApplication>
@@ -379,6 +380,8 @@ int RekonqWindow::addTab(QWidget *page, const QIcon &icon, const QString &label)
int RekonqWindow::insertTab(int index, QWidget *page, const QString &label)
{
+ if (! ReKonfig::openNewTabsNextToCurrent())
+ index = -1;
setUpdatesEnabled(false);
int i = KTabWidget::insertTab(index, page, label);
setUpdatesEnabled(true);
@@ -389,6 +392,8 @@ int RekonqWindow::insertTab(int index, QWidget *page, const QString &label)
int RekonqWindow::insertTab(int index, QWidget *page, const QIcon &icon, const QString &label)
{
+ if (! ReKonfig::openNewTabsNextToCurrent())
+ index = -1;
setUpdatesEnabled(false);
int i = KTabWidget::insertTab(index, page, icon, label);
setUpdatesEnabled(true);