aboutsummaryrefslogtreecommitdiff
path: root/src/mainwindow
diff options
context:
space:
mode:
Diffstat (limited to 'src/mainwindow')
-rw-r--r--src/mainwindow/mainwindow.cpp14
1 files changed, 1 insertions, 13 deletions
diff --git a/src/mainwindow/mainwindow.cpp b/src/mainwindow/mainwindow.cpp
index e280fee..6dc7635 100644
--- a/src/mainwindow/mainwindow.cpp
+++ b/src/mainwindow/mainwindow.cpp
@@ -17,14 +17,13 @@
#include <downloads/downloadswidget.h>
#include "addressbar/urllineedit.h"
#include <bookmarks/bookmarksview.h>
-//#include <settings/settingsdialog.h>
MainWindow::MainWindow(std::shared_ptr<Configuration> config, QWidget *parent)
: QMainWindow(parent)
, ui(new Ui::MainWindow)
, tabBar(new MainWindowTabBar(config, this))
, menuBar(new MainWindowMenuBar(config, this))
- , m_addressBar(new UrlLineEdit(this))
+ , m_addressBar(new UrlLineEdit(config->section("addressbar"), this))
, m_progressBar(new LoadingBar(this))
{
Q_ASSERT(config);
@@ -84,17 +83,6 @@ MainWindow::MainWindow(std::shared_ptr<Configuration> config, QWidget *parent)
ui->statusBar->addWidget(m_searchBox);
m_searchBox->setVisible(false);
- // shortcuts
- QAction *focusAddressAction = new QAction(this);
- focusAddressAction->setShortcut(QKeySequence(QString::fromStdString(m_config->value<std::string>("browser.shortcuts.focusAddress").value())));
- //focusAddressAction->setShortcut(QKeySequence::fromString(browser->settings()->value("window.shortcuts.focusAddress").toString()));
- //connect(focusAddressAction, SIGNAL(triggered(bool)), this, SLOT(focusAddress()));
- connect(focusAddressAction, &QAction::triggered, this, [this]() {
- m_addressBar->setFocus();
- m_addressBar->selectAll();
- });
- addAction(focusAddressAction);
-
resize(m_config->value<int>("browser.window.width").value(), m_config->value<int>("browser.window.height").value());
if(m_config->value<bool>("browser.window.maximized").value()) {
showMaximized();