Show non-fixes shapes if no one constraint is assigned yet.
void PartSet_WidgetSketchLabel::onShowDOF()
{
CompositeFeaturePtr aCompFeature = std::dynamic_pointer_cast<ModelAPI_CompositeFeature>(myFeature);
- if (aCompFeature.get() && aCompFeature->numberOfSubs() > 1) {
+ if (aCompFeature.get()) {
static const Events_ID anEvent = Events_Loop::eventByName(EVENT_GET_DOF_OBJECTS);
ModelAPI_EventCreator::get()->sendUpdated(aCompFeature->subFeature(0), anEvent);
Events_Loop::loop()->flush(anEvent);
void PlaneGCSSolver_Solver::getFreeParameters(GCS::VEC_pD& theFreeParams) const
{
- myEquationSystem->getDependentParams(theFreeParams);
+ if (myConstraints.empty())
+ theFreeParams = myParameters;
+ else
+ myEquationSystem->getDependentParams(theFreeParams);
}
void PlaneGCSSolver_Solver::addFictiveConstraintIfNecessary()
std::map<double*, FeaturePtr> aParamOfFeatures;
for (std::map<FeaturePtr, EntityWrapperPtr>::const_iterator aFIt = myFeatureMap.begin();
aFIt != myFeatureMap.end(); ++aFIt) {
+ if (!aFIt->second)
+ continue;
GCS::SET_pD aParams = PlaneGCSSolver_Tools::parameters(aFIt->second);
for (GCS::SET_pD::iterator aPIt = aParams.begin(); aPIt != aParams.end(); ++aPIt)
aParamOfFeatures[*aPIt] = aFIt->first;