Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/prusa3d/PrusaSlicer.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYuSanka <yusanka@gmail.com>2018-03-16 14:56:03 +0300
committerYuSanka <yusanka@gmail.com>2018-03-16 14:56:03 +0300
commit7f5bfe3ddc11be07f6dad9a2fdf92182a20bf324 (patch)
tree8c65a4d1935814ac68d6b3713ac48f0f5f816588 /xs/src/libslic3r/Config.cpp
parentd97a8f574078a488c5625448ff5908993b4bd35d (diff)
First visualization of system value changes
Diffstat (limited to 'xs/src/libslic3r/Config.cpp')
-rw-r--r--xs/src/libslic3r/Config.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/xs/src/libslic3r/Config.cpp b/xs/src/libslic3r/Config.cpp
index 0a531849d..a4eaf3072 100644
--- a/xs/src/libslic3r/Config.cpp
+++ b/xs/src/libslic3r/Config.cpp
@@ -206,6 +206,18 @@ t_config_option_keys ConfigBase::diff(const ConfigBase &other) const
return diff;
}
+t_config_option_keys ConfigBase::equal(const ConfigBase &other) const
+{
+ t_config_option_keys equal;
+ for (const t_config_option_key &opt_key : this->keys()) {
+ const ConfigOption *this_opt = this->option(opt_key);
+ const ConfigOption *other_opt = other.option(opt_key);
+ if (this_opt != nullptr && other_opt != nullptr && *this_opt == *other_opt)
+ equal.emplace_back(opt_key);
+ }
+ return equal;
+}
+
std::string ConfigBase::serialize(const t_config_option_key &opt_key) const
{
const ConfigOption* opt = this->option(opt_key);