void MainWindow::on_actionStatisticalRemoval_triggered() { //load RadiusOutlier Ui QUiLoader loader; QFile file(":/forms/StatisticalRemoval.ui"); file.open(QFile::ReadOnly); QDialog *statisticalRemovalForm = dynamic_cast<QDialog *>(loader.load(&file, this)); file.close(); if(statisticalRemovalForm->exec()==QDialog::Accepted) { while(statisticalRemovalForm->isVisible());//untill it closed QLineEdit *std=statisticalRemovalForm->findChild<QLineEdit *>("stddev"); QLineEdit *n=statisticalRemovalForm->findChild<QLineEdit *>("neighbor"); QString txt ="Applying Statistical filter to the cloud ..."; QProgressDialog *p=new QProgressDialog( txt,QString(),0, 0, this); p->setWindowModality(Qt::WindowModal); p->setVisible(true); connect(controller, SIGNAL(finished()), p, SLOT(reset())); QtConcurrent::run(controller,&CloudControl::filter,std->text().toDouble(),n->text().toInt(),1); //int re=controller->RadiusOutlier(r->text().toDouble(),n->text().toInt()); } }