mirror of
https://git.salome-platform.org/gitpub/modules/smesh.git
synced 2025-01-27 23:10:33 +05:00
python dump SetColor() only if the color changes
This commit is contained in:
parent
2fb8ce8c74
commit
aab884d201
@ -582,8 +582,12 @@ void SMESH_GroupBase_i::SetColor(const SALOMEDS::Color& color)
|
||||
if (aGroupDS)
|
||||
{
|
||||
Quantity_Color aQColor( color.R, color.G, color.B, Quantity_TOC_RGB );
|
||||
aGroupDS->SetColor(aQColor);
|
||||
TPythonDump()<<_this()<<".SetColor( SALOMEDS.Color( "<<color.R<<", "<<color.G<<", "<<color.B<<" ))";
|
||||
Quantity_Color oldColor = aGroupDS->GetColor();
|
||||
if ( oldColor != aQColor )
|
||||
{
|
||||
aGroupDS->SetColor(aQColor);
|
||||
TPythonDump()<<_this()<<".SetColor( SALOMEDS.Color( "<<color.R<<", "<<color.G<<", "<<color.B<<" ))";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user