OSDN Git Service

Ver0.26
[gefu/Gefu.git] / operationdialog.h
1 #ifndef OPERATIONDIALOG_H\r
2 #define OPERATIONDIALOG_H\r
3 \r
4 #include <QDialog>\r
5 class OperationWorker;\r
6 \r
7 namespace Ui {\r
8 class OperationDialog;\r
9 }\r
10 \r
11 class OperationDialog : public QDialog\r
12 {\r
13     Q_OBJECT\r
14 \r
15 public:\r
16     explicit OperationDialog(QWidget *parent = 0);\r
17     ~OperationDialog();\r
18 \r
19     void setWorker(OperationWorker *worker) {\r
20         m_worker = worker;\r
21     }\r
22     void setAutoClose(bool yes);\r
23     bool autoClose() const;\r
24 \r
25 private:\r
26     Ui::OperationDialog *ui;\r
27 \r
28     OperationWorker*    m_worker;\r
29     bool                m_Error;\r
30 \r
31 private slots:\r
32     void onProgress(const QString &msg);\r
33     void onSuccess(const QString &msg);\r
34     void onError(const QString &msg);\r
35     void onFinished(bool abort);\r
36     void on_btnCloseCancel_clicked();\r
37     void on_btnShowDetail_clicked();\r
38 \r
39     // QDialog interface\r
40 public slots:\r
41     int exec();\r
42 };\r
43 \r
44 #endif // OPERATIONDIALOG_H\r