]> SALOME platform Git repositories - modules/smesh.git/commitdiff
Salome HOME
0021014]: EDF 1583 SMESH: Improvement of the Python Dump for the creation of groups
authoreap <eap@opencascade.com>
Thu, 3 Nov 2011 14:07:18 +0000 (14:07 +0000)
committereap <eap@opencascade.com>
Thu, 3 Nov 2011 14:07:18 +0000 (14:07 +0000)
   Set a good filter name in groupOnFilter.SetFilter( filter0x628fc30 )

src/SMESH_I/SMESH_2smeshpy.cxx

index fd59f5c86dc1005369612222d897b521dfd6e07c..2d5ee24f1031f8ead9562b5fccb35c59a7fdc5b8 100644 (file)
@@ -991,6 +991,9 @@ void _pyMesh::Process( const Handle(_pyCommand)& theCommand )
   else if ( method == "CreateGroupFromFilter" ) // --> GroupOnFilter()
   {
     theCommand->SetMethod( "GroupOnFilter" );
+    Handle(_pyGroup) group = new _pyGroup( theCommand );
+    theGen->AddObject( group );
+
     // GroupOnFilter(typ, name, aFilter0x4743dc0 -> aFilter_1)
     _pyID filterID = theCommand->GetArg(3);
     Handle(_pyObject) filter = theGen->FindObject( filterID );
@@ -1294,7 +1297,8 @@ void _pyMeshEditor::Process( const Handle(_pyCommand)& theCommand)
       "SewBorderToSide","SewSideElements","ChangeElemNodes","GetLastCreatedNodes",
       "GetLastCreatedElems",
       "MirrorMakeMesh","MirrorObjectMakeMesh","TranslateMakeMesh",
-      "TranslateObjectMakeMesh","RotateMakeMesh","RotateObjectMakeMesh","MakeBoundaryMesh"
+      "TranslateObjectMakeMesh","RotateMakeMesh","RotateObjectMakeMesh","MakeBoundaryMesh",
+      "MakeBoundaryElements"
       ,"" }; // <- mark of the end
     sameMethods.Insert( names );
   }
@@ -2830,6 +2834,14 @@ void _pyGroup::Process( const Handle(_pyCommand)& theCommand)
     // set new name of a filter
     filter->Process( makeGroupCmd );
   }
+  else if ( theCommand->GetMethod() == "SetFilter" )
+  {
+    // set new name of a filter
+    _pyID filterID = theCommand->GetArg(1);
+    Handle(_pyObject) filter = theGen->FindObject( filterID );
+    if ( !filter.IsNull() )
+      filter->Process( theCommand );
+  }
 }
 
 //================================================================================