From e7b20067cfec5e44ee860256f80b97d2dc0d80bf Mon Sep 17 00:00:00 2001 From: "zhou.xu" Date: Fri, 11 Oct 2024 10:32:19 +0800 Subject: [PATCH] FIX:solve bug of ".gcode.gcode.3mf" on mac jira: none Change-Id: I8951672c5acdecb1e0375c89e0132c575a7b40e5 --- src/slic3r/GUI/Plater.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/slic3r/GUI/Plater.cpp b/src/slic3r/GUI/Plater.cpp index d0a92db6a..9f7f828a5 100644 --- a/src/slic3r/GUI/Plater.cpp +++ b/src/slic3r/GUI/Plater.cpp @@ -11390,6 +11390,11 @@ void Plater::export_gcode_3mf(bool export_all) temp_path = temp_path.substr(0, temp_path.size() - 6); output_path = temp_path + L".gcode.3mf"; } + else if (boost::iends_with(output_path.string(), ".gcode.gcode.3mf")) {//for mac + std::wstring temp_path = output_path.wstring(); + temp_path = temp_path.substr(0, temp_path.size() - 16); + output_path = temp_path + L".gcode.3mf"; + } else if (!boost::iends_with(output_path.string(), ".gcode.3mf")) { output_path = output_path.replace_extension(".gcode.3mf"); }