#ifndef RZTASKDIALOG_H #define RZTASKDIALOG_H #include #include #include #include #include "common/RizinTask.h" #include "core/CutterCommon.h" class RizinTask; namespace Ui { class RizinTaskDialog; } class CUTTER_EXPORT RizinTaskDialog : public QDialog { Q_OBJECT public: using Ptr = QSharedPointer; RizinTaskDialog(Ptr task, QWidget *parent = nullptr); ~RizinTaskDialog(); void setBreakOnClose(bool v) { breakOnClose = v; } bool getBreakOnClose() { return breakOnClose; } void setDesc(const QString &label); public slots: void reject() override; private slots: void updateProgressTimer(); protected: void closeEvent(QCloseEvent *event) override; private: std::unique_ptr ui; QSharedPointer task; QTimer timer; QElapsedTimer elapsedTimer; bool breakOnClose = false; }; #endif // RZTASKDIALOG_H