add: basic req trans.
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
#include "Transform.h"
|
||||
|
||||
#include <QMessageBox>
|
||||
|
||||
#include "ui_Transform.h"
|
||||
@@ -16,4 +17,23 @@ TransForm::~TransForm()
|
||||
void TransForm::SetClientCore(ClientCore* clientCore)
|
||||
{
|
||||
clientCore_ = clientCore;
|
||||
fileTrans_ = new FileTrans(clientCore_);
|
||||
}
|
||||
|
||||
void TransForm::SetTasks(const QVector<TransTask>& tasks)
|
||||
{
|
||||
tasks_ = tasks;
|
||||
}
|
||||
|
||||
void TransForm::startTask()
|
||||
{
|
||||
for (auto& task : tasks_) {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
void TransForm::showEvent(QShowEvent* event)
|
||||
{
|
||||
QDialog::showEvent(event);
|
||||
startTask();
|
||||
}
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
#include <ClientCore.h>
|
||||
#include <QDialog>
|
||||
#include <QFile>
|
||||
#include <FileTrans.h>
|
||||
|
||||
namespace Ui {
|
||||
class TransForm;
|
||||
@@ -19,9 +20,18 @@ public:
|
||||
|
||||
public:
|
||||
void SetClientCore(ClientCore* clientCore);
|
||||
void SetTasks(const QVector<TransTask>& tasks);
|
||||
|
||||
private:
|
||||
ClientCore* clientCore_;
|
||||
void startTask();
|
||||
|
||||
protected:
|
||||
void showEvent(QShowEvent* event) override;
|
||||
|
||||
private:
|
||||
QVector<TransTask> tasks_;
|
||||
FileTrans* fileTrans_{};
|
||||
ClientCore* clientCore_{};
|
||||
Ui::TransForm* ui;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user