mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-10-19 23:01:22 -06:00
OctoPrint WIP: Fix build
This commit is contained in:
parent
2350fb62b9
commit
2eaca46b75
3 changed files with 124 additions and 1 deletions
|
@ -17,6 +17,7 @@
|
|||
#include "libslic3r/GCode/PostProcessor.hpp"
|
||||
|
||||
//#undef NDEBUG
|
||||
#include <iostream> // XXX
|
||||
#include <cassert>
|
||||
#include <stdexcept>
|
||||
#include <cctype>
|
||||
|
@ -79,6 +80,10 @@ void BackgroundSlicingProcess::process_fff()
|
|||
wxQueueEvent(GUI::wxGetApp().mainframe->m_plater, new wxCommandEvent(m_event_slicing_completed_id));
|
||||
m_fff_print->export_gcode(m_temp_output_path, m_gcode_preview_data);
|
||||
if (this->set_step_started(bspsGCodeFinalize)) {
|
||||
|
||||
std::cerr << "BackgroundSlicingProcess: m_upload_job: " << !!m_upload_job << std::endl;
|
||||
std::cerr << "BackgroundSlicingProcess: m_export_path: " << m_export_path << std::endl;
|
||||
|
||||
if (! m_export_path.empty()) {
|
||||
//FIXME localize the messages
|
||||
// Perform the final post-processing of the export path by applying the print statistics over the file name.
|
||||
|
@ -387,7 +392,7 @@ void BackgroundSlicingProcess::schedule_upload(Slic3r::PrintHostJob upload_job)
|
|||
if (! m_export_path.empty())
|
||||
return;
|
||||
|
||||
const auto path = boost::filesystem::temp_directory_path()
|
||||
const boost::filesystem::path path = boost::filesystem::temp_directory_path()
|
||||
/ boost::filesystem::unique_path(".upload.%%%%-%%%%-%%%%-%%%%.gcode");
|
||||
|
||||
// Guard against entering the export step before changing the export path.
|
||||
|
|
|
@ -43,10 +43,24 @@ struct PrintHostJob
|
|||
std::unique_ptr<PrintHost> printhost;
|
||||
|
||||
PrintHostJob() {}
|
||||
PrintHostJob(const PrintHostJob&) = delete;
|
||||
PrintHostJob(PrintHostJob &&other)
|
||||
: upload_data(std::move(other.upload_data))
|
||||
, printhost(std::move(other.printhost))
|
||||
{}
|
||||
|
||||
PrintHostJob(DynamicPrintConfig *config)
|
||||
: printhost(PrintHost::get_print_host(config))
|
||||
{}
|
||||
|
||||
PrintHostJob& operator=(const PrintHostJob&) = delete;
|
||||
PrintHostJob& operator=(PrintHostJob &&other)
|
||||
{
|
||||
upload_data = std::move(other.upload_data);
|
||||
printhost = std::move(other.printhost);
|
||||
return *this;
|
||||
}
|
||||
|
||||
bool empty() const { return !printhost; }
|
||||
operator bool() const { return !!printhost; }
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue