aboutsummaryrefslogtreecommitdiff
path: root/src/widgets/webviewtabbar.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/widgets/webviewtabbar.cpp')
-rw-r--r--src/widgets/webviewtabbar.cpp15
1 files changed, 7 insertions, 8 deletions
diff --git a/src/widgets/webviewtabbar.cpp b/src/widgets/webviewtabbar.cpp
index db44bc9..745a7a5 100644
--- a/src/widgets/webviewtabbar.cpp
+++ b/src/widgets/webviewtabbar.cpp
@@ -19,7 +19,7 @@
******************************************************************************/
#include "webviewtabbar.h"
-#include "settings.h"
+#include "browser.h"
#include <QAction>
WebViewTabBar::WebViewTabBar(QWidget *parent) :
@@ -32,26 +32,25 @@ WebViewTabBar::WebViewTabBar(QWidget *parent) :
connect(this, SIGNAL(currentChanged(int)), this, SLOT(handleCurrentChanged(int)));
connect(this, SIGNAL(tabMoved(int,int)), this, SLOT(updateVectorArrangement(int,int)));
- Settings settings;
- if(settings.contains("shortcuts/tabClose")) {
+ if(sSettings->contains("shortcuts.tabClose")) {
QAction *tabCloseAction = new QAction(this);
- tabCloseAction->setShortcut(QKeySequence::fromString(settings.value("shortcuts/tabClose").toString()));
+ tabCloseAction->setShortcut(QKeySequence::fromString(sSettings->value("shortcuts.tabClose").toString()));
connect(tabCloseAction, &QAction::triggered, [this]() {
this->handleTabClose(currentIndex());
});
addAction(tabCloseAction);
}
- if(settings.contains("shortcuts/tabLeft")) {
+ if(sSettings->contains("shortcuts.tabLeft")) {
QAction *tabLeftAction = new QAction(this);
- tabLeftAction->setShortcut(QKeySequence::fromString(settings.value("shortcuts/tabLeft").toString()));
+ tabLeftAction->setShortcut(QKeySequence::fromString(sSettings->value("shortcuts.tabLeft").toString()));
connect(tabLeftAction, &QAction::triggered, [this]() {
this->setCurrentIndex(currentIndex()-1);
});
addAction(tabLeftAction);
}
- if(settings.contains("shortcuts/tabRight")) {
+ if(sSettings->contains("shortcuts.tabRight")) {
QAction *tabRightAction = new QAction(this);
- tabRightAction->setShortcut(QKeySequence::fromString(settings.value("shortcuts/tabRight").toString()));
+ tabRightAction->setShortcut(QKeySequence::fromString(sSettings->value("shortcuts.tabRight").toString()));
connect(tabRightAction, &QAction::triggered, [this]() {
this->setCurrentIndex(currentIndex()+1);
});