]> Creatis software - clitk.git/blobdiff - vv/vvInteractorStyleNavigator.cxx
Change in headers order
[clitk.git] / vv / vvInteractorStyleNavigator.cxx
index e161cc08c24758f0e73dec236e42960e8808101e..ac37a8fd22c95442157365a2a03ad3409d662ed1 100644 (file)
@@ -3,7 +3,7 @@
 
   Authors belong to:
   - University of LYON              http://www.universite-lyon.fr/
-  - Léon Bérard cancer center       http://oncora1.lyon.fnclcc.fr
+  - Léon Bérard cancer center       http://www.centreleonberard.fr
   - CREATIS CNRS laboratory         http://www.creatis.insa-lyon.fr
 
   This software is distributed WITHOUT ANY WARRANTY; without even
@@ -14,7 +14,7 @@
 
   - BSD        See included LICENSE.txt file
   - CeCILL-B   http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html
-======================================================================-====*/
+===========================================================================**/
 #include "vvInteractorStyleNavigator.h"
 
 #include "vtkAbstractPropPicker.h"
@@ -249,7 +249,10 @@ void vvInteractorStyleNavigator::OnLeftButtonDown()
 
   // Redefine this button to handle pick
   this->GrabFocus(this->EventCallbackCommand);
-  if (!this->Interactor->GetShiftKey() && !this->Interactor->GetControlKey()) {
+  if (this->Interactor->GetShiftKey()) {
+    this->OnMiddleButtonDown();
+  }
+  else if (!this->Interactor->GetControlKey()) {
     this->StartPick();
   }
 
@@ -271,6 +274,9 @@ void vvInteractorStyleNavigator::OnLeftButtonUp()
       this->ReleaseFocus();
     }
     break;
+  case VTKIS_PAN:
+    this->OnMiddleButtonUp();
+    break;
   }
 
   // Call parent to handle all other states and perform additional work
@@ -472,7 +478,9 @@ void vvInteractorStyleNavigator::Pan()
     this->CurrentRenderer->UpdateLightsGeometryToFollowCamera();
   }
 
-  rwi->Render();
+  this->InvokeEvent(vtkCommand::EndInteractionEvent, this);
+
+//  rwi->Render();
 }
 
 //----------------------------------------------------------------------------
@@ -557,6 +565,8 @@ void vvInteractorStyleNavigator::Dolly(double factor)
   }
   this->CurrentRenderer->ResetCameraClippingRange();
   //this->Interactor->Render();
+
+  this->InvokeEvent(vtkCommand::EndInteractionEvent, this);
 }