API Documentation
Loading...
Searching...
No Matches
MainWindow.h
Go to the documentation of this file.
1/*--------------------------------------------------------------------------------------------
2Copyright (c) 2019, NDEVR LLC
3tyler.parke@ndevr.org
4 __ __ ____ _____ __ __ _______
5 | \ | | | __ \ | ___|\ \ / / | __ \
6 | \ | | | | \ \ | |___ \ \ / / | |__) |
7 | . \| | | |__/ / | |___ \ V / | _ /
8 | |\ |_|_____/__|_____|___\_/____| | \ \
9 |__| \__________________________________| \__\
10
11Subject to the terms of the Enterprise+ Agreement, NDEVR hereby grants
12Licensee a limited, non-exclusive, non-transferable, royalty-free license
13(without the right to sublicense) to use the API solely for the purpose of
14Licensee's internal development efforts to develop applications for which
15the API was provided.
16
17The above copyright notice and this permission notice shall be included in all
18copies or substantial portions of the Software.
19
20THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
21INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
22PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE
23FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
24OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
25DEALINGS IN THE SOFTWARE.
26
27Library: NDEVR
28File: MainWindow
29Included in API: True
30Author(s): Tyler Parke
31 *-----------------------------------------------------------------------------------------**/
32#pragma once
33#include <NDEVR/NDEVRWindow.h>
34#include <NDEVR/GettingStartedDialog.h>
35#include <NDEVR/QCustomDockWidget.h>
36#include <NDEVR/BaseValues.h>
37
38#if NDEVR_VIEWPORT
39namespace NDEVR
40{
41 class QTWindowManager;
42 class NDEVRRibbon;
43 class GettingStartedDialog;
44 class QTModelManager;
45 class CameraPane;
46 class MainWindow;
47 class MainWindowPopupWidget : public QWidget
48 {
49 MainWindowPopupWidget(MainWindow* window);
50 virtual void resizeEvent(QResizeEvent* event);
51 MainWindow* m_window;
52 QTimer* m_resize_timer;
53 };
54 class MainWindow : public NDEVRWindow
55 {
56 public:
57 MainWindow(QTModelManager* model_manager, QTWindowManager* window_manager, QWidget* parent = nullptr);
58 MainWindow(uint04 desktop_index, QTModelManager* model_manager, QTWindowManager* window_manager, QWidget* parent = nullptr);
59 ~MainWindow();
60 void init(QTModelManager* model_manager, QTWindowManager* window_manager);
61 void resizeEvent(QResizeEvent *event) override;
62 void moveEvent(QMoveEvent* event) override;
63 bool event(QEvent* event) override;
64 NDEVRRibbon* ribbon() { return m_ribbon; };
65 DockWidget<GettingStartedDialog>* home() { return m_home; };
66 DockWidget<CameraPane>* cameraPane() {return m_camera_pane; }
67 ContainerWidget* container() { return m_container_widget; };
68 void setPopupPosition();
69 virtual void keyReleaseEvent(QKeyEvent* event) override;
70 virtual void closeEvent(QCloseEvent *event) override;
71 virtual void hideEvent(QHideEvent* event) override;
72 virtual void showEvent(QShowEvent* event) override;
73 void addBottomWidget(QWidget* widget);
74 void removeBottomWidget(QWidget* widget);
75 void beginReset();
76 void removeFromResetShow(UUID id);
77 void endReset();
78 void updateModified();
79 QSize minimumSizeHint() const override;
80 protected:
81 ContainerWidget* m_container_widget;
82 NDEVRRibbon* m_ribbon;
83 DockWidget<GettingStartedDialog>* m_home;
84 QTWindowManager* m_window_manager;
85 QTModelManager* m_model_manager;
86 DockWidget<CameraPane>* m_camera_pane;
87 Buffer<Buffer<QPointer<FloatingWidget>>> m_reset_fullscreen_stack;
88 QWidget* m_popup_widget;
89 };
90}
91#endif
Definition ACIColor.h:37