From 3762b79ef95689a580fa9861abfdf3b14bc26178 Mon Sep 17 00:00:00 2001 From: mpv Date: Wed, 6 May 2020 16:45:16 +0300 Subject: [PATCH] Fix for the issue #19039 Can't select solids to create a compound and the issue #19019 Python dump not loadable --- src/Model/Model_AttributeSelection.cpp | 2 ++ src/Model/Model_Update.cpp | 8 -------- 2 files changed, 2 insertions(+), 8 deletions(-) diff --git a/src/Model/Model_AttributeSelection.cpp b/src/Model/Model_AttributeSelection.cpp index 9f93e1e92..6cd4958d2 100644 --- a/src/Model/Model_AttributeSelection.cpp +++ b/src/Model/Model_AttributeSelection.cpp @@ -1987,6 +1987,8 @@ ResultPtr Model_AttributeSelection::newestContext( const ResultPtr theCurrent, const GeomShapePtr theValue) { ResultPtr aResult = theCurrent; + if (!std::dynamic_pointer_cast(aResult).get()) + return aResult; // construction, groups and other results are not propagated (#19019) GeomShapePtr aSelectedShape = theValue.get() ? theValue : theCurrent->shape(); std::shared_ptr aDoc = std::dynamic_pointer_cast(owner()->document()); diff --git a/src/Model/Model_Update.cpp b/src/Model/Model_Update.cpp index 40c5fe191..052468c78 100644 --- a/src/Model/Model_Update.cpp +++ b/src/Model/Model_Update.cpp @@ -735,14 +735,6 @@ bool Model_Update::processFeature(FeaturePtr theFeature) } if (aDoExecute) { executeFeature(theFeature); - // Tuleap issue #19019: when loading python dump several wires are referred to the same - // sketch edge. First wire is concealed by another feature, but the flag is not initialized - // for the result. When the next wire is created, it finds wire as a referred feature - // instead of sketch edge. - // As a result, call synchronization to initialize the concealed flag. - Model_Objects* aDocObjects = - std::dynamic_pointer_cast(theFeature->document())->objects(); - aDocObjects->synchronizeBackRefs(); } else { // store information that this feature must be executed later theFeature->data()->execState(ModelAPI_StateMustBeUpdated); -- 2.39.2