From 4f7a9d542961ae1241d7de9111b327689e460135 Mon Sep 17 00:00:00 2001 From: jfa Date: Thu, 27 Oct 2005 13:58:54 +0000 Subject: [PATCH] Fix for bug 9929: Signal 8 detected on RestoreViewParameters() in the second study --- src/VISU_I/VISU_ViewManager_i.cc | 6 +++++- src/VISU_I/VISU_View_i.cc | 11 +++++------ 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/src/VISU_I/VISU_ViewManager_i.cc b/src/VISU_I/VISU_ViewManager_i.cc index 4c6c97e0..cb396ceb 100644 --- a/src/VISU_I/VISU_ViewManager_i.cc +++ b/src/VISU_I/VISU_ViewManager_i.cc @@ -56,6 +56,8 @@ #include #include +#include + using namespace std; #ifdef _DEBUG_ @@ -177,8 +179,10 @@ namespace VISU { //if (CheckStudy(myStudyDocument)) { if (myApplication) { TViewFrame* pView = new TViewFrame (myApplication); - if (pView->Create(1)) + if (pView->Create(1)) { myResult = pView->_this(); + qApp->processEvents(); // Fix for bug 9929 + } } } }; diff --git a/src/VISU_I/VISU_View_i.cc b/src/VISU_I/VISU_View_i.cc index e655eac9..20e75cf1 100644 --- a/src/VISU_I/VISU_View_i.cc +++ b/src/VISU_I/VISU_View_i.cc @@ -1334,7 +1334,7 @@ namespace VISU { const int mode, const double xMin, const double xMax, const double yMin, const double yMax): - myView(theView), + myView(theView), myMode(mode), myXMin(xMin),myXMax(xMax), myYMin(yMin),myYMax(yMax) @@ -1351,7 +1351,7 @@ namespace VISU { const double myYMax; Plot2d_ViewFrame* myView; }; - + void XYPlot_i::FitXRange(const CORBA::Double xMin,const CORBA::Double xMax) { const CORBA::Long mode = 1; @@ -1374,7 +1374,7 @@ namespace VISU { const CORBA::Long mode = 0; ProcessVoidEvent(new TFitRangeEvent(myView,mode,xMin,xMax,yMin,yMax)); } - + void XYPlot_i::GetFitRanges(double& xMin, double& xMax, double& yMin, double& yMax) { double y2Min,y2Max; @@ -1730,9 +1730,8 @@ namespace VISU { SetViewUp(theViewWindow,aViewUp); SetFocalPoint(theViewWindow,aFocalPnt); SetParallelScale(theViewWindow,aParallelScale); - ScaleView(theViewWindow,VISU::View3D::XAxis,aScaleFactor[0]); - ScaleView(theViewWindow,VISU::View3D::YAxis,aScaleFactor[1]); - ScaleView(theViewWindow,VISU::View3D::ZAxis,aScaleFactor[2]); + SVTK_ViewWindow* aViewWindow = VISU::GetViewWindow(theViewWindow); + aViewWindow->SetScale(aScaleFactor); } -- 2.39.2