From 7385205cc938ad0b6467b990184ba106182d4b44 Mon Sep 17 00:00:00 2001 From: srn Date: Thu, 16 Jun 2005 07:33:54 +0000 Subject: [PATCH] BugID IPAL8996, fixed method getTrihedronSize --- src/SOCC/SOCC_ViewModel.cxx | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) 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; -- 2.39.2