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

github.com/supermerill/SuperSlicer.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEnrico Turri <enricoturri@seznam.cz>2020-01-17 16:16:12 +0300
committerEnrico Turri <enricoturri@seznam.cz>2020-01-17 16:16:12 +0300
commite8d52cfba1e025bb8b1d1ff4caa42354cccaf501 (patch)
treed8ed0c0a2f4aea3b6bdbf2c2be812131548086e6 /src/slic3r/GUI/3DBed.cpp
parent051fcd4e2459cb23df9e99e4b8465c9e6bee5402 (diff)
parent2259f7b3e8648b408e51d501ebe424a72f13c283 (diff)
Fixed conflicts after merge with master
Diffstat (limited to 'src/slic3r/GUI/3DBed.cpp')
-rw-r--r--src/slic3r/GUI/3DBed.cpp18
1 files changed, 2 insertions, 16 deletions
diff --git a/src/slic3r/GUI/3DBed.cpp b/src/slic3r/GUI/3DBed.cpp
index 9e32df783..beb0a6577 100644
--- a/src/slic3r/GUI/3DBed.cpp
+++ b/src/slic3r/GUI/3DBed.cpp
@@ -335,24 +335,10 @@ void Bed3D::calc_gridlines(const ExPolygon& poly, const BoundingBox& bed_bbox)
printf("Unable to create bed grid lines\n");
}
-static const VendorProfile::PrinterModel* system_printer_model(const Preset &preset)
-{
- const VendorProfile::PrinterModel *out = nullptr;
- if (preset.vendor != nullptr) {
- auto *printer_model = preset.config.opt<ConfigOptionString>("printer_model");
- if (printer_model != nullptr && ! printer_model->value.empty()) {
- auto it = std::find_if(preset.vendor->models.begin(), preset.vendor->models.end(), [printer_model](const VendorProfile::PrinterModel &pm) { return pm.id == printer_model->value; });
- if (it != preset.vendor->models.end())
- out = &(*it);
- }
- }
- return out;
-}
-
static std::string system_print_bed_model(const Preset &preset)
{
std::string out;
- const VendorProfile::PrinterModel *pm = system_printer_model(preset);
+ const VendorProfile::PrinterModel *pm = PresetUtils::system_printer_model(preset);
if (pm != nullptr && ! pm->bed_model.empty())
out = Slic3r::resources_dir() + "/profiles/" + preset.vendor->id + "/" + pm->bed_model;
return out;
@@ -361,7 +347,7 @@ static std::string system_print_bed_model(const Preset &preset)
static std::string system_print_bed_texture(const Preset &preset)
{
std::string out;
- const VendorProfile::PrinterModel *pm = system_printer_model(preset);
+ const VendorProfile::PrinterModel *pm = PresetUtils::system_printer_model(preset);
if (pm != nullptr && ! pm->bed_texture.empty())
out = Slic3r::resources_dir() + "/profiles/" + preset.vendor->id + "/" + pm->bed_texture;
return out;