mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-07 23:17:35 -06:00
fix flatpak build
This commit is contained in:
parent
b0bd16e908
commit
f490d2ca9f
2 changed files with 14 additions and 15 deletions
|
@ -583,7 +583,16 @@ public:
|
|||
bool is_step_done(PrintStepEnum step) const { return m_state.is_done(step, this->state_mutex()); }
|
||||
PrintStateBase::StateWithTimeStamp step_state_with_timestamp(PrintStepEnum step) const { return m_state.state_with_timestamp(step, this->state_mutex()); }
|
||||
PrintStateBase::StateWithWarnings step_state_with_warnings(PrintStepEnum step) const { return m_state.state_with_warnings(step, this->state_mutex()); }
|
||||
|
||||
// Add a slicing warning to the active Print step and send a status notification.
|
||||
// This method could be called multiple times between this->set_started() and this->set_done().
|
||||
void active_step_add_warning(PrintStateBase::WarningLevel warning_level, const std::string &message,
|
||||
PrintStateBase::SlicingNotificationType message_id = PrintStateBase::SlicingDefaultNotification)
|
||||
{
|
||||
std::pair<PrintStepEnum, bool> active_step = m_state.active_step_add_warning(warning_level, message, (int)message_id, this->state_mutex());
|
||||
if (active_step.second)
|
||||
// Update UI.
|
||||
this->status_update_warnings(static_cast<int>(active_step.first), warning_level, message, nullptr, message_id);
|
||||
}
|
||||
protected:
|
||||
bool set_started(PrintStepEnum step) { return m_state.set_started(step, this->state_mutex(), [this](){ this->throw_if_canceled(); }); }
|
||||
PrintStateBase::TimeStamp set_done(PrintStepEnum step) {
|
||||
|
@ -605,16 +614,6 @@ protected:
|
|||
bool is_step_started_unguarded(PrintStepEnum step) const { return m_state.is_started_unguarded(step); }
|
||||
bool is_step_done_unguarded(PrintStepEnum step) const { return m_state.is_done_unguarded(step); }
|
||||
|
||||
// Add a slicing warning to the active Print step and send a status notification.
|
||||
// This method could be called multiple times between this->set_started() and this->set_done().
|
||||
void active_step_add_warning(PrintStateBase::WarningLevel warning_level, const std::string &message,
|
||||
PrintStateBase::SlicingNotificationType message_id = PrintStateBase::SlicingDefaultNotification)
|
||||
{
|
||||
std::pair<PrintStepEnum, bool> active_step = m_state.active_step_add_warning(warning_level, message, (int)message_id, this->state_mutex());
|
||||
if (active_step.second)
|
||||
// Update UI.
|
||||
this->status_update_warnings(static_cast<int>(active_step.first), warning_level, message, nullptr, message_id);
|
||||
}
|
||||
|
||||
private:
|
||||
PrintState<PrintStepEnum, COUNT> m_state;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue