From a2c77adccc321c607e829f2e415aa58d898cafb9 Mon Sep 17 00:00:00 2001 From: eap Date: Thu, 19 May 2005 12:45:25 +0000 Subject: [PATCH] CheckActiveStudyLock() in accept() Do not renderViewFrame() in destructor set step of Position spin to range/10 --- src/VISUGUI/VisuGUI_Plot3DDlg.cxx | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/src/VISUGUI/VisuGUI_Plot3DDlg.cxx b/src/VISUGUI/VisuGUI_Plot3DDlg.cxx index 0a912cbb..3058bc45 100644 --- a/src/VISUGUI/VisuGUI_Plot3DDlg.cxx +++ b/src/VISUGUI/VisuGUI_Plot3DDlg.cxx @@ -256,7 +256,6 @@ VisuGUI_Plot3DPane::~VisuGUI_Plot3DPane() myViewFrame->RemoveActor( myPreviewActor ); myPreviewActor->Delete(); } - renderViewFrame( myStudyFrame->getStudy() ); } //======================================================================= @@ -346,8 +345,13 @@ void VisuGUI_Plot3DPane::onRelativePos( bool isRelativePos ) else // relative -> absolute pos = minPos * ( 1. - pos ) + maxPos * pos; } - PositionSpn->setMinValue( isRelativePos ? 0. : minPos ); - PositionSpn->setMaxValue( isRelativePos ? 1. : maxPos ); + if ( isRelativePos ) { + minPos = 0.; + maxPos = 1.; + } + PositionSpn->setMinValue( minPos ); + PositionSpn->setMaxValue( maxPos ); + PositionSpn->setLineStep(( maxPos - minPos ) / 10. ); PositionSpn->setValue( pos ); } @@ -571,6 +575,10 @@ VisuGUI_Plot3DDlg::VisuGUI_Plot3DDlg() void VisuGUI_Plot3DDlg::accept() { + if ( !VisuGUI::CheckActiveStudyLock() ) { + reject(); + return; + } if (myIsoPane->check() && myScalarPane->check()) { if ( !isModal() ) { VISU::Plot3D_i* prs = myIsoPane->GetPrs(); -- 2.39.2