Showing the changes to interface/src/scripting/WebWindowClass.cpp (1 of 1 file). Show all
Unified · Split
| @@ -47,7 +47,6 @@ WebWindowClass::WebWindowClass(const QString& title, const QString& url, int wid · 46 unmodified lines | |||
| 47 | dockWidget->setFeatures(QDockWidget::DockWidgetMovable); | 47 | dockWidget->setFeatures(QDockWidget::DockWidgetMovable); |
| 48 | 48 | ||
| 49 | _webView = new QWebView(dockWidget); | 49 | _webView = new QWebView(dockWidget); |
| 50 | _webView->setStyle(QStyleFactory::create("fusion")); | ||
| 51 | addEventBridgeToWindowObject(); | 50 | addEventBridgeToWindowObject(); |
| 52 | 51 | ||
| 53 | dockWidget->setWidget(_webView); | 52 | dockWidget->setWidget(_webView); |
| @@ -66,7 +65,6 @@ WebWindowClass::WebWindowClass(const QString& title, const QString& url, int wid · 12 unmodified lines | |||
| 66 | dialogWidget->setLayout(layout); | 65 | dialogWidget->setLayout(layout); |
| 67 | 66 | ||
| 68 | _webView = new QWebView(dialogWidget); | 67 | _webView = new QWebView(dialogWidget); |
| 69 | _webView->setStyle(QStyleFactory::create("fusion")); | ||
| 70 | 68 | ||
| 71 | layout->addWidget(_webView); | 69 | layout->addWidget(_webView); |
| 72 | 70 | ||
| @@ -75,6 +73,11 @@ WebWindowClass::WebWindowClass(const QString& title, const QString& url, int wid · 2 unmodified lines | |||
| 75 | _windowWidget = dialogWidget; | 73 | _windowWidget = dialogWidget; |
| 76 | } | 74 | } |
| 77 | 75 | ||
| 76 | auto style = QStyleFactory::create("fusion"); | ||
| 77 | if (style) { | ||
| 78 | _webView->setStyle(style); | ||
| 79 | } | ||
| 80 | |||
| 78 | _webView->setPage(new DataWebPage()); | 81 | _webView->setPage(new DataWebPage()); |
| 79 | _webView->setUrl(url); | 82 | _webView->setUrl(url); |
| 80 | 83 | ||