From dc8239e0c1e9cbc0f9d1e68ae14d5c9864da35d4 Mon Sep 17 00:00:00 2001 From: Debian Multimedia Maintainers Date: Mon, 8 Jun 2020 08:17:12 +0100 Subject: [PATCH] optional-qtwebengine-12-7c3305d45cba46096c01ea9f7e8232436c1d3271 commit 7c3305d45cba46096c01ea9f7e8232436c1d3271 Author: Nathan Ho Date: Sat Jun 8 15:19:17 2019 -0700 Change SC_USE_WEBENGINE to SC_USE_QTWEBENGINE Gbp-Pq: Name optional-qtwebengine-12-7c3305d45cba46096c01ea9f7e8232436c1d3271 --- HelpSource/Classes/HelpBrowser.schelp | 2 +- HelpSource/Classes/WebView.schelp | 2 +- QtCollider/CMakeLists.txt | 6 +-- QtCollider/factories.cpp | 2 +- QtCollider/interface.cpp | 4 +- QtCollider/style/ProxyStyle.cpp | 6 +-- QtCollider/widgets/QcWebView.cpp | 4 +- QtCollider/widgets/web_page.cpp | 4 +- editors/sc-ide/CMakeLists.txt | 8 ++-- editors/sc-ide/core/main.cpp | 20 ++++----- .../widgets/code_editor/autocompleter.cpp | 8 ++-- .../sc-ide/widgets/code_editor/sc_editor.cpp | 12 ++--- editors/sc-ide/widgets/help_browser.cpp | 4 +- editors/sc-ide/widgets/main_window.cpp | 44 +++++++++---------- editors/sc-ide/widgets/main_window.hpp | 4 +- editors/sc-ide/widgets/style/style.cpp | 8 ++-- .../widgets/util/WebSocketTransport.cpp | 4 +- lang/CMakeLists.txt | 4 +- 18 files changed, 73 insertions(+), 73 deletions(-) diff --git a/HelpSource/Classes/HelpBrowser.schelp b/HelpSource/Classes/HelpBrowser.schelp index 20e94ab..799d20a 100644 --- a/HelpSource/Classes/HelpBrowser.schelp +++ b/HelpSource/Classes/HelpBrowser.schelp @@ -9,7 +9,7 @@ HelpBrowser is the GUI help browser that lets you browse the documentation of Su Note that this is not the same as the help browser built into the IDE. -Since the Qt WebEngine dependency is hefty and difficult to install on some systems, it is possible for sclang to have been built without WebView support (using the CMake flag code:: -DSC_USE_WEBENGINE=OFF :: at compile). If so, attempting to invoke this class will throw an error. +Since the Qt WebEngine dependency is hefty and difficult to install on some systems, it is possible for sclang to have been built without WebView support (using the CMake flag code:: -DSC_USE_QTWEBENGINE=OFF :: at compile). If so, attempting to invoke this class will throw an error. classmethods:: private:: getOldWrapUrl, initClass diff --git a/HelpSource/Classes/WebView.schelp b/HelpSource/Classes/WebView.schelp index 74cf943..d2fb326 100644 --- a/HelpSource/Classes/WebView.schelp +++ b/HelpSource/Classes/WebView.schelp @@ -6,7 +6,7 @@ DESCRIPTION:: WebView displays web pages and provides all the standard browsing functionality. -Since the Qt WebEngine dependency is hefty and difficult to install on some systems, it is possible for sclang to have been built without WebView support (using the CMake flag code:: -DSC_USE_WEBENGINE=OFF :: at compile). If so, attempting to invoke this class will throw an error. +Since the Qt WebEngine dependency is hefty and difficult to install on some systems, it is possible for sclang to have been built without WebView support (using the CMake flag code:: -DSC_USE_QTWEBENGINE=OFF :: at compile). If so, attempting to invoke this class will throw an error. CLASSMETHODS:: diff --git a/QtCollider/CMakeLists.txt b/QtCollider/CMakeLists.txt index f9da30d..de38afb 100644 --- a/QtCollider/CMakeLists.txt +++ b/QtCollider/CMakeLists.txt @@ -1,5 +1,5 @@ set(REQUIRED_QT_VERSION 5.7) -option(SC_USE_WEBENGINE "Build with Qt WebEngine." ON) +option(SC_USE_QTWEBENGINE "Build with Qt WebEngine." ON) ############################################################################### # Components and libraries @@ -22,7 +22,7 @@ set (QT_COLLIDER_LIBS Qt5::Quick Qt5::Qml Qt5::Sql Qt5::OpenGL Qt5::Svg ${MATH_LIBRARY}) -if(SC_USE_WEBENGINE) +if(SC_USE_QTWEBENGINE) list(APPEND QT_COMPONENTS WebEngine WebEngineCore WebEngineWidgets) list(APPEND QT_COLLIDER_LIBS Qt5::WebEngineCore Qt5::WebEngineWidgets) endif() @@ -151,7 +151,7 @@ set(QT_COLLIDER_WEBENGINE_HDRS ${QT_COLLIDER_DIR}/widgets/web_page.hpp ) -if(SC_USE_WEBENGINE) +if(SC_USE_QTWEBENGINE) list(APPEND QT_COLLIDER_HDRS ${QT_COLLIDER_WEBENGINE_HDRS}) endif() diff --git a/QtCollider/factories.cpp b/QtCollider/factories.cpp index c3d04b6..85bb89b 100644 --- a/QtCollider/factories.cpp +++ b/QtCollider/factories.cpp @@ -66,7 +66,7 @@ static void doLoadFactories() { QC_ADD_FACTORY(QcGridLayout); QC_ADD_FACTORY(QcStackLayout); QC_ADD_FACTORY(QtDownload); -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE QC_ADD_FACTORY(WebView); #endif #ifdef __APPLE__ diff --git a/QtCollider/interface.cpp b/QtCollider/interface.cpp index d3f5c20..ae79c2d 100644 --- a/QtCollider/interface.cpp +++ b/QtCollider/interface.cpp @@ -30,7 +30,7 @@ #include #include -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE # include #endif @@ -82,7 +82,7 @@ void QtCollider::init() { gSystemPalette = qcApp->palette(); -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE // Enable javascript localStorage for WebViews QWebEngineSettings::globalSettings()->setAttribute(QWebEngineSettings::LocalStorageEnabled, true); #endif diff --git a/QtCollider/style/ProxyStyle.cpp b/QtCollider/style/ProxyStyle.cpp index 38a0b77..21bce63 100644 --- a/QtCollider/style/ProxyStyle.cpp +++ b/QtCollider/style/ProxyStyle.cpp @@ -6,7 +6,7 @@ #include #include -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE # include #endif @@ -33,7 +33,7 @@ static bool AlwaysShowScrollbars() { void ProxyStyle::drawComplexControl(ComplexControl ctrl, const QStyleOptionComplex* opt, QPainter* p, const QWidget* w) const { -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE // FIXME: this is a workaround for the WebKit bug #104116 (or a variation on it). if (ctrl == QStyle::CC_ScrollBar && qobject_cast(w) != 0 && opt->type == QStyleOption::SO_Slider) { @@ -45,7 +45,7 @@ void ProxyStyle::drawComplexControl(ComplexControl ctrl, const QStyleOptionCompl QProxyStyle::drawComplexControl(ctrl, &opt2, p, w); return; } -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE if (ctrl == QStyle::CC_ScrollBar && AlwaysShowScrollbars()) { const QStyleOptionSlider* optSlider = static_cast(opt); diff --git a/QtCollider/widgets/QcWebView.cpp b/QtCollider/widgets/QcWebView.cpp index be781a6..201266d 100644 --- a/QtCollider/widgets/QcWebView.cpp +++ b/QtCollider/widgets/QcWebView.cpp @@ -19,7 +19,7 @@ * ************************************************************************/ -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE # include "QcWebView.h" # include "../widgets/web_page.hpp" @@ -324,4 +324,4 @@ void WebView::onLinkClicked(const QUrl &url, QWebEnginePage::NavigationType type } // namespace QtCollider -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE diff --git a/QtCollider/widgets/web_page.cpp b/QtCollider/widgets/web_page.cpp index 1dbb14f..879faa5 100644 --- a/QtCollider/widgets/web_page.cpp +++ b/QtCollider/widgets/web_page.cpp @@ -19,7 +19,7 @@ * ************************************************************************/ -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE # include "web_page.hpp" @@ -63,4 +63,4 @@ bool WebPage::acceptNavigationRequest(const QUrl& url, QWebEnginePage::Navigatio } // namespace QtCollider -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE diff --git a/editors/sc-ide/CMakeLists.txt b/editors/sc-ide/CMakeLists.txt index d028640..7879c60 100644 --- a/editors/sc-ide/CMakeLists.txt +++ b/editors/sc-ide/CMakeLists.txt @@ -24,7 +24,7 @@ set(QT_IDE_LIBRARIES Qt5::Sql ) -if(SC_USE_WEBENGINE) +if(SC_USE_QTWEBENGINE) list(APPEND QT_IDE_COMPONENTS WebChannel WebEngine @@ -200,7 +200,7 @@ set(ide_webengine_src ${CMAKE_SOURCE_DIR}/QtCollider/widgets/web_page.cpp ) -if(SC_USE_WEBENGINE) +if(SC_USE_QTWEBENGINE) list(APPEND ide_moc_hdr ${ide_webengine_moc_hdrs}) list(APPEND ide_src ${ide_webengine_src}) endif() @@ -354,9 +354,9 @@ if(LTO) APPEND PROPERTY LINK_FLAGS "-flto -flto-report -fwhole-program") endif() -if(SC_USE_WEBENGINE) +if(SC_USE_QTWEBENGINE) message(STATUS "IDE: Building with QtWebEngine") - target_compile_definitions(SuperCollider PUBLIC SC_USE_WEBENGINE) + target_compile_definitions(SuperCollider PUBLIC SC_USE_QTWEBENGINE) endif() # Installation diff --git a/editors/sc-ide/core/main.cpp b/editors/sc-ide/core/main.cpp index d45792a..59497f3 100644 --- a/editors/sc-ide/core/main.cpp +++ b/editors/sc-ide/core/main.cpp @@ -43,12 +43,12 @@ #include #include -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE # include # include "../widgets/util/WebSocketClientWrapper.hpp" # include "../widgets/util/WebSocketTransport.hpp" # include "../widgets/util/IDEWebChannelWrapper.hpp" -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE using namespace ScIDE; @@ -137,7 +137,7 @@ int main( int argc, char *argv[] ) if (startInterpreter) main->scProcess()->startLanguage(); -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE // setup HelpBrowser server QWebSocketServer server("SCIDE HelpBrowser Server", QWebSocketServer::NonSecureMode); if (!server.listen(QHostAddress::LocalHost, 12344)) { @@ -153,7 +153,7 @@ int main( int argc, char *argv[] ) // publish IDE interface IDEWebChannelWrapper ideWrapper { win->helpBrowserDocklet()->browser() }; channel.registerObject("IDE", &ideWrapper); -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE return app.exec(); } @@ -314,7 +314,7 @@ bool Main::nativeEventFilter(const QByteArray &, void * message, long *) } bool Main::openDocumentation(const QString& string) { -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE QString symbol = string.trimmed(); if (symbol.isEmpty()) return false; @@ -323,20 +323,20 @@ bool Main::openDocumentation(const QString& string) { helpDock->browser()->gotoHelpFor(symbol); helpDock->focus(); return true; -#else // SC_USE_WEBENGINE +#else // SC_USE_QTWEBENGINE return false; -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE } bool Main::openDocumentationForMethod(const QString& className, const QString& methodName) { -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE HelpBrowserDocklet* helpDock = MainWindow::instance()->helpBrowserDocklet(); helpDock->browser()->gotoHelpForMethod(className, methodName); helpDock->focus(); return true; -#else // SC_USE_WEBENGINE +#else // SC_USE_QTWEBENGINE return false; -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE } void Main::openDefinition(const QString& string, QWidget* parent) { diff --git a/editors/sc-ide/widgets/code_editor/autocompleter.cpp b/editors/sc-ide/widgets/code_editor/autocompleter.cpp index b35e204..50ff741 100644 --- a/editors/sc-ide/widgets/code_editor/autocompleter.cpp +++ b/editors/sc-ide/widgets/code_editor/autocompleter.cpp @@ -29,9 +29,9 @@ #include "../../core/util/standard_dirs.hpp" #include "../main_window.hpp" -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE # include "../help_browser.hpp" -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE #include #include @@ -1310,11 +1310,11 @@ void AutoCompleter::parseClassNode(DocNode *node, QString *str) } void AutoCompleter::gotoHelp(QString symbol) { -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE HelpBrowserDocklet* helpDock = MainWindow::instance()->helpBrowserDocklet(); helpDock->browser()->gotoHelpFor(symbol); helpDock->focus(); -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE } } // namespace ScIDE diff --git a/editors/sc-ide/widgets/code_editor/sc_editor.cpp b/editors/sc-ide/widgets/code_editor/sc_editor.cpp index cebc0c5..57be622 100644 --- a/editors/sc-ide/widgets/code_editor/sc_editor.cpp +++ b/editors/sc-ide/widgets/code_editor/sc_editor.cpp @@ -28,9 +28,9 @@ #include "../../core/settings/manager.hpp" #include "../../core/settings/theme.hpp" -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE # include "help_browser.hpp" -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE #include "QtCollider/hacks/hacks_qt.hpp" @@ -1319,13 +1319,13 @@ void ScCodeEditor::evaluateLine() { QString text; -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE HelpBrowserDocklet* help = MainWindow::instance()->helpBrowserDocklet(); if (help && help->browser()->helpBrowserHasFocus()) { help->browser()->evaluateSelection(false); return; // early return } -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE // Try current selection QTextCursor cursor = textCursor(); @@ -1360,13 +1360,13 @@ void ScCodeEditor::evaluateRegion() { QString text; -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE HelpBrowserDocklet* help = MainWindow::instance()->helpBrowserDocklet(); if (help && help->browser()->helpBrowserHasFocus()) { help->browser()->evaluateSelection(true); return; // early return } -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE // Try current selection QTextCursor cursor = textCursor(); diff --git a/editors/sc-ide/widgets/help_browser.cpp b/editors/sc-ide/widgets/help_browser.cpp index 05afce6..f3941ad 100644 --- a/editors/sc-ide/widgets/help_browser.cpp +++ b/editors/sc-ide/widgets/help_browser.cpp @@ -18,7 +18,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE # define QT_NO_DEBUG_OUTPUT @@ -527,4 +527,4 @@ HelpBrowserDocklet::HelpBrowserDocklet( QWidget *parent ): } // namespace ScIDE -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE diff --git a/editors/sc-ide/widgets/main_window.cpp b/editors/sc-ide/widgets/main_window.cpp index f283488..a6d1cbe 100644 --- a/editors/sc-ide/widgets/main_window.cpp +++ b/editors/sc-ide/widgets/main_window.cpp @@ -43,9 +43,9 @@ #include "code_editor/sc_editor.hpp" #include "settings/dialog.hpp" -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE # include "help_browser.hpp" -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE #include "QtCollider/hacks/hacks_qt.hpp" @@ -146,12 +146,12 @@ MainWindow::MainWindow(Main * main) : addDockWidget(Qt::LeftDockWidgetArea, mDocumentsDocklet->dockWidget()); mDocumentsDocklet->hide(); -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE mHelpBrowserDocklet = new HelpBrowserDocklet(this); mHelpBrowserDocklet->setObjectName("help-dock"); addDockWidget(Qt::RightDockWidgetArea, mHelpBrowserDocklet->dockWidget()); // mHelpBrowserDockable->hide(); -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE mPostDocklet = new PostDocklet(this); mPostDocklet->setObjectName("post-dock"); @@ -486,12 +486,12 @@ void MainWindow::createActions() action->setStatusTip(tr("Show/hide Documents docklet")); settings->addAction(mDocumentsDocklet->toggleViewAction(), "ide-docklet-documents", ideCategory); -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE action = mHelpBrowserDocklet->toggleViewAction(); action->setIcon(QIcon::fromTheme("system-help")); action->setStatusTip(tr("Show/hide Help browser docklet")); settings->addAction(mHelpBrowserDocklet->toggleViewAction(), "ide-docklet-help", ideCategory); -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE // In Mac OS, all menu item shortcuts need a modifier, so add the action with // the "Escape" default shortcut to the main window widget. @@ -508,14 +508,14 @@ void MainWindow::createActions() mPostDocklet->widget()->addAction(mActions[LookupReferences]); mPostDocklet->widget()->addAction(mActions[LookupReferencesForCursor]); -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE mHelpBrowserDocklet->widget()->addAction(mActions[LookupDocumentation]); mHelpBrowserDocklet->widget()->addAction(mActions[LookupDocumentationForCursor]); mHelpBrowserDocklet->widget()->addAction(mActions[LookupImplementation]); mHelpBrowserDocklet->widget()->addAction(mActions[LookupImplementationForCursor]); mHelpBrowserDocklet->widget()->addAction(mActions[LookupReferences]); mHelpBrowserDocklet->widget()->addAction(mActions[LookupReferencesForCursor]); -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE } void MainWindow::createMenus() { @@ -593,9 +593,9 @@ void MainWindow::createMenus() { submenu = new QMenu(tr("&Docklets"), this); submenu->addAction(mPostDocklet->toggleViewAction()); submenu->addAction(mDocumentsDocklet->toggleViewAction()); -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE submenu->addAction(mHelpBrowserDocklet->toggleViewAction()); -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE menu->addMenu(submenu); menu->addSeparator(); submenu = menu->addMenu(tr("&Tool Panels")); @@ -672,12 +672,12 @@ void MainWindow::createMenus() { menu = new QMenu(tr("&Help"), this); menu->addAction(mActions[HelpAboutIDE]); menu->addAction(mActions[ReportABug]); -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE menu->addSeparator(); menu->addAction(mActions[Help]); menu->addAction(mActions[LookupDocumentationForCursor]); menu->addAction(mActions[LookupDocumentation]); -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE menu->addSeparator(); menu->addAction(mActions[ShowAbout]); menu->addAction(mActions[ShowAboutQT]); @@ -693,9 +693,9 @@ template void MainWindow::saveWindowState(T* settings) { QVariantMap detachedData; saveDetachedState(mPostDocklet, detachedData); saveDetachedState(mDocumentsDocklet, detachedData); -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE saveDetachedState(mHelpBrowserDocklet, detachedData); -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE settings->beginGroup("mainWindow"); settings->setValue("geometry", this->saveGeometry().toBase64()); @@ -742,9 +742,9 @@ void MainWindow::restoreWindowState( T * settings ) restoreDetachedState(mPostDocklet, detachedData); restoreDetachedState(mDocumentsDocklet, detachedData); -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE restoreDetachedState(mHelpBrowserDocklet, detachedData); -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE qDebug("restoring state"); @@ -1397,9 +1397,9 @@ void MainWindow::applySettings(Settings::Manager* settings) { applyCursorBlinkingSettings(settings); mPostDocklet->mPostWindow->applySettings(settings); -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE mHelpBrowserDocklet->browser()->applySettings(settings); -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE mCmdLine->applySettings(settings); } @@ -1575,18 +1575,18 @@ void MainWindow::lookupDocumentationForCursor() { } void MainWindow::openHelp() { -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE if (mHelpBrowserDocklet->browser()->url().isEmpty()) mHelpBrowserDocklet->browser()->goHome(); mHelpBrowserDocklet->focus(); -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE } void MainWindow::openHelpAboutIDE() { -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE mHelpBrowserDocklet->browser()->gotoHelpFor("Guides/SCIde"); mHelpBrowserDocklet->focus(); -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE } void MainWindow::doBugReport() { diff --git a/editors/sc-ide/widgets/main_window.hpp b/editors/sc-ide/widgets/main_window.hpp index c95af11..7c9b828 100644 --- a/editors/sc-ide/widgets/main_window.hpp +++ b/editors/sc-ide/widgets/main_window.hpp @@ -120,7 +120,7 @@ public: void focusCodeEditor(); bool promptSaveDocs(); -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE HelpBrowserDocklet* helpBrowserDocklet() { return mHelpBrowserDocklet; } #endif PostDocklet* postDocklet() { return mPostDocklet; } @@ -239,7 +239,7 @@ private: // Docks PostDocklet* mPostDocklet; DocumentsDocklet* mDocumentsDocklet; -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE HelpBrowserDocklet* mHelpBrowserDocklet; #endif diff --git a/editors/sc-ide/widgets/style/style.cpp b/editors/sc-ide/widgets/style/style.cpp index d77f539..3ce4cd6 100644 --- a/editors/sc-ide/widgets/style/style.cpp +++ b/editors/sc-ide/widgets/style/style.cpp @@ -33,9 +33,9 @@ #include #include -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE # include -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE namespace ScIDE { @@ -74,7 +74,7 @@ void Style::drawComplexControl(ComplexControl control, const QStyleOptionComplex } switch (control) { -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE // FIXME: this is a workaround for the WebKit bug #104116 (or a variation on it). case QStyle::CC_ScrollBar: { if (qobject_cast(widget) != 0 && option->type == QStyleOption::SO_Slider) { @@ -87,7 +87,7 @@ void Style::drawComplexControl(ComplexControl control, const QStyleOptionComplex return; } } -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE case QStyle::CC_ToolButton: { // TODO: We only draw either text, or icon, or arrow diff --git a/editors/sc-ide/widgets/util/WebSocketTransport.cpp b/editors/sc-ide/widgets/util/WebSocketTransport.cpp index 126e8f5..a2259d0 100644 --- a/editors/sc-ide/widgets/util/WebSocketTransport.cpp +++ b/editors/sc-ide/widgets/util/WebSocketTransport.cpp @@ -48,7 +48,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#ifdef SC_USE_WEBENGINE +#ifdef SC_USE_QTWEBENGINE # include "WebSocketTransport.hpp" @@ -88,4 +88,4 @@ void WebSocketTransport::textMessageReceived(const QString &messageData) { } // namespace ScIDE -#endif // SC_USE_WEBENGINE +#endif // SC_USE_QTWEBENGINE diff --git a/lang/CMakeLists.txt b/lang/CMakeLists.txt index 879e0e6..bc03385 100644 --- a/lang/CMakeLists.txt +++ b/lang/CMakeLists.txt @@ -182,9 +182,9 @@ if(SC_QT OR SC_IDE) message(STATUS "Found Qt: " ${QtCore_location} ) get_filename_component(QT_BIN_PATH ${QtCore_location} DIRECTORY CACHE) - if(SC_USE_WEBENGINE) + if(SC_USE_QTWEBENGINE) message(STATUS "sclang: Building with QtWebEngine") - target_compile_definitions(libsclang PUBLIC SC_USE_WEBENGINE) + target_compile_definitions(libsclang PUBLIC SC_USE_QTWEBENGINE) endif() target_link_libraries(libsclang ${QT_COLLIDER_LIBS}) endif() -- 2.30.2