Medical Imaging Interaction Toolkit  2016.11.0
Medical Imaging Interaction Toolkit
QmitkToolWorkingDataSelectionBox.h
Go to the documentation of this file.
1 /*===================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center,
6 Division of Medical and Biological Informatics.
7 All rights reserved.
8 
9 This software is distributed WITHOUT ANY WARRANTY; without
10 even the implied warranty of MERCHANTABILITY or FITNESS FOR
11 A PARTICULAR PURPOSE.
12 
13 See LICENSE.txt or http://www.mitk.org for details.
14 
15 ===================================================================*/
16 
17 #ifndef QmitkToolWorkingDataSelectionListBox_h_Included
18 #define QmitkToolWorkingDataSelectionListBox_h_Included
19 
20 // mmueller
22 #include <QListWidget>
23 
24 #include "mitkProperties.h"
25 #include "mitkToolManager.h"
26 
47 {
48  Q_OBJECT
49 
50 public:
62  {
64  ListDataIfAnyToolMatches
65  };
66 
67  QmitkToolWorkingDataSelectionBox(QWidget *parent = 0);
69 
71  void SetDataStorage(mitk::DataStorage &storage);
72 
76  void UpdateDataDisplay();
77 
81  mitk::ToolManager *GetToolManager();
82 
86  void SetToolManager(mitk::ToolManager &); // no NULL pointer allowed here, a manager is required
87 
93  mitk::ToolManager::DataVectorType GetAllNodes(bool onlyDerivedFromOriginal = true);
94 
100  mitk::ToolManager::DataVectorType GetSelectedNodes();
101 
107  mitk::DataNode *GetSelectedNode();
108 
113  void OnToolManagerWorkingDataModified();
114 
119  void OnToolManagerReferenceDataModified();
120 
121 signals:
122 
123  void WorkingNodeSelected(const mitk::DataNode *);
124 
125 protected slots:
126 
127  void OnWorkingDataSelectionChanged();
128 
129 protected:
130  typedef std::map<QListWidgetItem *, mitk::DataNode *> ItemNodeMapType;
131 
133 
134  ItemNodeMapType m_Node;
135 
137 
139 
141 
143 };
144 
145 #endif
Display the data selection of a ToolManager.
Data management class that handles 'was created by' relations.
itk::SmartPointer< Self > Pointer
std::vector< DataNode * > DataVectorType
static mitk::DataStorage::Pointer GetDataStorage()
std::map< QListWidgetItem *, mitk::DataNode * > ItemNodeMapType
DisplayMode
What kind of items should be displayed.
Class for nodes of the DataTree.
Definition: mitkDataNode.h:66
#define MITKSEGMENTATIONUI_EXPORT
Manages and coordinates instances of mitk::Tool.