summaryrefslogtreecommitdiff
path: root/src/webpage.cpp
diff options
context:
space:
mode:
authorAndrea Diamantini <adjam7@gmail.com>2010-01-10 12:55:58 +0100
committerAndrea Diamantini <adjam7@gmail.com>2010-01-10 12:55:58 +0100
commit3aa17f3d2d6b2e40da55456d2c7336abbb1df3b5 (patch)
treec5ec4c7e78a27fedc32fb6257cd376a10209a7b1 /src/webpage.cpp
parentfix crash on window close (diff)
downloadrekonq-3aa17f3d2d6b2e40da55456d2c7336abbb1df3b5.tar.xz
Protocol Handling fix
We can now manage all the most important protocols :D
Diffstat (limited to 'src/webpage.cpp')
-rw-r--r--src/webpage.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/webpage.cpp b/src/webpage.cpp
index 70fca7c5..cfa5ff04 100644
--- a/src/webpage.cpp
+++ b/src/webpage.cpp
@@ -105,9 +105,11 @@ bool WebPage::acceptNavigationRequest(QWebFrame *frame, const QNetworkRequest &r
return false;
}
- if(m_protHandler.handle(request,frame))
+ if (frame && m_protHandler.preHandling( request, frame ))
+ {
return false;
-
+ }
+
m_requestedUrl = request.url();
return KWebPage::acceptNavigationRequest(frame, request, type);
@@ -191,6 +193,9 @@ void WebPage::manageNetworkErrors(QNetworkReply* reply)
if( reply->error() == QNetworkReply::NoError )
return;
+ if(m_protHandler.postHandling( reply->request(), mainFrame() ))
+ return;
+
// don't bother on adblocked urls
if( reply->error() == QNetworkReply::ContentAccessDenied )
return;