diff options
author | YuSanka <yusanka@gmail.com> | 2020-01-08 17:26:01 +0300 |
---|---|---|
committer | YuSanka <yusanka@gmail.com> | 2020-01-08 18:29:37 +0300 |
commit | fb65e3152f12faf6d515e8e1c184e00c9a42758b (patch) | |
tree | eb8f34dd992abd039d65f492ed2c6aac7d01db22 /src/slic3r/GUI/wxExtensions.hpp | |
parent | 07c1c3d1dc9aade0b95fa570314205ee8ee35481 (diff) |
DoubleSlider modes(states) are extended and implemented mode detection from model
+ Some code refactoring
Diffstat (limited to 'src/slic3r/GUI/wxExtensions.hpp')
-rw-r--r-- | src/slic3r/GUI/wxExtensions.hpp | 35 |
1 files changed, 9 insertions, 26 deletions
diff --git a/src/slic3r/GUI/wxExtensions.hpp b/src/slic3r/GUI/wxExtensions.hpp index 390dafab9..31e60d7d6 100644 --- a/src/slic3r/GUI/wxExtensions.hpp +++ b/src/slic3r/GUI/wxExtensions.hpp @@ -823,7 +823,10 @@ public: enum ManipulationState { msSingleExtruder, // single extruder printer preset is selected - msMultiExtruder // multiple extruder printer preset is selected, and "Whole print" is selected + msMultiAsSingle, // multiple extruder printer preset is selected, but + // this mode works just for Single extruder print + // (For all print from objects settings is used just one extruder) + msMultiExtruder // multiple extruder printer preset is selected }; void SetManipulationState(ManipulationState state) { m_state = state; @@ -976,31 +979,11 @@ private: public: struct ExtrudersSequence { - bool is_mm_intervals; - double interval_by_mm; - int interval_by_layers; - std::vector<size_t> extruders; - - ExtrudersSequence() : - is_mm_intervals(true), - interval_by_mm(3.0), - interval_by_layers(10), - extruders({ 0 }) {} - - ExtrudersSequence(const ExtrudersSequence& other) : - is_mm_intervals(other.is_mm_intervals), - interval_by_mm(other.interval_by_mm), - interval_by_layers(other.interval_by_layers), - extruders(other.extruders) {} - - ExtrudersSequence& operator=(const ExtrudersSequence& other) { - this->is_mm_intervals = other.is_mm_intervals; - this->interval_by_mm = other.interval_by_mm; - this->interval_by_layers= other.interval_by_layers; - this->extruders = other.extruders; - - return *this; - } + bool is_mm_intervals = true; + double interval_by_mm = 3.0; + int interval_by_layers = 10; + std::vector<size_t> extruders = { 0 }; + bool operator==(const ExtrudersSequence& other) const { return (other.is_mm_intervals == this->is_mm_intervals ) && |