Commit 08fbb24d authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Allow to load or not external reference

parent 9170d1e4
Pipeline #65745 canceled with stage
......@@ -65,7 +65,7 @@ public:
Q_UNUSED(info)
}
};
// #define HAVE_BLOCK_SUPPORT 1
#define HAVE_BLOCK_SUPPORT 1
ArticleViewerWebEngine::ArticleViewerWebEngine(KActionCollection *ac, QWidget *parent)
: WebEngineViewer::WebEngineView(parent)
, mActionCollection(ac)
......@@ -87,6 +87,7 @@ ArticleViewerWebEngine::ArticleViewerWebEngine(KActionCollection *ac, QWidget *p
#ifdef HAVE_BLOCK_SUPPORT
mNetworkAccessManager = new WebEngineViewer::InterceptorManager(this, ac, this);
mExternalReference = new WebEngineViewer::LoadExternalReferencesUrlInterceptor(this);
mExternalReference->setAllowExternalContent(Settings::self()->loadExternalReferences());
// connect(externalReference, &MessageViewer::LoadExternalReferencesUrlInterceptor::urlBlocked, this, &MailWebEngineView::urlBlocked);
mNetworkAccessManager->addInterceptor(mExternalReference);
auto blockTracking = new WebEngineViewer::BlockTrackingUrlInterceptor(this);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment