goldendict-ng/iframeschemehandler.h
Xiao YiFang e6ab87ca73 fix:add ifr local scheme
due to iframe security policy and x-frame-option .
the website online dictionary can not work in qt 5.15.2+ version.
this is a workaround to pass through the restriction.
2022-05-15 22:54:26 +08:00

20 lines
379 B
C++

#ifndef IFRAMESCHEMEHANDLER_H
#define IFRAMESCHEMEHANDLER_H
#include"article_netmgr.hh"
class IframeSchemeHandler : public QWebEngineUrlSchemeHandler
{
Q_OBJECT
public:
IframeSchemeHandler(QObject * parent=nullptr);
void requestStarted(QWebEngineUrlRequestJob *requestJob);
protected:
private:
QNetworkAccessManager mgr;
};
#endif // IFRAMESCHEMEHANDLER_H