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:
authorMartin Loidl <martin.loidl@gmail.com>2018-08-20 21:19:22 +0300
committerVojtech Kral <vojtech@kral.hk>2018-08-21 12:12:53 +0300
commitee9f7eaef69cbb84e3f5b54e6b624e317d16f7a3 (patch)
treec92c1bedb30a0fb01e85b26fdb732afa2adccccd /xs/src/libslic3r
parentd4b73701d939f6832d5b86818a318d409a25b508 (diff)
Host upload backwards compatibility
* Added legacy code to preserve backwards compatibility * renamed some cli option names to better match option names
Diffstat (limited to 'xs/src/libslic3r')
-rw-r--r--xs/src/libslic3r/PrintConfig.cpp12
1 files changed, 9 insertions, 3 deletions
diff --git a/xs/src/libslic3r/PrintConfig.cpp b/xs/src/libslic3r/PrintConfig.cpp
index 794c27608..943db2a30 100644
--- a/xs/src/libslic3r/PrintConfig.cpp
+++ b/xs/src/libslic3r/PrintConfig.cpp
@@ -1153,21 +1153,21 @@ PrintConfigDef::PrintConfigDef()
def->label = L("API Key / Password");
def->tooltip = L("Slic3r can upload G-code files to a printer host. This field should contain "
"the API Key or the password required for authentication.");
- def->cli = "octoprint-apikey=s";
+ def->cli = "printhost-apikey=s";
def->default_value = new ConfigOptionString("");
def = this->add("printhost_cafile", coString);
def->label = "HTTPS CA file";
def->tooltip = "Custom CA certificate file can be specified for HTTPS OctoPrint connections, in crt/pem format. "
"If left blank, the default OS CA certificate repository is used.";
- def->cli = "octoprint-cafile=s";
+ def->cli = "printhost-cafile=s";
def->default_value = new ConfigOptionString("");
def = this->add("print_host", coString);
def->label = L("Hostname, IP or URL");
def->tooltip = L("Slic3r can upload G-code files to a printer host. This field should contain "
"the hostname, IP address or URL of the printer host instance.");
- def->cli = "octoprint-host=s";
+ def->cli = "print-host=s";
def->default_value = new ConfigOptionString("");
def = this->add("only_retract_when_crossing_perimeters", coBool);
@@ -2129,6 +2129,12 @@ void PrintConfigDef::handle_legacy(t_config_option_key &opt_key, std::string &va
} else if (opt_key == "support_material_pattern" && value == "pillars") {
// Slic3r PE does not support the pillars. They never worked well.
value = "rectilinear";
+ } else if (opt_key == "octoprint_host") {
+ opt_key = "print_host";
+ } else if (opt_key == "octoprint_cafile") {
+ opt_key = "printhost_cafile";
+ } else if (opt_key == "octoprint_apikey") {
+ opt_key = "printhost_apikey";
}
// Ignore the following obsolete configuration keys: