Commit cd02fdfc authored by Christoph Cullmann's avatar Christoph Cullmann 🍨
Browse files

urlbar: reuse the current document if not modified

just open the url in the current active view
if the underlying document isn't modified
parent 36cdc92a
Pipeline #136926 passed with stage
in 4 minutes and 55 seconds
......@@ -122,8 +122,14 @@ KateViewSpace::KateViewSpace(KateViewManager *viewManager, QWidget *parent, cons
// END tab bar
m_urlBar = new KateUrlBar(this);
// like other editors, we try to re-use documents, of not modified
connect(m_urlBar, &KateUrlBar::openUrlRequested, this, [this](const QUrl &url) {
if (auto activeView = m_viewManager->activeView(); activeView && !activeView->document()->isModified()) {
} else {
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment