src/settingseditor/settingseditor.h

Sat, 01 Feb 2020 15:33:57 +0200

author
Teemu Piippo <teemu@hecknology.net>
date
Sat, 01 Feb 2020 15:33:57 +0200
changeset 37
90443fb328ea
parent 16
aeb5f203b3eb
child 41
0abada2a9802
permissions
-rw-r--r--

wired renderstyle up

7
68443f5be176 added the settings editor
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
1 #pragma once
68443f5be176 added the settings editor
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
2 #include <QDialog>
68443f5be176 added the settings editor
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
3 #include "main.h"
68443f5be176 added the settings editor
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
4 #include "librarieseditor.h"
68443f5be176 added the settings editor
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
5 #include "libraries.h"
16
Teemu Piippo <teemu@hecknology.net>
parents: 7
diff changeset
6 #include "uiutilities.h"
7
68443f5be176 added the settings editor
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
7
68443f5be176 added the settings editor
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
8 class SettingsEditor : public QDialog
68443f5be176 added the settings editor
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
9 {
68443f5be176 added the settings editor
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
10 Q_OBJECT
68443f5be176 added the settings editor
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
11 public:
16
Teemu Piippo <teemu@hecknology.net>
parents: 7
diff changeset
12 SettingsEditor(QSettings* settings,
Teemu Piippo <teemu@hecknology.net>
parents: 7
diff changeset
13 const uiutilities::KeySequenceMap& defaultKeyboardShortcuts = {},
Teemu Piippo <teemu@hecknology.net>
parents: 7
diff changeset
14 QWidget* parent = nullptr);
7
68443f5be176 added the settings editor
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
15 ~SettingsEditor();
68443f5be176 added the settings editor
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
16 private slots:
68443f5be176 added the settings editor
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
17 void handleAccepted();
68443f5be176 added the settings editor
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
18 private:
68443f5be176 added the settings editor
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
19 class Ui_SettingsEditor& ui;
68443f5be176 added the settings editor
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
20 QSettings* const settings;
68443f5be176 added the settings editor
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
21 LibraryManager libraries;
68443f5be176 added the settings editor
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
22 LibrariesEditor librariesEditor;
16
Teemu Piippo <teemu@hecknology.net>
parents: 7
diff changeset
23 const uiutilities::KeySequenceMap defaultKeyboardShortcuts;
7
68443f5be176 added the settings editor
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
24 void loadLocales();
68443f5be176 added the settings editor
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
25 void setDefaults();
68443f5be176 added the settings editor
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
26 void setCurrentLanguage(const QString& localeCode);
68443f5be176 added the settings editor
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
27 };

mercurial