Fix renamed_from feature and others

This commit is contained in:
SoftFever 2025-01-19 23:04:35 +08:00
parent 8188963e20
commit 206c6228a5
6 changed files with 83 additions and 79 deletions

View file

@ -160,7 +160,12 @@ public:
// and the system profiles will point to the VendorProfile instances owned by PresetBundle::vendors.
VendorMap vendors;
struct ObsoletePresets {
// Orca: for OrcaFilamentLibrary
std::map<std::string, DynamicPrintConfig> m_config_maps;
std::map<std::string, std::string> m_filament_id_maps;
struct ObsoletePresets
{
std::vector<std::string> prints;
std::vector<std::string> sla_prints;
std::vector<std::string> filaments;
@ -212,9 +217,9 @@ public:
// Don't do any config substitutions when loading a system profile, perform and report substitutions otherwise.
/*std::pair<PresetsConfigSubstitutions, size_t> load_configbundle(
const std::string &path, LoadConfigBundleAttributes flags, ForwardCompatibilitySubstitutionRule compatibility_rule);*/
//BBS: add json related logic
//Orca: load config bundle from json, pass the base bundle to support cross vendor inheritance
std::pair<PresetsConfigSubstitutions, size_t> load_vendor_configs_from_json(
const std::string &path, const std::string &vendor_name, LoadConfigBundleAttributes flags, ForwardCompatibilitySubstitutionRule compatibility_rule);
const std::string &path, const std::string &vendor_name, LoadConfigBundleAttributes flags, ForwardCompatibilitySubstitutionRule compatibility_rule, const PresetBundle* base_bundle = nullptr);
// Export a config bundle file containing all the presets and the names of the active presets.
//void export_configbundle(const std::string &path, bool export_system_settings = false, bool export_physical_printers = false);