summaryrefslogtreecommitdiff
path: root/src/webpage.cpp
diff options
context:
space:
mode:
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;