API Documentation
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros
SettingsDialog.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: SettingsDialog
29Included in API: True
30Author(s): Tyler Parke
31 *-----------------------------------------------------------------------------------------**/
32#pragma once
33#include "DLLInfo.h"
34#include <NDEVR/Dictionary.h>
35#include <QWidget>
36namespace Ui
37{
38 class SettingsUI;
39}
40namespace NDEVR
41{
42 class FileChooserDialog;
43 class QTResourceListener;
44 class QTModelManager;
45 class UnitsDialog;
46 class MouseController;
47 class MouseEditorWidget;
48 class ModelFileDialog;
49 class PhysicalCameraViewSettings;
50 class WindowManager;
51 class LanguageEditor;
52 class RibbonSubGroup;
53 class Button;
54 class FileAndFolderSettingsDialog;
55 class KeystrokeWidget;
56 class ModulesDialog;
57 class NDEVR_API SettingsDialog : public QWidget
58 {
59 Q_OBJECT
60 public:
61 SettingsDialog(WindowManager* window_manager, QTModelManager* model_manager, QWidget* parent = nullptr);
62 void prepareToShow();
63 virtual ~SettingsDialog();
64 void addSettingsMenu(QWidget* menu, std::function<void()> reset_to_defaults, uint04 location = 1);
65 void removeSettingsMenu(QWidget* menu);
66 protected:
67 void setupMainTab();
68 void setupFolderTab();
69 void setupUITab();
70 void setupGraphicsTab();
71 void setupUnitsTab();
72 void setupImportTab();
73 void setupKeystrokeTab();
74 void updateImportSettingsRibbon();
75 void setupExportTab();
76 void updateExportSettingsRibbon();
77 void updateLayout();
78 void resetUIToDefaults();
79 void resetGeneralToDefaults();
80 void createBackground();
81 bool event(QEvent* event) override;
82 void setupStationTab();
83 void setupMouseSettingsTab();
84 void updateTabLocation();
85 signals:
87 protected:
88 void retranslate();
89 protected:
90 Ui::SettingsUI* ui;
91 ModulesDialog* m_modules_dialog = nullptr;
92 QTResourceListener* m_camera_background_listener= nullptr;
93 QTModelManager* m_model_manager= nullptr;
94 WindowManager* m_window_manager= nullptr;
95 UnitsDialog* m_units_dialog= nullptr;
96 LanguageEditor* m_language_editor= nullptr;
97 KeystrokeWidget* m_keystroke_widget= nullptr;
98 FileAndFolderSettingsDialog* m_file_and_folder_settings = nullptr;
99 MouseEditorWidget* m_mouse_editor= nullptr;
100 ModelFileDialog* m_import_settings_dialog = nullptr;
101 ModelFileDialog* m_export_settings_dialog = nullptr;
102 RibbonSubGroup* m_import_settings_ribbon_group = nullptr;
103 RibbonSubGroup* m_export_settings_ribbon_group = nullptr;
104 Dictionary<QWidget*, std::function<void()>> m_reset_to_default_settings;
105 bool m_shown_to_user = false;
106 };
107}
#define NDEVR_API
Definition DLLInfo.h:67
Definition Dictionary.h:48
Definition FileAndFolderSettingsDialog.h:15
Definition KeystrokeWidget.h:15
Definition LanguageEditor.h:32
Definition ModelFileDialog.h:56
Definition ModulesDialog.h:8
Definition QTModelManager.h:94
Definition QTTools.h:183
Definition RibbonSubGroup.h:43
Definition SettingsDialog.h:58
Ui::SettingsUI * ui
Definition SettingsDialog.h:90
Dictionary< QWidget *, std::function< void()> > m_reset_to_default_settings
Definition SettingsDialog.h:104
Definition UnitsDialog.h:49
Definition WindowManager.h:68
Definition ACIColor.h:37
uint32_t uint04
-Defines an alias representing a 4 byte, unsigned integer -Can represent exact integer values 0 throu...
Definition BaseValues.hpp:120
Definition FontEditor.h:6