diff options
author | bubnikv <bubnikv@gmail.com> | 2020-03-12 14:43:01 +0300 |
---|---|---|
committer | bubnikv <bubnikv@gmail.com> | 2020-03-12 14:43:09 +0300 |
commit | e2274bfc8372577a62e309218c2a2fe6457da0c2 (patch) | |
tree | 0e2060c1bad8503cd1e9c5ed1408f6691d312bf5 /src/slic3r/GUI/Plater.cpp | |
parent | b9415607369d7a69772e197ac099c0ff2e8a41d5 (diff) |
Saving one enumeration of external drives when deciding whether
to verify the file saved or not.
Diffstat (limited to 'src/slic3r/GUI/Plater.cpp')
-rw-r--r-- | src/slic3r/GUI/Plater.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/slic3r/GUI/Plater.cpp b/src/slic3r/GUI/Plater.cpp index 224eb42fd..3d17c1fab 100644 --- a/src/slic3r/GUI/Plater.cpp +++ b/src/slic3r/GUI/Plater.cpp @@ -1929,7 +1929,7 @@ struct Plater::priv GUI::show_error(this->q, msg); } } - void export_gcode(fs::path output_path, PrintHostJob upload_job); + void export_gcode(fs::path output_path, bool output_path_on_removable_media, PrintHostJob upload_job); void reload_from_disk(); void reload_all_from_disk(); void fix_through_netfabb(const int obj_idx, const int vol_idx = -1); @@ -3216,7 +3216,7 @@ bool Plater::priv::restart_background_process(unsigned int state) return false; } -void Plater::priv::export_gcode(fs::path output_path, PrintHostJob upload_job) +void Plater::priv::export_gcode(fs::path output_path, bool output_path_on_removable_media, PrintHostJob upload_job) { wxCHECK_RET(!(output_path.empty() && upload_job.empty()), "export_gcode: output_path and upload_job empty"); @@ -3237,7 +3237,7 @@ void Plater::priv::export_gcode(fs::path output_path, PrintHostJob upload_job) return; if (! output_path.empty()) { - background_process.schedule_export(output_path.string()); + background_process.schedule_export(output_path.string(), output_path_on_removable_media); } else { background_process.schedule_upload(std::move(upload_job)); } @@ -4901,8 +4901,8 @@ void Plater::export_gcode(bool prefer_removable) } if (! output_path.empty()) { - p->export_gcode(output_path, PrintHostJob()); bool path_on_removable_media = removable_drive_manager.set_and_verify_last_save_path(output_path.string()); + p->export_gcode(output_path, path_on_removable_media, PrintHostJob()); // Storing a path to AppConfig either as path to removable media or a path to internal media. // is_path_on_removable_drive() is called with the "true" parameter to update its internal database as the user may have shuffled the external drives // while the dialog was open. @@ -5225,7 +5225,7 @@ void Plater::send_gcode() upload_job.upload_data.upload_path = dlg.filename(); upload_job.upload_data.start_print = dlg.start_print(); - p->export_gcode(fs::path(), std::move(upload_job)); + p->export_gcode(fs::path(), false, std::move(upload_job)); } } |