From d37d99acdcb7ec9c09e0ec51283efbc61a221601 Mon Sep 17 00:00:00 2001 From: nds Date: Thu, 15 Dec 2016 13:12:38 +0300 Subject: [PATCH] Porting to SALOME_8.2.0 --- src/CollectionPlugin/CMakeLists.txt | 29 ++++++++++++++++++++----- src/ModuleBase/CMakeLists.txt | 1 - src/PartSet/PartSet_ResultSketchPrs.cpp | 5 +++-- src/SamplePanelPlugin/CMakeLists.txt | 2 ++ 4 files changed, 29 insertions(+), 8 deletions(-) diff --git a/src/CollectionPlugin/CMakeLists.txt b/src/CollectionPlugin/CMakeLists.txt index 16e2b2166..653aeb8e6 100644 --- a/src/CollectionPlugin/CMakeLists.txt +++ b/src/CollectionPlugin/CMakeLists.txt @@ -2,22 +2,29 @@ INCLUDE(Common) INCLUDE(UnitTest) +INCLUDE(UseQtExt) + +# additional include directories +INCLUDE_DIRECTORIES(${QT_INCLUDES}) + +# additional preprocessor / compiler flags +ADD_DEFINITIONS(${QT_DEFINITIONS}) SET(PROJECT_HEADERS CollectionPlugin.h CollectionPlugin_Plugin.h CollectionPlugin_Group.h CollectionPlugin_Field.h - CollectionPlugin_WidgetCreator.h - CollectionPlugin_WidgetField.h + CollectionPlugin_WidgetCreator.h + CollectionPlugin_WidgetField.h ) SET(PROJECT_SOURCES CollectionPlugin_Plugin.cpp CollectionPlugin_Group.cpp CollectionPlugin_Field.cpp - CollectionPlugin_WidgetCreator.cpp - CollectionPlugin_WidgetField.cpp + CollectionPlugin_WidgetCreator.cpp + CollectionPlugin_WidgetField.cpp ) SET(XML_RESOURCES @@ -29,6 +36,12 @@ SET(TEXT_RESOURCES CollectionPlugin_msg_en.ts ) +# sources / moc wrappings +QT_WRAP_MOC(PROJECT_AUTOMOC ${PROJECT_HEADERS}) + +#QT5_ADD_TRANSLATION(QM_RESOURCES ${TEXT_RESOURCES}) + +SOURCE_GROUP ("Generated Files" FILES ${PROJECT_AUTOMOC} ${PROJECT_COMPILED_RESOURCES} ${QM_RESOURCES}) SOURCE_GROUP ("Resource Files" FILES ${TEXT_RESOURCES}) @@ -52,10 +65,16 @@ SET(PROJECT_LIBRARIES GeomValidators ModuleBase XGUI + ${QT_LIBRARIES} ) ADD_DEFINITIONS(-DCOLLECTIONPLUGIN_EXPORTS ${CAS_DEFINITIONS}) -ADD_LIBRARY(CollectionPlugin MODULE ${PROJECT_SOURCES} ${PROJECT_HEADERS} ${XML_RESOURCES} ${TEXT_RESOURCES}) +ADD_LIBRARY(CollectionPlugin MODULE + ${PROJECT_SOURCES} + ${PROJECT_HEADERS} + ${XML_RESOURCES} + ${TEXT_RESOURCES} + ${PROJECT_AUTOMOC}) TARGET_LINK_LIBRARIES(CollectionPlugin ${PROJECT_LIBRARIES}) INSTALL(TARGETS CollectionPlugin DESTINATION ${SHAPER_INSTALL_PLUGIN_FILES}) diff --git a/src/ModuleBase/CMakeLists.txt b/src/ModuleBase/CMakeLists.txt index f45095636..8118d8d51 100644 --- a/src/ModuleBase/CMakeLists.txt +++ b/src/ModuleBase/CMakeLists.txt @@ -142,7 +142,6 @@ SET(PROJECT_SOURCES ) SET(PROJECT_LIBRARIES - ${QT_LIBRARIES} Config Events ModelAPI diff --git a/src/PartSet/PartSet_ResultSketchPrs.cpp b/src/PartSet/PartSet_ResultSketchPrs.cpp index 6a96a15d4..029c21bb6 100755 --- a/src/PartSet/PartSet_ResultSketchPrs.cpp +++ b/src/PartSet/PartSet_ResultSketchPrs.cpp @@ -229,11 +229,12 @@ void PartSet_ResultSketchPrs::setAuxiliaryPresentationStyle(const bool isAuxilia Quantity_Color aCurrentColor; Aspect_TypeOfLine aPrevLineType; Standard_Real aCurrentWidth; - aLineAspect->Aspect()->Values(aCurrentColor, aPrevLineType, aCurrentWidth); + // PORTING_TO_SALOME_8 + /*aLineAspect->Aspect()->Values(aCurrentColor, aPrevLineType, aCurrentWidth); bool isChangedLineType = aType != aPrevLineType; if (isChangedLineType) { aLineAspect->SetTypeOfLine(aType); - } + }*/ } void PartSet_ResultSketchPrs::fillShapes(TopoDS_Shape& theResultShape, diff --git a/src/SamplePanelPlugin/CMakeLists.txt b/src/SamplePanelPlugin/CMakeLists.txt index 2cf83e159..4c9c5eaa8 100755 --- a/src/SamplePanelPlugin/CMakeLists.txt +++ b/src/SamplePanelPlugin/CMakeLists.txt @@ -42,6 +42,8 @@ SET(XML_RESOURCES # sources / moc wrappings QT_WRAP_MOC(PROJECT_AUTOMOC ${PROJECT_HEADERS}) +SOURCE_GROUP ("Generated Files" FILES ${PROJECT_AUTOMOC}) + ADD_DEFINITIONS(-DSAMPLEPANELPLUGIN_EXPORTS -DWNT) ADD_LIBRARY(SamplePanelPlugin MODULE ${PROJECT_SOURCES} -- 2.39.2