From 4127ec8019539a95868663748ff952c87938bd0a Mon Sep 17 00:00:00 2001 From: Ryan Huffman Date: Fri, 24 Apr 2015 09:42:59 -0700 Subject: [PATCH 1/4] Add checkboxes.html --- examples/checkboxes.html | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 examples/checkboxes.html diff --git a/examples/checkboxes.html b/examples/checkboxes.html new file mode 100644 index 0000000000..7c919bfd2d --- /dev/null +++ b/examples/checkboxes.html @@ -0,0 +1,20 @@ + + + + + + + + + + + + + + + +
Checkbox 2
Checkbox 3
Checkbox 4
+ +
+ +
From df591f9ad74aac9de9b1ebe6d237f8fe2b988fdf Mon Sep 17 00:00:00 2001 From: Ryan Huffman Date: Fri, 24 Apr 2015 11:49:33 -0700 Subject: [PATCH 2/4] Set style of webview --- interface/src/scripting/WebWindowClass.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/interface/src/scripting/WebWindowClass.cpp b/interface/src/scripting/WebWindowClass.cpp index 1c9fced619..07188e62b6 100644 --- a/interface/src/scripting/WebWindowClass.cpp +++ b/interface/src/scripting/WebWindowClass.cpp @@ -16,6 +16,7 @@ #include #include #include +#include #include "Application.h" #include "ui/DataWebPage.h" @@ -46,6 +47,7 @@ WebWindowClass::WebWindowClass(const QString& title, const QString& url, int wid dockWidget->setFeatures(QDockWidget::DockWidgetMovable); _webView = new QWebView(dockWidget); + _webView->setStyle(QStyleFactory::create("fusion")); addEventBridgeToWindowObject(); dockWidget->setWidget(_webView); @@ -64,6 +66,7 @@ WebWindowClass::WebWindowClass(const QString& title, const QString& url, int wid dialogWidget->setLayout(layout); _webView = new QWebView(dialogWidget); + _webView->setStyle(QStyleFactory::create("fusion")); layout->addWidget(_webView); From 6087a3e8a93b4e990c611711e28112a8b3e8c05c Mon Sep 17 00:00:00 2001 From: Ryan Huffman Date: Fri, 24 Apr 2015 13:40:02 -0700 Subject: [PATCH 3/4] Revert "Add checkboxes.html" This reverts commit 4127ec8019539a95868663748ff952c87938bd0a. --- examples/checkboxes.html | 20 -------------------- 1 file changed, 20 deletions(-) delete mode 100644 examples/checkboxes.html diff --git a/examples/checkboxes.html b/examples/checkboxes.html deleted file mode 100644 index 7c919bfd2d..0000000000 --- a/examples/checkboxes.html +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - - - - - - - - - - -
Checkbox 2
Checkbox 3
Checkbox 4
- -
- -
From 547b0e5ee64ffd1f850cb71a70c97414b91e35c7 Mon Sep 17 00:00:00 2001 From: Ryan Huffman Date: Fri, 24 Apr 2015 13:42:03 -0700 Subject: [PATCH 4/4] Update style of webview to only be set when 'fusion' exists --- interface/src/scripting/WebWindowClass.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/interface/src/scripting/WebWindowClass.cpp b/interface/src/scripting/WebWindowClass.cpp index 07188e62b6..be36fe1989 100644 --- a/interface/src/scripting/WebWindowClass.cpp +++ b/interface/src/scripting/WebWindowClass.cpp @@ -47,7 +47,6 @@ WebWindowClass::WebWindowClass(const QString& title, const QString& url, int wid dockWidget->setFeatures(QDockWidget::DockWidgetMovable); _webView = new QWebView(dockWidget); - _webView->setStyle(QStyleFactory::create("fusion")); addEventBridgeToWindowObject(); dockWidget->setWidget(_webView); @@ -66,7 +65,6 @@ WebWindowClass::WebWindowClass(const QString& title, const QString& url, int wid dialogWidget->setLayout(layout); _webView = new QWebView(dialogWidget); - _webView->setStyle(QStyleFactory::create("fusion")); layout->addWidget(_webView); @@ -75,6 +73,11 @@ WebWindowClass::WebWindowClass(const QString& title, const QString& url, int wid _windowWidget = dialogWidget; } + auto style = QStyleFactory::create("fusion"); + if (style) { + _webView->setStyle(style); + } + _webView->setPage(new DataWebPage()); _webView->setUrl(url);