| 1234567891011121314151617181920212223242526272829303132 |
- #include "mainwindow.h"
- #include "ui_mainwindow.h"
- MainWindow::MainWindow(QWidget *parent) :
- QMainWindow(parent),
- ui(new Ui::MainWindow)
- {
- ui->setupUi(this);
- thread = new SegmentUpdate();
- thread->setMethod(UpdateBaseInfo);
- connect(thread,SIGNAL(updateFinished()),this,SLOT(killme()));
- thread->start();
- }
- MainWindow::~MainWindow()
- {
- delete ui;
- //QFile::remove("baseSeg.csv");
- //QFile::remove("dynamicSeg.csv");
- }
- void MainWindow::killme()
- {
- thread->abort();
- thread->wait();
- delete thread;
- this->close();
- }
- void MainWindow::closeEvent(QCloseEvent *event)
- {
- return ;
- }
|