mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-10-23 00:31:11 -06:00
Several improvements to the print job queue
This commit is contained in:
parent
9b21ac877a
commit
fc1a7471cf
13 changed files with 174 additions and 65 deletions
|
@ -158,6 +158,18 @@ GCodeSender::resume_queue()
|
|||
this->send();
|
||||
}
|
||||
|
||||
void
|
||||
GCodeSender::purge_queue()
|
||||
{
|
||||
boost::lock_guard<boost::mutex> l(this->queue_mutex);
|
||||
{
|
||||
// clear queue
|
||||
std::queue<std::string> empty;
|
||||
std::swap(this->queue, empty);
|
||||
}
|
||||
this->queue_paused = false;
|
||||
}
|
||||
|
||||
// purge log and return its contents
|
||||
std::vector<std::string>
|
||||
GCodeSender::purge_log()
|
||||
|
|
|
@ -27,6 +27,7 @@ class GCodeSender : private boost::noncopyable {
|
|||
size_t queue_size() const;
|
||||
void pause_queue();
|
||||
void resume_queue();
|
||||
void purge_queue();
|
||||
std::vector<std::string> purge_log();
|
||||
std::string getT() const;
|
||||
std::string getB() const;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue