From: eap Date: Wed, 12 Mar 2014 11:12:59 +0000 (+0400) Subject: 22364: EDF SMESH: Create Mesh dialog box improvement: hide inapplicable algorithms... X-Git-Tag: V7_4_0a1~36^2~7 X-Git-Url: http://git.salome-platform.org/gitweb/?p=modules%2Fsmesh.git;a=commitdiff_plain;h=e8af590068866acaacd724c667089dc7ab3572f5;hp=88c84e8922f2ff927971ae5f389c9f61f57db190 22364: EDF SMESH: Create Mesh dialog box improvement: hide inapplicable algorithms/hypotheses pass toCheckAll=true to IsApplicable() only if a shape is geom group --- diff --git a/src/SMESH_SWIG/smeshBuilder.py b/src/SMESH_SWIG/smeshBuilder.py index 222e4f9dc..262685a43 100644 --- a/src/SMESH_SWIG/smeshBuilder.py +++ b/src/SMESH_SWIG/smeshBuilder.py @@ -1567,8 +1567,10 @@ class Mesh: if self.mesh.HasShapeToMesh(): hyp_type = hyp.GetName() lib_name = hyp.GetLibName() - isSubMesh = ( not geom.IsSame( self.mesh.GetShapeToMesh() )) - isApplicable = self.smeshpyD.IsApplicable(hyp_type, lib_name, geom, isSubMesh) + checkAll = ( not geom.IsSame( self.mesh.GetShapeToMesh() )) + if checkAll and geom: + checkAll = geom.GetType() == 37 + isApplicable = self.smeshpyD.IsApplicable(hyp_type, lib_name, geom, checkAll) if isApplicable: AssureGeomPublished( self, geom, "shape for %s" % hyp.GetName()) status = self.mesh.AddHypothesis(geom, hyp)