return SMDSAbs_Node;
}
+void CoincidentNodes::SetTolerance( const double theToler )
+{
+ if ( myToler != theToler )
+ {
+ SetMesh(0);
+ myToler = theToler;
+ }
+}
+
void CoincidentNodes::SetMesh( const SMDS_Mesh* theMesh )
{
myMeshModifTracer.SetMesh( theMesh );
myMeshDS = dynamic_cast<const SMESHDS_Mesh*>(theMesh);
init();
}
+ if ( myElementsOnShapePtr )
+ myElementsOnShapePtr->SetMesh( myMeshDS );
}
void BelongToGeom::SetGeom( const TopoDS_Shape& theShape )
myMeshDS = dynamic_cast<const SMESHDS_Mesh*>(theMesh);
init();
}
+ if ( myElementsOnShapePtr )
+ myElementsOnShapePtr->SetMesh( myMeshDS );
}
void LyingOnGeom::SetGeom( const TopoDS_Shape& theShape )
virtual bool IsSatisfy( long theElementId );
virtual SMDSAbs_ElementType GetType() const;
- void SetTolerance (const double theToler) { myToler = theToler; }
+ void SetTolerance (const double theToler);
double GetTolerance () const { return myToler; }
private:
~ManifoldPart();
//virtual Predicate* clone() const { return new ManifoldPart( *this ); }
virtual void SetMesh( const SMDS_Mesh* theMesh );
- // inoke when all parameters already set
+ // invoke when all parameters already set
virtual bool IsSatisfy( long theElementId );
virtual SMDSAbs_ElementType GetType() const;
void SMESHGUI_CtrlInfo::setTolerance( double theTolerance )
{
- //SMESH::long_array_var anElems = getElementsByType( SMESH::NODE );
- myButtons[1]->setEnabled( true );
- myWidgets[2]->setText("");
+ myButtons[2]->setEnabled( true );
+ myWidgets[3]->setText("");
+ for ( int i = 0; i < myPredicates.count(); ++i )
+ if ( myPredicates[i]->GetFunctorType() == SMESH::FT_EqualNodes )
+ {
+ SMESH::EqualNodes_var functor = SMESH::EqualNodes::_narrow( myPredicates[i] );
+ if ( !functor->_is_nil() )
+ functor->SetTolerance( theTolerance );
+ }
}
#ifndef DISABLE_PLOT2DVIEWER