diff options
author | Aqua-sama <aqua@iserlohn-fortress.net> | 2017-01-23 15:42:14 +0100 |
---|---|---|
committer | Aqua-sama <aqua@iserlohn-fortress.net> | 2017-01-23 15:42:14 +0100 |
commit | d886b377ac168d32668b5f3d145279a4f64de730 (patch) | |
tree | b5547077ce555e8c609495fc6b3851b827abbb3d /src/webengine/adblockinterceptor.h | |
parent | Removed window/title config (diff) | |
download | smolbote-d886b377ac168d32668b5f3d145279a4f64de730.tar.xz |
URL blocking
Diffstat (limited to 'src/webengine/adblockinterceptor.h')
-rw-r--r-- | src/webengine/adblockinterceptor.h | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/src/webengine/adblockinterceptor.h b/src/webengine/adblockinterceptor.h new file mode 100644 index 0000000..061b626 --- /dev/null +++ b/src/webengine/adblockinterceptor.h @@ -0,0 +1,25 @@ +#ifndef ADBLOCKINTERCEPTOR_H +#define ADBLOCKINTERCEPTOR_H + +#include <QWebEngineUrlRequestInterceptor> +#include "adblockrule.h" + +class AdBlockInterceptor : public QWebEngineUrlRequestInterceptor +{ + Q_OBJECT +public: + explicit AdBlockInterceptor(QObject *parent = 0); + + void interceptRequest(QWebEngineUrlRequestInfo &info); + + int loadSubscription(const QString &subpath); + +signals: + +public slots: + +private: + QList<AdBlockRule*> m_urlBlacklist; +}; + +#endif // ADBLOCKINTERCEPTOR_H |