17 #ifndef QMITKABSTRACTVIEW_H_
18 #define QMITKABSTRACTVIEW_H_
44 #include <QItemSelectionModel>
51 struct IBerryPreferences;
54 class QmitkAbstractViewPrivate;
55 class QmitkAbstractViewSelectionProvider;
118 BRING_TO_FRONT = 0x00000001,
120 ACTIVATE = 0x00000002,
125 Q_DECLARE_FLAGS(IRenderWindowPartStrategies, IRenderWindowPartStrategy)
141 virtual ~QmitkAbstractView();
151 void FireNodeSelected(
mitk::DataNode::
Pointer node);
159 virtual
void FireNodesSelected(const QList<
mitk::DataNode::
Pointer>& nodes);
167 QList<
mitk::DataNode::
Pointer> GetCurrentSelection() const;
175 bool IsCurrentSelectionValid() const;
183 QList<
mitk::DataNode::
Pointer> GetDataManagerSelection() const;
191 bool IsDataManagerSelectionValid() const;
200 QItemSelectionModel::SelectionFlags flags = QItemSelectionModel::ClearAndSelect) const;
206 void SynchronizeDataManagerSelection() const;
218 mitk::IDataStorageReference::
Pointer GetDataStorageReference() const;
232 mitk::IRenderWindowPart* GetRenderWindowPart(IRenderWindowPartStrategies strategies = NONE) const;
240 void RequestRenderWindowUpdate(
mitk::RenderingManager::RequestType requestType =
mitk::RenderingManager::REQUEST_UPDATE_ALL);
249 void HandleException(
std::exception& e, QWidget* parent =
nullptr,
bool showDialog = true ) const;
255 void HandleException( const
char* str, QWidget* parent =
nullptr,
bool showDialog = true ) const;
265 void WaitCursorOff();
275 void BusyCursorOff();
280 void RestoreOverrideCursor();
291 virtual
void SetSelectionProvider();
305 virtual QItemSelectionModel* GetDataNodeSelectionModel() const;
316 virtual
void OnSelectionChanged(
berry::IWorkbenchPart::
Pointer part, const QList<
mitk::DataNode::
Pointer> &nodes);
323 virtual
void OnNullSelection(
berry::IWorkbenchPart::
Pointer part);
331 virtual
void OnPreferencesChanged(const
berry::IBerryPreferences*);
337 virtual
void NodeAdded(const
mitk::DataNode* node);
343 virtual
void NodeChanged(const
mitk::DataNode* node);
349 virtual
void NodeRemoved(const
mitk::DataNode* node);
357 virtual
void DataStorageModified();
365 virtual
void DataStorageChanged(
mitk::IDataStorageReference::
Pointer dsRef);
370 void CreatePartControl(QWidget* parent) override;
376 void AfterCreateQtPartControl();
380 friend class QmitkAbstractViewPrivate;
381 friend class QmitkViewCoordinator;
383 Q_DISABLE_COPY(QmitkAbstractView)
385 const QScopedPointer<QmitkAbstractViewPrivate> d;
389 Q_DECLARE_OPERATORS_FOR_FLAGS(QmitkAbstractView::IRenderWindowPartStrategies)
itk::SmartPointer< Self > Pointer
DataCollection - Class to facilitate loading/accessing structured data.
static mitk::DataStorage::Pointer GetDataStorage()
itk::SmartPointer< const Self > ConstPointer
#define berryObjectMacro(...)
A convenient base class for MITK related BlueBerry Views.
IRenderWindowPartStrategy