From: srn Date: Thu, 16 Jun 2005 07:33:54 +0000 (+0000) Subject: BugID IPAL8996, fixed method getTrihedronSize X-Git-Tag: T3_0_0_a4~109 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=7385205cc938ad0b6467b990184ba106182d4b44;p=modules%2Fgui.git BugID IPAL8996, fixed method getTrihedronSize --- diff --git a/src/SOCC/SOCC_ViewModel.cxx b/src/SOCC/SOCC_ViewModel.cxx index 86d97ff67..c21735bba 100755 --- a/src/SOCC/SOCC_ViewModel.cxx +++ b/src/SOCC/SOCC_ViewModel.cxx @@ -550,7 +550,13 @@ bool SOCC_Viewer::getTrihedronSize( double& theNewSize, double& theSize ) theNewSize = 100; theSize = 100; - Handle(V3d_View) view3d = getViewer3d()->ActiveView(); + //SRN: BUG IPAL8996, a usage of method ActiveView without an initialization + Handle(V3d_Viewer) viewer = getViewer3d(); + viewer->InitActiveViews(); + if(!viewer->MoreActiveViews()) return false; + + Handle(V3d_View) view3d = viewer->ActiveView(); + //SRN: END of fix if ( view3d.IsNull() ) return false;