2022-05-18 14:31:47 +00:00
|
|
|
#ifndef ARTICLEWEBPAGE_H
|
|
|
|
#define ARTICLEWEBPAGE_H
|
|
|
|
|
|
|
|
#include <QWebEnginePage>
|
|
|
|
|
2022-06-08 00:19:23 +00:00
|
|
|
struct LastReqInfo{
|
|
|
|
QString group;
|
|
|
|
QString mutedDicts;
|
|
|
|
};
|
|
|
|
|
2022-05-18 14:31:47 +00:00
|
|
|
class ArticleWebPage : public QWebEnginePage
|
|
|
|
{
|
|
|
|
Q_OBJECT
|
|
|
|
public:
|
|
|
|
explicit ArticleWebPage( QObject * parent = nullptr );
|
|
|
|
signals:
|
|
|
|
void linkClicked( const QUrl & url );
|
|
|
|
protected:
|
|
|
|
virtual bool acceptNavigationRequest( const QUrl & url, NavigationType type, bool isMainFrame );
|
2022-06-08 00:19:23 +00:00
|
|
|
private:
|
|
|
|
LastReqInfo lastReq;
|
2022-05-18 14:31:47 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif // ARTICLEWEBPAGE_H
|