openmw/apps/opencs/view/doc/operations.hpp

41 lines
798 B
C++
Raw Permalink Normal View History

2012-11-23 12:20:35 +01:00
#ifndef CSV_DOC_OPERATIONS_H
#define CSV_DOC_OPERATIONS_H
#include <vector>
#include <QDockWidget>
class QVBoxLayout;
namespace CSVDoc
{
class Operation;
class Operations : public QDockWidget
{
2022-09-22 21:26:05 +03:00
Q_OBJECT
2012-11-23 12:20:35 +01:00
2022-09-22 21:26:05 +03:00
QVBoxLayout* mLayout;
std::vector<Operation*> mOperations;
2012-11-23 12:20:35 +01:00
2022-09-22 21:26:05 +03:00
// not implemented
Operations(const Operations&);
Operations& operator=(const Operations&);
2012-11-23 12:20:35 +01:00
2022-09-22 21:26:05 +03:00
public:
Operations();
2012-11-23 12:20:35 +01:00
2022-09-22 21:26:05 +03:00
void setProgress(int current, int max, int type, int threads);
///< Implicitly starts the operation, if it is not running already.
2012-11-23 12:20:35 +01:00
2022-09-22 21:26:05 +03:00
void quitOperation(int type);
///< Calling this function for an operation that is not running is a no-op.
2012-11-23 12:20:35 +01:00
2022-09-22 21:26:05 +03:00
signals:
2022-09-22 21:26:05 +03:00
void abortOperation(int type);
2012-11-23 12:20:35 +01:00
};
}
#endif