From c0f258a52dfcce0812fe7bf2c5d054afdb7a8d3b Mon Sep 17 00:00:00 2001 From: Andrea Diamantini Date: Sun, 25 Nov 2012 12:43:40 +0100 Subject: re-enable the (useful) "open link in new tab" action in web app mode --- src/application.cpp | 3 ++- src/webtab/webview.cpp | 11 ++++------- 2 files changed, 6 insertions(+), 8 deletions(-) (limited to 'src') diff --git a/src/application.cpp b/src/application.cpp index 13cbc174..92444625 100644 --- a/src/application.cpp +++ b/src/application.cpp @@ -388,7 +388,8 @@ void Application::loadUrl(const KUrl& url, const Rekonq::OpenType& type) newType = Rekonq::CurrentTab; } else if (newType == Rekonq::NewWindow - || (newType == Rekonq::NewTab && ReKonfig::openLinksInNewWindow())) + || (newType == Rekonq::NewTab && ReKonfig::openLinksInNewWindow()) + || (newType == Rekonq::NewTab && tabWindowList().count() == 0)) { w = newTabWindow(); newType = Rekonq::CurrentTab; diff --git a/src/webtab/webview.cpp b/src/webtab/webview.cpp index 31082a61..48c35615 100644 --- a/src/webtab/webview.cpp +++ b/src/webtab/webview.cpp @@ -370,13 +370,10 @@ void WebView::contextMenuEvent(QContextMenuEvent *event) sendByMailAction->setData(m_contextMenuHitResult.linkUrl()); sendByMailAction->setText(i18n("Share link")); - if (webwin) - { - a = new KAction(KIcon("tab-new"), i18n("Open in New &Tab"), this); - a->setData(m_contextMenuHitResult.linkUrl()); - connect(a, SIGNAL(triggered(bool)), this, SLOT(openLinkInNewTab())); - menu.addAction(a); - } + a = new KAction(KIcon("tab-new"), i18n("Open in New &Tab"), this); + a->setData(m_contextMenuHitResult.linkUrl()); + connect(a, SIGNAL(triggered(bool)), this, SLOT(openLinkInNewTab())); + menu.addAction(a); a = new KAction(KIcon("window-new"), i18n("Open in New &Window"), this); a->setData(m_contextMenuHitResult.linkUrl()); -- cgit v1.2.1