From: azv Date: Fri, 1 Oct 2021 13:19:22 +0000 (+0300) Subject: Fix compilation of CAD Builder with SALOME 9.7.0 X-Git-Tag: V9_8_0a1~12 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=9257b41bbeedd309da7982d5a4703700bb368189;p=modules%2Fshaper.git Fix compilation of CAD Builder with SALOME 9.7.0 --- diff --git a/src/PartSet/PartSet_Module.cpp b/src/PartSet/PartSet_Module.cpp index 78130efca..3999ae85e 100644 --- a/src/PartSet/PartSet_Module.cpp +++ b/src/PartSet/PartSet_Module.cpp @@ -146,8 +146,10 @@ #include #include -#include +#ifdef HAVE_SALOME +#include +#endif #define FEATURE_ITEM_COLOR "0,0,225" @@ -1405,6 +1407,7 @@ double getResultTransparency(const ResultPtr& theResult) //****************************************************** void PartSet_Module::setTexture(const std::string & theTextureFile, const AISObjectPtr& thePrs) { +#ifdef HAVE_SALOME Handle(AIS_InteractiveObject) anAIS = thePrs->impl(); if (!anAIS.IsNull()) { @@ -1437,6 +1440,7 @@ void PartSet_Module::setTexture(const std::string & theTextureFile, const AISObj anAISShape->SetDisplayMode(AIS_Shaded); } } +#endif } //****************************************************** diff --git a/src/XGUI/XGUI_Workshop.cpp b/src/XGUI/XGUI_Workshop.cpp index 79ccfdc05..e68c986e6 100644 --- a/src/XGUI/XGUI_Workshop.cpp +++ b/src/XGUI/XGUI_Workshop.cpp @@ -680,6 +680,7 @@ void XGUI_Workshop::showHelpPage(const QString& thePage) const #endif QString aFileName = aDocDir + aSep + thePage; if (QFile::exists(aFileName)) { +#ifdef HAVE_SALOME SUIT_Application* app = SUIT_Session::session()->activeApplication(); if (app) app->onHelpContextModule("SHAPER", aFileName); @@ -687,6 +688,10 @@ void XGUI_Workshop::showHelpPage(const QString& thePage) const QUrl aUrl = QUrl::fromLocalFile(aFileName); QDesktopServices::openUrl(aUrl); } +#else + QUrl aUrl = QUrl::fromLocalFile(aFileName); + QDesktopServices::openUrl(aUrl); +#endif } } }