NifTK  16.4.1 - 0798f20
CMIC's Translational Medical Imaging Platform
niftkDataSourcesView.h
Go to the documentation of this file.
1 /*=============================================================================
2 
3  NifTK: A software platform for medical image computing.
4 
5  Copyright (c) University College London (UCL). All rights reserved.
6 
7  This software is distributed WITHOUT ANY WARRANTY; without even
8  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
9  PURPOSE.
10 
11  See LICENSE.txt in the top level directory for details.
12 
13 =============================================================================*/
14 
15 #ifndef DataSourcesView_h
16 #define DataSourcesView_h
17 
18 #include <niftkBaseView.h>
19 #include <niftkIGIDataType.h>
21 #include <berryIBerryPreferences.h>
22 #include <ctkDictionary.h>
23 #include <service/event/ctkEvent.h>
24 
25 namespace niftk
26 {
27 
34 {
39  Q_OBJECT
40 
41 public:
42 
44  virtual ~DataSourcesView();
45 
49  static const std::string VIEW_ID;
50 
54  virtual std::string GetViewID() const;
55 
56 protected:
57 
61  virtual void CreateQtPartControl(QWidget *parent) override;
62 
66  virtual void SetFocus() override;
67 
68 signals:
69 
73  void Updated(const ctkDictionary&);
74 
78  void RecordingStarted(const ctkDictionary&);
79 
80 protected slots:
81 
83  void OnUpdateShouldPause(const ctkEvent& event);
84  void OnUpdateShouldRestart(const ctkEvent& event);
85 
86 protected:
87 
88 private slots:
89 
93  void OnUpdateGuiEnd(niftk::IGIDataType::IGITimeType timeStamp);
94 
98  void OnRecordingStarted(QString baseDirectory);
99 
100 private:
101 
105  void RetrievePreferenceValues();
106 
110  virtual void OnPreferencesChanged(const berry::IBerryPreferences*) override;
111 
112  niftk::IGIDataSourceManagerWidget* m_DataSourceManagerWidget;
113  bool m_SetupWasCalled;
114 };
115 
116 } // end namespace
117 
118 #endif // DataSourcesView_h
virtual void CreateQtPartControl(QWidget *parent) override
Called by framework, this method creates all the controls for this view.
Definition: niftkDataSourcesView.cxx:104
User interface to provide Image Guided Surgery functionality.
Definition: niftkDataSourcesView.h:33
SystemTimeServiceI::TimeType IGITimeType
Definition: niftkIGIDataType.h:39
virtual ~DataSourcesView()
Definition: niftkDataSourcesView.cxx:38
Widget class to manage a list of IGIDataSources (trackers, ultra-sound machines, video etc)...
Definition: niftkIGIDataSourceManagerWidget.h:37
void OnUpdateShouldRestart(const ctkEvent &event)
Definition: niftkDataSourcesView.cxx:75
void RecordingStarted(const ctkDictionary &)
CTK-bus equivalent of IGIDataSourceManager's RecordingStarted. Topic is "uk/ac/ucl/cmic/IGIRECORDINGS...
void OnUpdateShouldPause(const ctkEvent &event)
Definition: niftkDataSourcesView.cxx:67
DataSourcesView()
Definition: niftkDataSourcesView.cxx:30
static const std::string VIEW_ID
Static view ID = uk.ac.ucl.cmic.igidatasources.
Definition: niftkDataSourcesView.h:49
Base view component for plugins listening to visibility change events, focus changed events and so on...
Definition: niftkBaseView.h:47
void Updated(const ctkDictionary &)
We publish an update signal on topic "uk/ac/ucl/cmic/IGIUPDATE" onto the Event Bus so that any other ...
virtual void SetFocus() override
Called by framework, sets the focus on a specific widget.
Definition: niftkDataSourcesView.cxx:97
virtual std::string GetViewID() const
Returns the view ID.
Definition: niftkDataSourcesView.cxx:90
cl_event event
Definition: glew.h:3231
Definition: niftkExceptionObject.h:21
GLsizei const GLcharARB ** string
Definition: glew.h:5194