From: dmv Date: Thu, 4 Sep 2008 14:31:55 +0000 (+0000) Subject: IPAL20317 It's impossible to Delete either a reference or an object through reference... X-Git-Tag: V4_1_0_maintainance_20080915 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=54ab0f94ccc8fa00c80e8c914bf40fdf67688719;p=modules%2Fvisu.git IPAL20317 It's impossible to Delete either a reference or an object through reference in presentation. Regress to version 3.2.1 --- diff --git a/src/VISUGUI/VisuGUI.cxx b/src/VISUGUI/VisuGUI.cxx index cc52fc60..b8cdfba0 100644 --- a/src/VISUGUI/VisuGUI.cxx +++ b/src/VISUGUI/VisuGUI.cxx @@ -1352,6 +1352,7 @@ VisuGUI QObject::tr("WRN_VISU"), QObject::tr("WRN_NO_APPROPRIATE_SELECTION"), QObject::tr("BUT_OK")); + return; } if ( SUIT_MessageBox::warn2( GetDesktop(this), diff --git a/src/VISUGUI/VisuGUI_Tools.cxx b/src/VISUGUI/VisuGUI_Tools.cxx index a349bb95..35b0ad37 100644 --- a/src/VISUGUI/VisuGUI_Tools.cxx +++ b/src/VISUGUI/VisuGUI_Tools.cxx @@ -409,6 +409,15 @@ namespace VISU _PTR(GenericAttribute) anAttr; _PTR(AttributeString) aComment; + _PTR(SObject) aRefSObject; + if (aSObject->ReferencedObject(aRefSObject)) { + // It can be a reference on curve, published under a container. IPAL 20317 + VISU::TObjectInfo aRefObjectInfo = GetObjectByEntry(GetAppStudy(theModule), aRefSObject->GetID()); + VISU::Base_i* aRefBase = aRefObjectInfo.myBase; + if(aRefBase && aRefBase->GetType() == VISU::TCURVE) + return true; + } + bool isUnderVISU = false; _PTR(SObject) aFatherSObject = aSObject->GetFather(); if (aFatherSObject->FindAttribute(anAttr, "AttributeName")) {