feat(cpn): Add individual model save to yml (#1968)
- add save model(s) to context menu and toolbar - new storage functions to support single model write - modified yml storage format write functions - default save directory is application sd card TEMPLATES - model name used as default file name
This commit is contained in:
@@ -121,6 +121,20 @@ bool Storage::write(const RadioData & radioData)
|
||||
return ret;
|
||||
}
|
||||
|
||||
bool Storage::writeModel(const RadioData & radioData, const int modelIndex)
|
||||
{
|
||||
bool ret = false;
|
||||
foreach(StorageFactory * factory, registeredStorageFactories) {
|
||||
if (factory->probe(filename)) {
|
||||
StorageFormat * format = factory->instance(filename);
|
||||
ret = format->writeModel(radioData, modelIndex);
|
||||
delete format;
|
||||
break;
|
||||
}
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
||||
bool convertEEprom(const QString & sourceEEprom, const QString & destinationEEprom, const QString & firmwareFilename)
|
||||
{
|
||||
FirmwareInterface firmware(firmwareFilename);
|
||||
|
||||
Reference in New Issue
Block a user