From 0b167726780aac72379a444e16149b84c40d2458 Mon Sep 17 00:00:00 2001 From: aqua Date: Sun, 18 Sep 2022 21:42:42 +0300 Subject: Remove UrlBar::loadRequestedUrl slot --- src/panels/navigationtoolbar.cpp | 2 ++ src/panels/navigationtoolbar.hpp | 1 + 2 files changed, 3 insertions(+) (limited to 'src/panels') diff --git a/src/panels/navigationtoolbar.cpp b/src/panels/navigationtoolbar.cpp index ae55ac02..950efaad 100644 --- a/src/panels/navigationtoolbar.cpp +++ b/src/panels/navigationtoolbar.cpp @@ -20,6 +20,8 @@ NavigationToolBar::NavigationToolBar(QWidget *parent) : QToolBar(parent), urlBar // TODO homeAction->setObjectName("actionHome"); addWidget(urlBar); + connect(urlBar, &QLineEdit::returnPressed, this, + [this]() { emit loadRequestedUrl(QUrl::fromUserInput(urlBar->text()), rekonq::CurrentTab); }); auto *actionFocusUrlBar = new QAction(parent); actionFocusUrlBar->setShortcut({"F6"}); diff --git a/src/panels/navigationtoolbar.hpp b/src/panels/navigationtoolbar.hpp index eaf5b145..bdd2d245 100644 --- a/src/panels/navigationtoolbar.hpp +++ b/src/panels/navigationtoolbar.hpp @@ -21,6 +21,7 @@ public: signals: void loadUrl(rekonq::DefaultUrl url, rekonq::OpenType type = rekonq::CurrentTab); + void loadRequestedUrl(const QUrl &url, rekonq::OpenType type = rekonq::CurrentTab); public slots: void setCurrentView(RekonqView *view); -- cgit v1.2.1