OpenCurves  0.9
loadprogress.h
1 //
2 // author Kazys Stepanas
3 //
4 // Copyright (c) CSIRO 2012
5 //
6 #ifndef __LOADPROGRESS_
7 #define __LOADPROGRESS_
8 
9 #include "ocurvesconfig.h"
10 
11 #include <QWidget>
12 
13 namespace Ui
14 {
15  class LoadProgress;
16 }
17 
28 class LoadProgress : public QWidget
29 {
30  Q_OBJECT
31 
32 public:
33  enum
34  {
39  };
40 
43  explicit LoadProgress(QWidget *parent = nullptr);
45  ~LoadProgress();
46 
47 signals:
49  void cancel();
50 
51 public slots:
54  void itemName(const QString &name);
55 
58  void itemProgress(int current);
59 
64  void overallProgress(int current, int total);
65 
68  void loadComplete(int overallCount);
69 
70 private slots:
72  void onCancel();
73 
74 private:
75  Ui::LoadProgress *ui;
76 };
77 
78 #endif // __LOADPROGRESS_
void loadComplete(int overallCount)
To be invoked on completion.
Definition: coloursview.h:16
void itemName(const QString &name)
Sets the name of the current item or operation.
~LoadProgress()
Destructor.
void cancel()
Raised when the cancel button is pressed.
A widget for showing the progress of loading.
Definition: loadprogress.h:28
void itemProgress(int current)
Sets the current item progress [0, CurrentItemMax].
LoadProgress(QWidget *parent=nullptr)
Constructor.
Maximum value for the current progress item.
Definition: loadprogress.h:38
void overallProgress(int current, int total)
Updates the overall item progress bar [0, total].