diff options
| author | Felix (xq) Queißner <git@mq32.de> | 2020-05-30 19:33:47 +0200 |
|---|---|---|
| committer | Felix (xq) Queißner <git@mq32.de> | 2020-05-30 19:33:47 +0200 |
| commit | ea39cc542e17ce592dc3c4f2053d534bc458d88e (patch) | |
| tree | c3c6a369d5b6d8a6a4e0b3e3667a56ca19e93173 /geminiwebpage.hpp | |
| parent | 79ff338a3427a236ef53adf806c56616faa3426c (diff) | |
| download | kristall-ea39cc542e17ce592dc3c4f2053d534bc458d88e.tar.gz | |
More usability, survives conmans torture nearly with 100%
Diffstat (limited to 'geminiwebpage.hpp')
| -rw-r--r-- | geminiwebpage.hpp | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/geminiwebpage.hpp b/geminiwebpage.hpp index 94c6a82..a5de627 100644 --- a/geminiwebpage.hpp +++ b/geminiwebpage.hpp @@ -3,20 +3,25 @@ #include <QObject> #include <QWebEnginePage> +#include "mainwindow.hpp" class GeminiWebPage : public QWebEnginePage { Q_OBJECT public: - explicit GeminiWebPage(QObject *parent = nullptr); + explicit GeminiWebPage(MainWindow * container); signals: void navigationRequest(QUrl const & url, bool & allow); protected: - bool acceptNavigationRequest(const QUrl &url, NavigationType type, bool isMainFrame); + bool acceptNavigationRequest(const QUrl &url, NavigationType type, bool isMainFrame) override; + QWebEnginePage *createWindow(QWebEnginePage::WebWindowType type) override; + +private: + MainWindow * main_window; }; #endif // GEMINIWEBPAGE_HPP |
