mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-23 14:44:19 -06:00
Add dedicated subclass NotificationProgressIndicator
to replace ProgressStatusBar and revert changes from b9dab754
, keep UI jobs untouched
This commit is contained in:
parent
7e3306c68f
commit
63647f594e
16 changed files with 161 additions and 99 deletions
|
@ -8,13 +8,14 @@
|
|||
|
||||
#include <slic3r/GUI/I18N.hpp>
|
||||
|
||||
#include "ProgressIndicator.hpp"
|
||||
|
||||
#include <wx/event.h>
|
||||
|
||||
#include <boost/thread.hpp>
|
||||
|
||||
namespace Slic3r { namespace GUI {
|
||||
|
||||
class NotificationManager;
|
||||
// A class to handle UI jobs like arranging and optimizing rotation.
|
||||
// These are not instant jobs, the user has to be informed about their
|
||||
// state in the status progress indicator. On the other hand they are
|
||||
|
@ -32,7 +33,7 @@ class Job : public wxEvtHandler
|
|||
boost::thread m_thread;
|
||||
std::atomic<bool> m_running{false}, m_canceled{false};
|
||||
bool m_finalized = false, m_finalizing = false;
|
||||
std::shared_ptr<NotificationManager> m_notifications;
|
||||
std::shared_ptr<ProgressIndicator> m_progress;
|
||||
std::exception_ptr m_worker_error = nullptr;
|
||||
|
||||
void run(std::exception_ptr &);
|
||||
|
@ -64,7 +65,7 @@ protected:
|
|||
}
|
||||
|
||||
public:
|
||||
Job(std::shared_ptr<NotificationManager> nm);
|
||||
Job(std::shared_ptr<ProgressIndicator> pri);
|
||||
|
||||
bool is_finalized() const { return m_finalized; }
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue