1
mirror of https://invent.kde.org/network/falkon.git synced 2024-12-20 02:36:34 +01:00

When right clicking on link with javascript code, we won't show context

menu for links
This commit is contained in:
nowrep 2011-03-18 20:53:02 +01:00
parent e04885ec27
commit 83721bd9f7

View File

@ -384,7 +384,7 @@ void WebView::contextMenuEvent(QContextMenuEvent* event)
QWebHitTestResult r = page()->mainFrame()->hitTestContent(event->pos());
if (!r.linkUrl().isEmpty()) {
if (!r.linkUrl().isEmpty() && r.linkUrl().scheme()!="javascript") {
if (page()->selectedText() == r.linkText())
findText("");
menu->addAction(tr("Open link in new window"), this, SLOT(openUrlInNewWindow()))->setData(r.linkUrl());