summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMontel Laurent <[email protected]>2016-04-26 13:41:17 +0200
committerMontel Laurent <[email protected]>2016-04-26 13:41:17 +0200
commit8f94a0041995d1b51d625c374a160b8df7282fcd (patch)
tree1d21bcb3ea1a29aaa2dc49f877929f9c533b479a
parent32f6e7da7ebe2bcc65207cfc6fabd406f99befc1 (diff)
Continue to implement load browser
-rw-r--r--akregator/src/articleviewer-ng/webengine/articleviewerwebengine.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/akregator/src/articleviewer-ng/webengine/articleviewerwebengine.cpp b/akregator/src/articleviewer-ng/webengine/articleviewerwebengine.cpp
index 0c5466f..84aca1a 100644
--- a/akregator/src/articleviewer-ng/webengine/articleviewerwebengine.cpp
+++ b/akregator/src/articleviewer-ng/webengine/articleviewerwebengine.cpp
@@ -91,6 +91,21 @@ ArticleViewerWebEngine::~ArticleViewerWebEngine()
QWebEngineView *ArticleViewerWebEngine::createWindow(QWebEnginePage::WebWindowType type)
{
qDebug()<<" QWebEngineView *ArticleViewerWebEngine::createWindow(QWebEnginePage::WebWindowType type) not implemented yet" << type;
+ switch (type) {
+ case QWebEnginePage::WebBrowserWindow: {
+ if (!Settings::newWindowInTab()) {
+ WebEngineViewer::WebEngineView *view = new WebEngineViewer::WebEngineView();
+ view->setAttribute(Qt::WA_DeleteOnClose);
+ view->show();
+ return view;
+ }
+ }
+ case QWebEnginePage::WebDialog:
+ //TODO add in tab
+ case QWebEnginePage::WebBrowserTab:
+ default:
+ break;
+ }
return Q_NULLPTR;
}