Medical Imaging Interaction Toolkit
2016.11.0
Medical Imaging Interaction Toolkit
|
Helper class to allow QmitkAbstractView and derived classes to react on changes of the slice/time navigation. Purpose of the class to be used in view and to give the respective view class (by composition) the posibility to react on changes of the currently selected timepoint or position in the world geometry.
In order to setup this class properly the following things must be regarded:
More...
#include <QmitkSliceNavigationListener.h>
Classes | |
struct | ObserverInfo |
Public Slots | |
void | RenderWindowPartActivated (mitk::IRenderWindowPart *renderWindowPart) |
void | RenderWindowPartDeactivated (mitk::IRenderWindowPart *renderWindowPart) |
Signals | |
void | SliceChanged () |
Public Member Functions | |
QmitkSliceNavigationListener () | |
More... | |
virtual | ~QmitkSliceNavigationListener () |
Protected Types | |
typedef std::multimap< const mitk::SliceNavigationController *, ObserverInfo > | ObserverMapType |
Protected Slots | |
void | OnSliceChangedDelayed () |
Protected Member Functions | |
void | OnSliceChangedInternal (const itk::EventObject &e) |
Calls OnSliceChangedDelayed so the event isn't triggered multiple times. More... | |
void | OnSliceNavigationControllerDeleted (const itk::Object *sender, const itk::EventObject &) |
bool | InitObservers () |
void | RemoveObservers (const mitk::SliceNavigationController *deletedSlicer) |
void | RemoveAllObservers (mitk::IRenderWindowPart *deletedPart=NULL) |
Protected Attributes | |
mitk::IRenderWindowPart * | m_renderWindowPart |
bool | m_PendingSliceChangedEvent |
ObserverMapType | m_ObserverMap |
bool | m_internalUpdateFlag |
Is a visualization currently running? More... | |
Helper class to allow QmitkAbstractView and derived classes to react on changes of the slice/time navigation. Purpose of the class to be used in view and to give the respective view class (by composition) the posibility to react on changes of the currently selected timepoint or position in the world geometry.
In order to setup this class properly the following things must be regarded:
View class must implement void RenderWindowPartActivated(mitk::IRenderWindowPart* renderWindowPart) and pass the renderWindowPart to the listener.
void QmitkMyView::RenderWindowPartActivated(mitk::IRenderWindowPart* renderWindowPart) { this->m_SliceNavigationListener.RenderWindowPartActivated(renderWindowPart); }
View class must implement void RenderWindowPartDeactivated(mitk::IRenderWindowPart* renderWindowPart) and pass the renderWindowPart to the listener.
void QmitkMyView::RenderWindowPartDeactivated(mitk::IRenderWindowPart* renderWindowPart) { this->m_SliceNavigationListener.RenderWindowPartDeactivated(renderWindowPart); }
View class must pass its on render window part in its CreateQtPartControl(QWidget* parent)
this->m_SliceNavigationListener.RenderWindowPartActivated(this->GetRenderWindowPart());
Definition at line 64 of file QmitkSliceNavigationListener.h.
|
protected |
Definition at line 114 of file QmitkSliceNavigationListener.h.
QmitkSliceNavigationListener::QmitkSliceNavigationListener | ( | ) |
Definition at line 29 of file QmitkSliceNavigationListener.cpp.
|
virtual |
Definition at line 35 of file QmitkSliceNavigationListener.cpp.
References RemoveAllObservers().
|
protected |
Initializes and sets the observers that are used to monitor changes in the selected position or time point in order to actualize the view.h
Definition at line 90 of file QmitkSliceNavigationListener.cpp.
References mitk::IRenderWindowPart::GetQmitkRenderWindows(), m_ObserverMap, m_renderWindowPart, mitk::New(), OnSliceChangedInternal(), and OnSliceNavigationControllerDeleted().
Referenced by RenderWindowPartActivated().
|
protectedslot |
Overwrite function to implement the behavior on slice/time changes.
Definition at line 40 of file QmitkSliceNavigationListener.cpp.
References m_PendingSliceChangedEvent, and SliceChanged().
Referenced by OnSliceChangedInternal().
|
protected |
Calls OnSliceChangedDelayed so the event isn't triggered multiple times.
Definition at line 47 of file QmitkSliceNavigationListener.cpp.
References m_PendingSliceChangedEvent, and OnSliceChangedDelayed().
Referenced by InitObservers().
|
protected |
Definition at line 61 of file QmitkSliceNavigationListener.cpp.
References RemoveObservers().
Referenced by InitObservers().
|
protected |
Removes all observers of the deletedPart. If null pointer is passed all observers will be removed.
Definition at line 158 of file QmitkSliceNavigationListener.cpp.
References m_ObserverMap.
Referenced by RenderWindowPartDeactivated(), and ~QmitkSliceNavigationListener().
|
protected |
Definition at line 145 of file QmitkSliceNavigationListener.cpp.
References m_ObserverMap.
Referenced by OnSliceNavigationControllerDeleted().
|
slot |
Definition at line 69 of file QmitkSliceNavigationListener.cpp.
References InitObservers(), and m_renderWindowPart.
|
slot |
Definition at line 84 of file QmitkSliceNavigationListener.cpp.
References m_renderWindowPart, and RemoveAllObservers().
|
signal |
Referenced by OnSliceChangedDelayed().
|
protected |
Is a visualization currently running?
Definition at line 118 of file QmitkSliceNavigationListener.h.
|
protected |
Definition at line 115 of file QmitkSliceNavigationListener.h.
Referenced by InitObservers(), RemoveAllObservers(), and RemoveObservers().
|
protected |
Definition at line 100 of file QmitkSliceNavigationListener.h.
Referenced by OnSliceChangedDelayed(), and OnSliceChangedInternal().
|
protected |
Definition at line 97 of file QmitkSliceNavigationListener.h.
Referenced by InitObservers(), RenderWindowPartActivated(), and RenderWindowPartDeactivated().