Medical Imaging Interaction Toolkit  2018.4.99-389bf124
Medical Imaging Interaction Toolkit
QmitkDataStorageSelectionHistoryInspector.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 (DKFZ)
6 All rights reserved.
7 
8 Use of this source code is governed by a 3-clause BSD license that can be
9 found in the LICENSE file.
10 
11 ============================================================================*/
12 
13 #ifndef QMITKDATASTORAGESELECTIONHISTORYINSPECTOR_H
14 #define QMITKDATASTORAGESELECTIONHISTORYINSPECTOR_H
15 
16 #include <MitkQtWidgetsExports.h>
17 
19 #include <QSortFilterProxyModel>
21 
22 #include "ui_QmitkDataStorageSelectionHistoryInspector.h"
23 
24 /*
25 * @brief This is an inspector that offers a simple list view on the last selected nodes (in chronologic order) in a data storage.
26 */
28 {
29  Q_OBJECT
30 
31 public:
32  QmitkDataStorageSelectionHistoryInspector(QWidget* parent = nullptr);
33 
34  QAbstractItemView* GetView() override;
35  const QAbstractItemView* GetView() const override;
36 
37  void SetSelectionMode(SelectionMode mode) override;
38  SelectionMode GetSelectionMode() const override;
39 
40  static void AddNodeToHistory(mitk::DataNode* node);
41  static void ResetHistory();
42 
43  constexpr static const char* INSPECTOR_ID()
44  {
45  return "org.mitk.QmitkDataStorageSelectionHistoryInspector";
46  };
47 
48 protected:
49  void Initialize() override;
50 
52  Ui_QmitkDataStorageSelectionHistoryInspector m_Controls;
54 };
55 
56 #endif // QMITKDATASTORAGESELECTIONHISTORYINSPECTOR_H
virtual QAbstractItemView * GetView()=0
virtual SelectionMode GetSelectionMode() const =0
#define MITKQTWIDGETS_EXPORT
Ui_QmitkDataStorageSelectionHistoryInspector m_Controls
virtual void SetSelectionMode(SelectionMode mode)=0
QAbstractItemView::SelectionMode SelectionMode
This abstract class is a convenient base class for easy implementation of widgets that offer a specif...
Class for nodes of the DataTree.
Definition: mitkDataNode.h:57