1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
|
#pragma once
#include <QMenu>
#include <QObject>
#include "preferences/usersettings.h"
class ControlPickerMenu : public QMenu {
Q_OBJECT
public:
ControlPickerMenu(QWidget* pParent);
virtual ~ControlPickerMenu();
const QList<ConfigKey>& controlsAvailable() const {
return m_controlsAvailable;
}
bool controlExists(const ConfigKey& key) const;
QString descriptionForConfigKey(const ConfigKey& key) const;
QString controlTitleForConfigKey(const ConfigKey& key) const;
signals:
// Emitted when the user selects a control from the menu.
void controlPicked(const ConfigKey& control);
private slots:
// Triggered when user selects a control from the menu.
void controlChosen(int controlIndex);
private:
QMenu* addSubmenu(QString title, QMenu* pParent=NULL);
void addSingleControl(const QString& group,
const QString& control,
const QString& title,
const QString& description,
QMenu* pMenu,
const QString& prefix = QString(),
const QString& actionTitle = QString());
void addControl(const QString& group,
const QString& control,
const QString& title,
const QString& helpText,
QMenu* pMenu,
bool addReset = false,
const QString& prefix = QString());
void addPlayerControl(const QString& control,
const QString& title,
const QString& helpText,
QMenu* pMenu,
bool deckControls,
bool samplerControls,
bool previewdeckControls,
bool addReset = false);
void addDeckAndSamplerControl(const QString& control,
const QString& title,
const QString& helpText,
QMenu* pMenu,
bool addReset = false);
void addDeckAndPreviewDeckControl(const QString& control,
const QString& title,
const QString& helpText,
QMenu* pMenu,
bool addReset = false);
void addDeckAndSamplerAndPreviewDeckControl(const QString& control,
const QString& title,
const QString& helpText,
QMenu* pMenu,
bool addReset = false);
void addDeckControl(const QString& control,
const QString& title,
const QString& helpText,
QMenu* pMenu,
bool addReset = false);
void addSamplerControl(const QString& control,
const QString& title,
const QString& helpText,
QMenu* pMenu,
bool addReset = false);
void addPreviewDeckControl(const QString& control,
const QString& title,
const QString& helpText,
QMenu* pMenu,
bool addReset = false);
void addMicrophoneAndAuxControl(const QString& control,
const QString& title,
const QString& helpText,
QMenu* pMenu,
bool microphoneControls,
bool auxControls,
bool addReset = false);
int addAvailableControl(const ConfigKey& key, const QString& title, const QString& description);
QString m_effectMasterOutputStr;
QString m_effectHeadphoneOutputStr;
QString m_deckStr;
QString m_previewdeckStr;
QString m_samplerStr;
QString m_resetStr;
QString m_microphoneStr;
QString m_auxStr;
QString m_effectRackStr;
QString m_effectUnitStr;
QString m_effectStr;
QString m_parameterStr;
QString m_libraryStr;
QList<ConfigKey> m_controlsAvailable;
QHash<ConfigKey, QString> m_descriptionsByKey;
QHash<ConfigKey, QString> m_titlesByKey;
};
|