summaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@theqtcompany.com>2016-06-03 15:48:17 +0200
committerAllan Sandfeld Jensen <allan.jensen@qt.io>2016-06-07 07:19:32 +0000
commita387064650a749e3767574fa82d0ae4117785879 (patch)
tree3ec9800934181261c7d258fa6b8d9323c806f563 /examples
parent6ba99be5a88ea9f8dff7094dac5ea266c7a39355 (diff)
Enable plugins in the simplebrowser
This makes it possible to also test flash from simplebrowser. Change-Id: I94677383fdbea4a723432ea6811ee72314c019fd Reviewed-by: Alexandru Croitor <alexandru.croitor@theqtcompany.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Diffstat (limited to 'examples')
-rw-r--r--examples/webenginewidgets/simplebrowser/main.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/examples/webenginewidgets/simplebrowser/main.cpp b/examples/webenginewidgets/simplebrowser/main.cpp
index 750e7ae43..1d2796b8c 100644
--- a/examples/webenginewidgets/simplebrowser/main.cpp
+++ b/examples/webenginewidgets/simplebrowser/main.cpp
@@ -41,6 +41,7 @@
#include "browser.h"
#include "browserwindow.h"
#include <QApplication>
+#include <QWebEngineSettings>
QString getCommandLineUrlArgument()
{
@@ -59,6 +60,8 @@ int main(int argc, char **argv)
QApplication app(argc, argv);
app.setWindowIcon(QIcon(QLatin1String(":simplebrowser.svg")));
+ QWebEngineSettings::defaultSettings()->setAttribute(QWebEngineSettings::PluginsEnabled, true);
+
BrowserWindow *window = new BrowserWindow();
Browser::instance().addWindow(window);