mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-12 01:07:57 -06:00
ENH: config: add local logic into config.load
JIRA: github-2569 Change-Id: If593b9faee324dda096a27873587db27aa22129e
This commit is contained in:
parent
5250dc6fa6
commit
3b9d61cfc0
2 changed files with 3 additions and 1 deletions
|
@ -753,6 +753,9 @@ int ConfigBase::load_from_json(const std::string &file, ConfigSubstitutionContex
|
||||||
std::list<std::string> different_settings_append;
|
std::list<std::string> different_settings_append;
|
||||||
std::string new_support_style;
|
std::string new_support_style;
|
||||||
bool is_project_settings = false;
|
bool is_project_settings = false;
|
||||||
|
|
||||||
|
CNumericLocalesSetter locales_setter;
|
||||||
|
|
||||||
try {
|
try {
|
||||||
boost::nowide::ifstream ifs(file);
|
boost::nowide::ifstream ifs(file);
|
||||||
ifs >> j;
|
ifs >> j;
|
||||||
|
|
|
@ -2729,7 +2729,6 @@ void PresetBundle::load_config_file_config(const std::string &name_or_path, bool
|
||||||
std::pair<PresetsConfigSubstitutions, size_t> PresetBundle::load_vendor_configs_from_json(
|
std::pair<PresetsConfigSubstitutions, size_t> PresetBundle::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)
|
||||||
{
|
{
|
||||||
CNumericLocalesSetter locales_setter;
|
|
||||||
// Enable substitutions for user config bundle, throw an exception when loading a system profile.
|
// Enable substitutions for user config bundle, throw an exception when loading a system profile.
|
||||||
ConfigSubstitutionContext substitution_context { compatibility_rule };
|
ConfigSubstitutionContext substitution_context { compatibility_rule };
|
||||||
PresetsConfigSubstitutions substitutions;
|
PresetsConfigSubstitutions substitutions;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue