summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenjamin Poulain <ikipou@gmail.com>2010-11-13 16:24:12 +0100
committerBenjamin Poulain <benjamin.poulain@nokia.com>2010-11-20 18:52:36 +0100
commit00332be135592f04c9c72829d7e3be39f8d79b63 (patch)
treec7b705eb30c7135f02847fb9f9d12b7a7e4a77b5
parentAdd an assertion to ensure the consistency of WebView during development (diff)
downloadrekonq-00332be135592f04c9c72829d7e3be39f8d79b63.tar.xz
Move download handling from WebView to WebPage
Handling download is a responsibility of WebPage, the connection to the implementation is better done in WebPage than in WebView. Reviewed by: Pierre Rossi Reviewed by: Andrea Diamantini
-rw-r--r--src/webpage.cpp1
-rw-r--r--src/webview.cpp1
2 files changed, 1 insertions, 1 deletions
diff --git a/src/webpage.cpp b/src/webpage.cpp
index 2347b6d8..4bbed2f5 100644
--- a/src/webpage.cpp
+++ b/src/webpage.cpp
@@ -210,6 +210,7 @@ WebPage::WebPage(QWidget *parent)
// ----- last stuffs
connect(manager, SIGNAL(finished(QNetworkReply*)), this, SLOT(manageNetworkErrors(QNetworkReply*)));
+ connect(this, SIGNAL(downloadRequested(const QNetworkRequest &)), this, SLOT(downloadRequest(const QNetworkRequest &)));
connect(this, SIGNAL(loadStarted()), this, SLOT(loadStarted()));
connect(this, SIGNAL(loadFinished(bool)), this, SLOT(loadFinished(bool)));
diff --git a/src/webview.cpp b/src/webview.cpp
index 14373db9..980060ef 100644
--- a/src/webview.cpp
+++ b/src/webview.cpp
@@ -94,7 +94,6 @@ WebView::WebView(QWidget* parent)
// download system
connect(this, SIGNAL(linkShiftClicked(const KUrl &)), page, SLOT(downloadUrl(const KUrl &)));
- connect(page, SIGNAL(downloadRequested(const QNetworkRequest &)), page, SLOT(downloadRequest(const QNetworkRequest &)));
// middle click || ctrl + click signal
connect(this, SIGNAL(linkMiddleOrCtrlClicked(const KUrl &)), this, SLOT(loadUrlInNewTab(const KUrl &)));