summaryrefslogtreecommitdiff
path: root/src/webview.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/webview.cpp')
-rw-r--r--src/webview.cpp16
1 files changed, 15 insertions, 1 deletions
diff --git a/src/webview.cpp b/src/webview.cpp
index 2c96f532..f38d363e 100644
--- a/src/webview.cpp
+++ b/src/webview.cpp
@@ -66,6 +66,9 @@ WebView::WebView(QWidget* parent)
connect(this, SIGNAL(loadFinished(bool)), this, SLOT(loadFinished(bool)));
connect(this, SIGNAL(linkMiddleOrCtrlClicked(const KUrl &)), this, SLOT(loadInNewTab(const KUrl &)) );
+
+ connect(this, SIGNAL(linkShiftClicked(const KUrl &)), this, SLOT(downloadRequest(const KUrl &)));
+ connect(page(), SIGNAL(downloadRequested(const QNetworkRequest &)), this, SLOT(downloadRequest(const QNetworkRequest &r)));
}
@@ -427,4 +430,15 @@ void WebView::loadInNewTab(const KUrl &url)
{
Application::instance()->loadUrl(url, Rekonq::NewCurrentTab);
}
- \ No newline at end of file
+
+
+void WebView::downloadRequest(const KUrl &url)
+{
+ m_page->downloadRequest(QNetworkRequest(url));
+}
+
+
+void WebView::downloadRequest(const QNetworkRequest &request)
+{
+ m_page->downloadRequest(request);
+}