#include "importprogressform.h" #include "ui_importprogressform.h" ImportProgressForm::ImportProgressForm(QWidget *parent) : QWidget(parent), ui(new Ui::ImportProgressForm) { ui->setupUi(this); ui->progressBar->setRange(0, 100); ui->progressBar->setValue(0); m_terminate = false; } ImportProgressForm::~ImportProgressForm() { delete ui; } void ImportProgressForm::on_btnCancel_clicked() { m_terminate = true; this->close(); } void ImportProgressForm::updateProgress(int currentPos) { ui->progressBar->setValue(currentPos); } bool ImportProgressForm::terminate() { return m_terminate; }