13 #ifndef QmitkAbstractNodeSelectionWidget_h
14 #define QmitkAbstractNodeSelectionWidget_h
55 QString GetInvalidInfo()
const;
56 QString GetEmptyInfo()
const;
57 QString GetPopUpTitel()
const;
58 QString GetPopUpHint()
const;
60 bool GetSelectionIsOptional()
const;
62 bool GetSelectOnlyVisibleNodes()
const;
64 using NodeList = QList<mitk::DataNode::Pointer>;
80 void CurrentSelectionChanged(
NodeList nodes);
94 void SetSelectOnlyVisibleNodes(
bool selectOnlyVisibleNodes);
108 void SetCurrentSelection(
NodeList selectedNodes);
114 void SetInvalidInfo(QString info);
120 void SetEmptyInfo(QString info);
125 void SetPopUpTitel(QString info);
130 void SetPopUpHint(QString info);
135 void SetSelectionIsOptional(
bool isOptional);
146 virtual void UpdateInfo() = 0;
152 virtual void OnNodePredicateChanged();
157 virtual void OnDataStorageChanged();
162 virtual void OnInternalSelectionChanged();
174 virtual void OnNodeRemovedFromStorage(
const mitk::DataNode* node);
183 virtual void OnNodeModified(
const itk::Object* caller,
const itk::EventObject& event);
191 void HandleChangeOfInternalSelection(
NodeList newInternalSelection);
196 NodeList CompileEmitSelection()
const;
203 virtual void ReviseSelectionChanged(
const NodeList& oldInternalSelection,
NodeList& newInternalSelection);
210 virtual bool AllowEmissionOfSelection(
const NodeList& emissionCandidates)
const;
215 void EmitSelection(
const NodeList& emissionCandidates);
217 void SetCurrentInternalSelection(
NodeList selectedNodes);
218 const NodeList& GetCurrentInternalSelection()
const;
219 const NodeList& GetCurrentExternalSelection()
const;
236 void SetDataStorageDeleted();
251 unsigned long m_DataStorageDeletedTag;
253 NodeList m_CurrentInternalSelection;
254 NodeList m_CurrentExternalSelection;
257 bool m_LastEmissionAllowance;
259 using NodeObserverTagMapType = std::map<const mitk::DataNode*, unsigned long>;
260 NodeObserverTagMapType m_NodeObserverTags;
263 bool m_RecursionGuard;