chore(cpn): generic simulator (#5692)
This commit is contained in:
@@ -37,6 +37,7 @@
|
||||
#include <QObject>
|
||||
#include <QSettings>
|
||||
#include <QStandardPaths>
|
||||
#include <QColor>
|
||||
|
||||
//! CPN_SETTINGS_REVISION is used to track settings changes independently of EdgeTX version. It should be reset to zero whenever settings are migrated to new COMPANY or PRODUCT.
|
||||
//! \note !! Increment this value if properties are removed or refactored. It will trigger a conversion/cleanup of any stored settings. \sa AppData::convertSettings()
|
||||
@@ -502,6 +503,7 @@ class Profile: public CompStoreObj
|
||||
PROPERTY(bool, telemSimEnabled, false)
|
||||
PROPERTY(bool, telemSimPauseOnHide, true)
|
||||
PROPERTY(bool, telemSimResetRssiOnStop, false)
|
||||
PROPERTY(QColor, radioSimCaseColor, QColor(Qt::black))
|
||||
|
||||
// Firmware Variables
|
||||
PROPERTYSTR2(beeper, "Beeper")
|
||||
@@ -653,10 +655,18 @@ class AppData: public CompStoreObj
|
||||
};
|
||||
Q_ENUM(UpdateCheckFreq)
|
||||
|
||||
enum SimuGenericKeysPos {
|
||||
SIMU_GENERIC_KEYS_DEFAULT,
|
||||
SIMU_GENERIC_KEYS_LEFT,
|
||||
SIMU_GENERIC_KEYS_RIGHT
|
||||
};
|
||||
Q_ENUM(SimuGenericKeysPos)
|
||||
|
||||
static QStringList newModelActionsList() { return { tr("None"), tr("Wizard"), tr("Editor"), tr("Template"), tr("Prompt") } ; }
|
||||
static QStringList updateCheckFreqsList() { return { tr("Manual"), tr("Startup"), tr("Daily"), tr("Weekly"), tr("Monthly") } ; }
|
||||
// refer enum QtMsgType
|
||||
static QStringList updateLogLevelsList() { return { tr("Debug"), tr("Warning"), tr("Critical"), tr("Fatal"), tr("Information") } ; }
|
||||
static QStringList simuGenericKeysPosList() { return { tr("Default"), tr("Left"), tr("Right") } ; }
|
||||
|
||||
explicit AppData();
|
||||
void init() override;
|
||||
@@ -819,6 +829,9 @@ class AppData: public CompStoreObj
|
||||
PROPERTY(bool, simuSW, true)
|
||||
PROPERTY(bool, disableJoystickWarning, false)
|
||||
|
||||
PROPERTY(SimuGenericKeysPos, simuGenericKeysPos, SIMU_GENERIC_KEYS_DEFAULT)
|
||||
PROPERTY(bool, simuScrollButtons, false)
|
||||
|
||||
// Message box confirmations
|
||||
PROPERTY(bool, confirmWriteModelsAndSettings, true)
|
||||
|
||||
@@ -827,6 +840,7 @@ class AppData: public CompStoreObj
|
||||
|
||||
CREATE_ENUM_FRIEND_STREAM_OPS(AppData::NewModelAction)
|
||||
CREATE_ENUM_FRIEND_STREAM_OPS(AppData::UpdateCheckFreq)
|
||||
CREATE_ENUM_FRIEND_STREAM_OPS(AppData::SimuGenericKeysPos)
|
||||
};
|
||||
|
||||
extern AppData g;
|
||||
|
||||
Reference in New Issue
Block a user