X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;ds=inline;f=vv%2FvvSlicerManagerCommand.cxx;h=b7c2b4669fff27f2a2bd4888ecf501b09d88b4d1;hb=bb4e897df61593efc572a27c1312e87bb1f13c6e;hp=5d252043bb0603c9f5f0f58419df63b9f0a3ff73;hpb=1e034c70105f0926939acaaa27ddb46e904ae8bf;p=clitk.git diff --git a/vv/vvSlicerManagerCommand.cxx b/vv/vvSlicerManagerCommand.cxx index 5d25204..b7c2b46 100644 --- a/vv/vvSlicerManagerCommand.cxx +++ b/vv/vvSlicerManagerCommand.cxx @@ -188,6 +188,14 @@ void vvSlicerManagerCommand::Execute(vtkObject *caller, this->SM->Render(); return; } + if (KeyPress == "x") { + for(int i=0; iNumberOfSlicers(); i++) { + SM->RemoveActor("overlay",0); + SM->SetColorMap(0); + SM->Render(); + } + return; + } if (KeyPress == "u") { this->SM->Reload(); this->SM->Render(); @@ -291,6 +299,10 @@ void vvSlicerManagerCommand::Execute(vtkObject *caller, mStartSlicer = -1; } + if (event == vtkCommand::EndInteractionEvent) { + this->SM->UpdateLinkedNavigation(this->SM->GetSlicer(VisibleInWindow),true); + return; + } } if (VisibleInWindow > -1) { this->SM->Activated(); @@ -304,6 +316,7 @@ void vvSlicerManagerCommand::Execute(vtkObject *caller, } else if (event == vtkCommand::MouseWheelForwardEvent && isi->GetInteractor()->GetControlKey()) { double factor = 2; this->Dolly(pow((double)1.1, factor),isi->GetInteractor()); + Execute(caller, vtkCommand::EndInteractionEvent, NULL); } else if (event == vtkCommand::MouseWheelBackwardEvent && !isi->GetInteractor()->GetControlKey()) { this->SM->GetSlicer(VisibleInWindow)->SetSlice(this->SM->GetSlicer(VisibleInWindow)->GetSlice()-1); this->SM->UpdateSlice(VisibleInWindow); @@ -311,6 +324,7 @@ void vvSlicerManagerCommand::Execute(vtkObject *caller, } else if (event == vtkCommand::MouseWheelBackwardEvent && isi->GetInteractor()->GetControlKey()) { double factor = -2; this->Dolly(pow((double)1.1, factor),isi->GetInteractor()); + Execute(caller, vtkCommand::EndInteractionEvent, NULL); } double xWorld=0; double yWorld=0;