Medical Imaging Interaction Toolkit  2018.4.99-3e3f1a6e
Medical Imaging Interaction Toolkit
berryIWorkbench.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 BERRYIWORKBENCH_H_
14 #define BERRYIWORKBENCH_H_
15 
16 #include <berryMacros.h>
17 
19 #include "berryIViewRegistry.h"
20 #include "berryIEditorRegistry.h"
23 #include "berryIWorkbenchWindow.h"
25 #include "berryIWindowListener.h"
26 #include "berryDisplay.h"
27 
28 namespace berry {
29 
30 struct IElementFactory;
31 struct IExtensionTracker;
32 struct IWorkbenchPage;
33 
83 
85 
86  ~IWorkbench() override;
87 
98  virtual Display* GetDisplay() const = 0;
99 
107  virtual void AddWorkbenchListener(IWorkbenchListener* listener) = 0;
108 
116  virtual void RemoveWorkbenchListener(IWorkbenchListener* listener) = 0;
117 
121  virtual IWorkbenchListener::Events& GetWorkbenchEvents() = 0;
122 
130  virtual void AddWindowListener(IWindowListener* listener) = 0;
131 
139  virtual void RemoveWindowListener(IWindowListener* listener) = 0;
140 
145  virtual IWindowListener::Events& GetWindowEvents() = 0;
146 
157  virtual bool Close() = 0;
158 
167  virtual IWorkbenchWindow::Pointer GetActiveWorkbenchWindow() const = 0;
168 
182  virtual IExtensionTracker* GetExtensionTracker() const = 0;
183 
189  virtual IPerspectiveRegistry* GetPerspectiveRegistry() const = 0;
190 
197  virtual IViewRegistry* GetViewRegistry() const = 0;
198 
204  virtual IEditorRegistry* GetEditorRegistry() const = 0;
205 
214  virtual std::size_t GetWorkbenchWindowCount() const = 0;
215 
223  virtual QList<IWorkbenchWindow::Pointer> GetWorkbenchWindows() const = 0;
224 
256  virtual IWorkbenchWindow::Pointer OpenWorkbenchWindow(const QString& perspectiveId,
257  IAdaptable* input) = 0;
258 
281  virtual IWorkbenchWindow::Pointer OpenWorkbenchWindow(IAdaptable* input) = 0;
282 
322  virtual SmartPointer<IWorkbenchPage> ShowPerspective(const QString& perspectiveId,
323  IWorkbenchWindow::Pointer window) = 0;
324 
368  virtual SmartPointer<IWorkbenchPage> ShowPerspective(const QString& perspectiveId,
369  IWorkbenchWindow::Pointer window, IAdaptable* input) = 0;
370 
383  virtual bool SaveAllEditors(bool confirm) = 0;
384 
394  virtual IElementFactory* GetElementFactory(const QString& factoryId) const = 0;
395 
402  virtual IIntroManager* GetIntroManager() const = 0;
403 
412  virtual bool IsClosing() const = 0;
413 
417  virtual void UpdateTheme() = 0;
418 
419 };
420 
421 }
422 
423 #endif /*BERRYIWORKBENCH_H_*/
#define berryObjectMacro(...)
Definition: berryMacros.h:33
#define BERRY_UI_QT