From 1c886272b410051f72096ab2ebd8d7ade47d02fd Mon Sep 17 00:00:00 2001 From: mpa Date: Thu, 12 Dec 2013 12:12:28 +0000 Subject: [PATCH] 0022312: EDF 2689 GEOM: Save view parameters in the Study --- src/GEOMGUI/GEOM_Displayer.cxx | 27 +-------------------------- 1 file changed, 1 insertion(+), 26 deletions(-) diff --git a/src/GEOMGUI/GEOM_Displayer.cxx b/src/GEOMGUI/GEOM_Displayer.cxx index 8cad286d6..566e42c19 100644 --- a/src/GEOMGUI/GEOM_Displayer.cxx +++ b/src/GEOMGUI/GEOM_Displayer.cxx @@ -673,8 +673,7 @@ void GEOM_Displayer::updateShapeProperties( const Handle(GEOM_AISShape)& AISShap AISShape->SetDisplayVectors( propMap.value( GEOM::propertyName( GEOM::EdgesDirection ) ).toBool() ); // set transparency - // VSR: ??? next line is commented: transparency property is set in the AfterDisplay() function - //AISShape->SetTransparency( propMap.value( GEOM::propertyName( GEOM::Transparency ) ).toDouble() ); + AISShape->SetTransparency( propMap.value( GEOM::propertyName( GEOM::Transparency ) ).toDouble() ); // set iso properties int uIsos = propMap.value( GEOM::propertyName( GEOM::NbIsos ) ).toString().split( GEOM::subSectionSeparator() )[0].toInt(); @@ -1593,30 +1592,6 @@ void GEOM_Displayer::BeforeDisplay( SALOME_View* v, const SALOME_OCCPrs* ) void GEOM_Displayer::AfterDisplay( SALOME_View* v, const SALOME_OCCPrs* p ) { - SalomeApp_Study* aStudy = getStudy(); - if (!aStudy) return; - SOCC_Viewer* vf = dynamic_cast( v ); - if ( vf && !p->IsNull() ) { - int aMgrId = getViewManagerId( vf ); - Handle(AIS_InteractiveContext) ic = vf->getAISContext(); - const SOCC_Prs* prs = dynamic_cast( p ); - if ( !ic.IsNull() && prs ) { - AIS_ListOfInteractive objects; - prs->GetObjects( objects ); - AIS_ListIteratorOfListOfInteractive it( objects ); - for ( ; it.More(); it.Next() ) { - Handle(GEOM_AISShape) sh = Handle(GEOM_AISShape)::DownCast( it.Value() ); - if ( sh.IsNull() ) continue; - Handle(SALOME_InteractiveObject) IO = sh->getIO(); - if ( IO.IsNull() ) continue; - PropMap aPropMap = aStudy->getObjectPropMap( aMgrId, IO->getEntry() ); - if ( aPropMap.contains( GEOM::propertyName( GEOM::Transparency ) ) ) { - double transparency = aPropMap.value(GEOM::propertyName( GEOM::Transparency )).toDouble(); - ic->SetTransparency( sh, transparency, true ); - } - } - } - } UpdateColorScale(false,false); } -- 2.39.2