after rebase changes

This commit is contained in:
David Kocik 2022-01-24 17:31:53 +01:00
parent 2b45731cff
commit e074754bea
3 changed files with 13 additions and 3 deletions

View File

@ -1327,7 +1327,7 @@ std::pair<PresetsConfigSubstitutions, size_t> PresetBundle::load_configbundle(
}
return false;
};
if (flags & LOAD_CFGBNDLE_SYSTEM)
if (flags & LoadSystem)
{
if (vendor_profile->using_common_base_profile) {
if(!branch_common(branches_to_remove, tree)) {

View File

@ -119,7 +119,7 @@ public:
ResetUserProfile,
// Load a system config bundle.
LoadSystem,
LoadVendorOnly,
LoadVendorOnly
};
using LoadConfigBundleAttributes = enum_bitmask<LoadConfigBundleAttribute>;
// Load the config bundle based on the flags.
@ -160,6 +160,11 @@ public:
// Unselected option would be reverted to the beginning values
void save_changes_for_preset(const std::string& new_name, Preset::Type type, const std::vector<std::string>& unselected_options);
void create_common_bundles_info(boost::filesystem::path dir);
size_t PresetBundle::load_common_configbundle(const std::string& path);
static const char *PRUSA_BUNDLE;
private:
std::pair<PresetsConfigSubstitutions, std::string> load_system_presets(ForwardCompatibilitySubstitutionRule compatibility_rule);

View File

@ -138,6 +138,11 @@ struct Updates
std::vector<Semver> common_materials_versions;
};
enum CommonProfileType : int {
Base = 0,
Filaments,
Materials
};
wxDEFINE_EVENT(EVT_SLIC3R_VERSION_ONLINE, wxCommandEvent);
wxDEFINE_EVENT(EVT_SLIC3R_EXPERIMENTAL_VERSION_ONLINE, wxCommandEvent);
@ -929,7 +934,7 @@ void PresetUpdater::priv::check_common_profiles(const std::vector<Semver>& versi
// install
update.install();
PresetBundle bundle;
bundle.load_configbundle(update.source.string(), PresetBundle::LOAD_CFGBNDLE_SYSTEM);
bundle.load_configbundle(update.source.string(), PresetBundle::LoadConfigBundleAttribute::LoadSystem, ForwardCompatibilitySubstitutionRule::Disable);
}