From: Ricardo Corredor Date: Fri, 2 Apr 2010 07:22:25 +0000 (+0000) Subject: changes in vtkInteractorStyleBaseView2D. Check out the constructor of this class... X-Git-Tag: CREATOOLS.2-0-3~42 X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;h=0e9c6cea471e235717da5cac8b924254ed3f4f75;p=creaMaracasVisu.git changes in vtkInteractorStyleBaseView2D. Check out the constructor of this class for more information --- diff --git a/lib/maracasVisuLib/src/CutModule/kernel/CutModelManager.cxx b/lib/maracasVisuLib/src/CutModule/kernel/CutModelManager.cxx index 023b9d8..bfd82ed 100644 --- a/lib/maracasVisuLib/src/CutModule/kernel/CutModelManager.cxx +++ b/lib/maracasVisuLib/src/CutModule/kernel/CutModelManager.cxx @@ -3,8 +3,8 @@ Program: wxMaracas Module: $RCSfile: CutModelManager.cxx,v $ Language: C++ -Date: $Date: 2010/03/04 15:09:57 $ -Version: $Revision: 1.8 $ +Date: $Date: 2010/04/02 07:22:25 $ +Version: $Revision: 1.9 $ Copyright: (c) 2002, 2003 License: @@ -357,7 +357,7 @@ void CutModelManager::UpdatePolygon(bool mode) _polygonCutter = new CutModelPolygon(); - cout<<"RaC ContourDrawer::Update Printing points"< GetVtkImageViewer2() -> SetupInteractor ( iren ); - SetInteractorStyleImage( vtkInteractorStyleBaseView2D::New() ); + ////////////// + //RaC 04-2010 Look for the description of new changes in vtkInteractorStyleBaseView2D constructor. + // + // Previous version + // SetInteractorStyleImage( vtkInteractorStyleBaseView2D::New() ); + // + // Actual version + vtkInteractorStyleBaseView2D *style2D = vtkInteractorStyleBaseView2D::New(); + + manualInteractorWindowLevel *_manualinteractorwindowlevel= new manualInteractorWindowLevel(); + style2D->SetInteractorWindowLevel( _manualinteractorwindowlevel ); + + vtkInteractorScrollZ *_vtkInteractorScrollZ = new vtkInteractorScrollZ(); + style2D->SetInteractorScrollZ(_vtkInteractorScrollZ); + + SetInteractorStyleImage( style2D ); + + // RaC + ////////////// _interactorstyleplane2D = new vtkInteractorStylePlane2D(); ((vtkInteractorStyleBaseView*)GetInteractorStyleBaseView())->AddInteractorStyleMaracas( _interactorstyleplane2D ); diff --git a/lib/maracasVisuLib/src/interface/wxWindows/widgets/wxVtk2DBaseView.cxx b/lib/maracasVisuLib/src/interface/wxWindows/widgets/wxVtk2DBaseView.cxx index 33accb3..e703115 100644 --- a/lib/maracasVisuLib/src/interface/wxWindows/widgets/wxVtk2DBaseView.cxx +++ b/lib/maracasVisuLib/src/interface/wxWindows/widgets/wxVtk2DBaseView.cxx @@ -75,7 +75,26 @@ void wxVtk2DBaseView::ResetView() _imageViewer2XYZ -> GetVtkImageViewer2()->SetupInteractor ( iren ); _imageViewer2XYZ->GetVtkImageViewer2()->Render(); - SetInteractorStyleImage( vtkInteractorStyleBaseView2D::New() ); + + ////////////// + //RaC 04-2010 Look for the description of new changes in vtkInteractorStyleBaseView2D constructor. + // + // Previous version + // SetInteractorStyleImage( vtkInteractorStyleBaseView2D::New() ); + // + // Actual version + vtkInteractorStyleBaseView2D *style2D = vtkInteractorStyleBaseView2D::New(); + + manualInteractorWindowLevel *_manualinteractorwindowlevel= new manualInteractorWindowLevel(); + style2D->SetInteractorWindowLevel( _manualinteractorwindowlevel ); + + vtkInteractorScrollZ *_vtkInteractorScrollZ = new vtkInteractorScrollZ(); + style2D->SetInteractorScrollZ(_vtkInteractorScrollZ); + + SetInteractorStyleImage( style2D ); + + // RaC + ////////////// } @@ -93,7 +112,27 @@ void wxVtk2DBaseView::Configure(bool okimage) _imageViewer2XYZ = new vtkImageViewer2_XYZ(); wxVTKRenderWindowInteractor *iren = GetWxVTKRenderWindowInteractor(); _imageViewer2XYZ -> GetVtkImageViewer2()->SetupInteractor ( iren ); - SetInteractorStyleImage( vtkInteractorStyleBaseView2D::New() ); + + ////////////// + //RaC 04-2010 Look for the description of new changes in vtkInteractorStyleBaseView2D constructor. + // + // Previous version + // SetInteractorStyleImage( vtkInteractorStyleBaseView2D::New() ); + // + // Actual version + vtkInteractorStyleBaseView2D *style2D = vtkInteractorStyleBaseView2D::New(); + + manualInteractorWindowLevel *_manualinteractorwindowlevel= new manualInteractorWindowLevel(); + style2D->SetInteractorWindowLevel( _manualinteractorwindowlevel ); + + vtkInteractorScrollZ *_vtkInteractorScrollZ = new vtkInteractorScrollZ(); + style2D->SetInteractorScrollZ(_vtkInteractorScrollZ); + + SetInteractorStyleImage( style2D ); + + // RaC + ////////////// + }