mirror of
https://git.salome-platform.org/gitpub/modules/smesh.git
synced 2024-11-15 10:08:34 +05:00
Clear AddHypothesis(geom,hyp) command when RemoveHypothesis(geom,hyp) encounters iff both geom and hyp are same
This commit is contained in:
parent
66272cac4b
commit
9e81eb1e25
@ -1539,7 +1539,8 @@ void _pyMesh::Process( const Handle(_pyCommand)& theCommand )
|
|||||||
// ----------------------------------------------------------------------
|
// ----------------------------------------------------------------------
|
||||||
else if ( method == "RemoveHypothesis" ) // (geom, hyp)
|
else if ( method == "RemoveHypothesis" ) // (geom, hyp)
|
||||||
{
|
{
|
||||||
_pyID hypID = theCommand->GetArg( 2 );
|
_pyID hypID = theCommand->GetArg( 2 );
|
||||||
|
_pyID geomID = theCommand->GetArg( 1 );
|
||||||
|
|
||||||
// check if this mesh still has corresponding addition command
|
// check if this mesh still has corresponding addition command
|
||||||
bool hasAddCmd = false;
|
bool hasAddCmd = false;
|
||||||
@ -1547,7 +1548,8 @@ void _pyMesh::Process( const Handle(_pyCommand)& theCommand )
|
|||||||
while ( cmd != myAddHypCmds.end() )
|
while ( cmd != myAddHypCmds.end() )
|
||||||
{
|
{
|
||||||
// AddHypothesis(geom, hyp)
|
// AddHypothesis(geom, hyp)
|
||||||
if ( hypID == (*cmd)->GetArg( 2 )) { // erase both (add and remove) commands
|
if ( hypID == (*cmd)->GetArg( 2 ) &&
|
||||||
|
geomID == (*cmd)->GetArg( 1 )) { // erase both (add and remove) commands
|
||||||
theCommand->Clear();
|
theCommand->Clear();
|
||||||
(*cmd)->Clear();
|
(*cmd)->Clear();
|
||||||
cmd = myAddHypCmds.erase( cmd );
|
cmd = myAddHypCmds.erase( cmd );
|
||||||
|
Loading…
Reference in New Issue
Block a user