X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=lib%2FmaracasVisuLib%2Fsrc%2Finterface%2FwxWindows%2Fwidgets%2FwxVtkMPR2DView.cxx;h=7632ba2a798995be18786ddca6b3c5222e1e5188;hb=c016f2efd20188d031f0bc29c5a2bb1aab959adf;hp=2163d69de9a5be80a0f129d68621af2bd42dee97;hpb=6e940f8b87d85a90438f01d56c3c6c92da2bc14a;p=creaMaracasVisu.git diff --git a/lib/maracasVisuLib/src/interface/wxWindows/widgets/wxVtkMPR2DView.cxx b/lib/maracasVisuLib/src/interface/wxWindows/widgets/wxVtkMPR2DView.cxx index 2163d69..7632ba2 100644 --- a/lib/maracasVisuLib/src/interface/wxWindows/widgets/wxVtkMPR2DView.cxx +++ b/lib/maracasVisuLib/src/interface/wxWindows/widgets/wxVtkMPR2DView.cxx @@ -19,6 +19,7 @@ wxVtkMPR2DView::wxVtkMPR2DView( wxWindow *parent, int direction) _lineBActor = NULL; _lineBMapper = NULL; _pdB = NULL; + _interactorstylemprview = NULL; } //------------------------------------------------------------------- @@ -42,8 +43,13 @@ vtkMPRBaseData *wxVtkMPR2DView::GetVtkmprbasedata() void wxVtkMPR2DView::Configure(){ wxVtk2DBaseView::Configure(); - _interactorstylemprview = new vtkInteractorStyleMPRView(); - ((vtkInteractorStyleBaseView*)GetInteractorStyleBaseView())->AddInteractorStyleMaracas( _interactorstylemprview ); + if(_interactorstylemprview==NULL) + { + _interactorstylemprview = new vtkInteractorStyleMPRView(); + ((vtkInteractorStyleBaseView*)GetInteractorStyleBaseView())->AddInteractorStyleMaracas( _interactorstylemprview ); + } + + int x1,x2,y1,y2,z1,z2; GetVtkmprbasedata() -> GetDimensionExtention(&x1,&x2,&y1,&y2,&z1,&z2);