0020463: EDF 1099 SMESH: performance regression from V4 to V5

Patch from Erwan ADAM.
This commit is contained in:
vsr 2010-11-19 13:27:33 +00:00
parent 0b8910a8fd
commit da675994d2

View File

@ -923,7 +923,30 @@ void SMESH_Gen_i::UpdateParameters(CORBA::Object_ptr theObject, const char* theP
if(!hasAttr)
aNewParams = anInputParams;
else
aNewParams = aOldParameters+"|"+anInputParams;
{
int pos = aOldParameters.SearchFromEnd("|");
if(pos==-1) pos = 0;
TCollection_AsciiString previousParamFull(aOldParameters.Split(pos));
TCollection_AsciiString previousParam(previousParamFull);
TCollection_AsciiString theRepet("1");
pos = previousParam.SearchFromEnd(";*=");
if(pos >= 0)
{
theRepet = previousParam.Split(pos+2);
pos = pos-1;
if(pos==-1) pos = 0;
previousParam.Split(pos);
}
if(previousParam == anInputParams)
{
theRepet = theRepet.IntegerValue()+1;
aNewParams = aOldParameters + previousParam + ";*=" + theRepet;
}
else
{
aNewParams = aOldParameters + previousParamFull + "|" + anInputParams;
}
}
if(VARIABLE_DEBUG)
{