New Table widget

This commit is contained in:
Bertrand Songis
2019-11-28 17:03:57 +01:00
parent d3f7033605
commit bc9cd3fba9
17 changed files with 59 additions and 63 deletions
+8 -8
View File
@@ -1,35 +1,35 @@
if(PCB STREQUAL X9D OR PCB STREQUAL X9D+ OR PCB STREQUAL SKY9X OR PCB STREQUAL AR9X)
set(EEPROM_CONVERSIONS 216)
set(STORAGE_CONVERSIONS 216)
endif()
if(PCB STREQUAL SKY9X OR PCB STREQUAL AR9X OR PCB STREQUAL 9XRPRO)
set(EEPROM_CONVERSIONS 216)
set(STORAGE_CONVERSIONS 216)
endif()
if(PCB STREQUAL X7 OR PCB STREQUAL XLITE OR PCB STREQUAL X9E)
set(EEPROM_CONVERSIONS 218)
set(STORAGE_CONVERSIONS 218)
endif()
if(PCB STREQUAL X12S OR PCB STREQUAL X10)
set(EEPROM_CONVERSIONS 218)
set(STORAGE_CONVERSIONS 218)
endif()
if(EEPROM_CONVERSIONS)
add_definitions(-DEEPROM_CONVERSIONS=${EEPROM_CONVERSIONS})
if(STORAGE_CONVERSIONS)
add_definitions(-DSTORAGE_CONVERSIONS=${STORAGE_CONVERSIONS})
set(SRC
${SRC}
storage/conversions/conversions.cpp
)
endif()
if(EEPROM_CONVERSIONS LESS 218)
if(STORAGE_CONVERSIONS LESS 218)
set(SRC
${SRC}
storage/conversions/conversions_216_218.cpp
)
endif()
if(EEPROM_CONVERSIONS LESS 219)
if(STORAGE_CONVERSIONS LESS 219)
set(SRC
${SRC}
storage/conversions/conversions_218_219.cpp
@@ -25,21 +25,21 @@ void convertRadioData(int version)
{
TRACE("convertRadioData(%d)", version);
#if EEPROM_CONVERSIONS < 217
#if STORAGE_CONVERSIONS < 217
if (version == 216) {
version = 217;
convertRadioData_216_to_217(g_eeGeneral);
}
#endif
#if EEPROM_CONVERSIONS < 218
#if STORAGE_CONVERSIONS < 218
if (version == 217) {
version = 218;
convertRadioData_217_to_218(g_eeGeneral);
}
#endif
#if EEPROM_CONVERSIONS < 219
#if STORAGE_CONVERSIONS < 219
if (version == 218) {
version = 219;
convertRadioData_218_to_219(g_eeGeneral);
@@ -51,21 +51,21 @@ void convertModelData(int version)
{
TRACE("convertModelData(%d)", version);
#if EEPROM_CONVERSIONS < 217
#if STORAGE_CONVERSIONS < 217
if (version == 216) {
version = 217;
convertModelData_216_to_217(g_model);
}
#endif
#if EEPROM_CONVERSIONS < 218
#if STORAGE_CONVERSIONS < 218
if (version == 217) {
version = 218;
convertModelData_217_to_218(g_model);
}
#endif
#if EEPROM_CONVERSIONS < 219
#if STORAGE_CONVERSIONS < 219
if (version == 218) {
version = 219;
convertModelData_218_to_219(g_model);
@@ -121,21 +121,21 @@ bool eeConvert()
eeLoadGeneralSettingsData();
int version = conversionVersionStart;
#if EEPROM_CONVERSIONS < 217
#if STORAGE_CONVERSIONS < 217
if (version == 216) {
version = 217;
convertRadioData_216_to_217(g_eeGeneral);
}
#endif
#if EEPROM_CONVERSIONS < 218
#if STORAGE_CONVERSIONS < 218
if (version == 217) {
version = 218;
convertRadioData_217_to_218(g_eeGeneral);
}
#endif
#if EEPROM_CONVERSIONS < 219
#if STORAGE_CONVERSIONS < 219
if (version == 218) {
version = 219;
convertRadioData_218_to_219(g_eeGeneral);
+1 -1
View File
@@ -584,7 +584,7 @@ const char * eeRestoreModel(uint8_t i_fileDst, char *model_name)
eeLoadModelHeader(i_fileDst, &modelHeaders[i_fileDst]);
#if defined(EEPROM_CONVERSIONS)
#if defined(STORAGE_CONVERSIONS)
if (version < EEPROM_VER) {
eeConvertModel(i_fileDst, version);
eeLoadModel(g_eeGeneral.currModel);
+2 -2
View File
@@ -596,7 +596,7 @@ const char * eeRestoreModel(uint8_t i_fileDst, char *model_name)
f_close(&g_oLogFile);
#if defined(EEPROM_CONVERSIONS)
#if defined(STORAGE_CONVERSIONS)
if (version < EEPROM_VER) {
storageCheck(true);
eeConvertModel(i_fileDst, version);
@@ -795,7 +795,7 @@ bool eeLoadGeneral(bool allowFixes)
}
#endif
#if defined(EEPROM_CONVERSIONS)
#if defined(STORAGE_CONVERSIONS)
if (g_eeGeneral.version != EEPROM_VER) {
TRACE("EEPROM version %d instead of %d", g_eeGeneral.version, EEPROM_VER);
if (!allowFixes)
+4 -1
View File
@@ -122,9 +122,12 @@ const char * loadModel(const char * filename, bool alarms)
storageCheck(true);
alarms = false;
}
else if (version < EEPROM_VER) {
#if defined(STORAGE_CONVERSIONS)
if (version < EEPROM_VER) {
convertModelData(version);
}
#endif
postModelLoad(alarms);
+1 -1
View File
@@ -136,7 +136,7 @@ const char * loadRadioSettings(const char * path)
return error;
}
#if defined(EEPROM_CONVERSIONS)
#if defined(STORAGE_CONVERSIONS)
if (version < EEPROM_VER) {
convertRadioData(version);
}