From 5c8e31e4b6d70669aac97d0580687f1b9e6bda16 Mon Sep 17 00:00:00 2001 From: mpv Date: Wed, 25 May 2022 15:52:38 +0300 Subject: [PATCH] Fix for compilation problems. --- src/Model/Model_BodyBuilder.cpp | 4 ++-- src/Model/Model_Session.cpp | 3 ++- src/ModelHighAPI/ModelHighAPI_Dumper.cpp | 1 + 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/Model/Model_BodyBuilder.cpp b/src/Model/Model_BodyBuilder.cpp index 7e5b79a9d..d68bfa961 100644 --- a/src/Model/Model_BodyBuilder.cpp +++ b/src/Model/Model_BodyBuilder.cpp @@ -529,7 +529,7 @@ void Model_BodyBuilder::generated(const GeomShapePtr& theOldShape, if (aNewShapeType == TopAbs_WIRE || aNewShapeType == TopAbs_SHELL) { // TODO: This is a workaround. New shape should be only vertex, edge or face. TopAbs_ShapeEnum aShapeTypeToExplore = aNewShapeType == TopAbs_WIRE ? TopAbs_EDGE : TopAbs_FACE; - aTag = TopAbs_WIRE ? GENERATED_EDGES_TAG : GENERATED_FACES_TAG; + aTag = aNewShapeType == TopAbs_WIRE ? GENERATED_EDGES_TAG : GENERATED_FACES_TAG; for (TopExp_Explorer anExp(aNewShape, aShapeTypeToExplore); anExp.More(); anExp.Next()) { builder(aTag)->Generated(anOldShape, anExp.Current()); } @@ -750,7 +750,7 @@ void Model_BodyBuilder::loadGeneratedShapes(const GeomMakeShapePtr& theAlgo, // TODO: This is a workaround. New shape should be only edge or face. TopAbs_ShapeEnum aShapeTypeToExplore = aNewShapeType == TopAbs_WIRE ? TopAbs_EDGE : TopAbs_FACE; - int aTag = TopAbs_WIRE ? GENERATED_EDGES_TAG : GENERATED_FACES_TAG; + int aTag = aNewShapeType == TopAbs_WIRE ? GENERATED_EDGES_TAG : GENERATED_FACES_TAG; for (TopExp_Explorer anExp(aNewShape_, aShapeTypeToExplore); anExp.More(); anExp.Next()) { builder(aTag)->Generated(anOldSubShape_, anExp.Current()); // store information about the external document reference to restore old shape on open diff --git a/src/Model/Model_Session.cpp b/src/Model/Model_Session.cpp index 338c45142..9a11c5ae4 100644 --- a/src/Model/Model_Session.cpp +++ b/src/Model/Model_Session.cpp @@ -21,7 +21,6 @@ #include #include #include -#include #include #include #include @@ -675,7 +674,9 @@ void Model_Session::blockAutoUpdate(const bool theBlock) } } +#ifdef TINSPECTOR Handle(TDocStd_Application) Model_Session::application() { return Model_Application::getApplication(); } +#endif \ No newline at end of file diff --git a/src/ModelHighAPI/ModelHighAPI_Dumper.cpp b/src/ModelHighAPI/ModelHighAPI_Dumper.cpp index 4e2662319..020c3fd6a 100644 --- a/src/ModelHighAPI/ModelHighAPI_Dumper.cpp +++ b/src/ModelHighAPI/ModelHighAPI_Dumper.cpp @@ -73,6 +73,7 @@ #include #include #include +#include // =========== Implementation of storage of dumped data =========== static const int THE_DUMP_PRECISION = 16; -- 2.39.2