diff options
author | Aqua-sama <aqua@iserlohn-fortress.net> | 2017-12-23 16:45:31 +0100 |
---|---|---|
committer | Aqua-sama <aqua@iserlohn-fortress.net> | 2017-12-23 16:45:31 +0100 |
commit | f7ed63179fa4f99322d6c7716e17466ec4e3e4ce (patch) | |
tree | f187d1f73300f1ac0882a4be569d567bb4ed29f7 /src/webengine/urlinterceptor.h | |
parent | Removed SingleApplication::SessionParam (diff) | |
download | smolbote-f7ed63179fa4f99322d6c7716e17466ec4e3e4ce.tar.xz |
Request filter now properly takes hostlists
- hostslist directory is set in browser.filterPath
Diffstat (limited to 'src/webengine/urlinterceptor.h')
-rw-r--r-- | src/webengine/urlinterceptor.h | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/src/webengine/urlinterceptor.h b/src/webengine/urlinterceptor.h index cf1597c..1ff786b 100644 --- a/src/webengine/urlinterceptor.h +++ b/src/webengine/urlinterceptor.h @@ -11,26 +11,22 @@ #include <QWebEngineUrlRequestInterceptor> #include <vector> -#include "filter/filter.h" +#include "hostrule.h" class UrlRequestInterceptor : public QWebEngineUrlRequestInterceptor { Q_OBJECT public: explicit UrlRequestInterceptor(const QString &path, QObject *parent = nullptr); - //~UrlRequestInterceptor(); + ~UrlRequestInterceptor(); void interceptRequest(QWebEngineUrlRequestInfo &info); -signals: - public slots: + int parseHostfile(const QString &filename); private: - - std::vector<FilterRule> m_rules; + std::vector<HostRule*> m_rules; }; -bool shouldBlock(const QUrl &url, const QString &test); - #endif // URLREQUESTINTERCEPTOR_H |