EDIT: And your connect seems to be now in wrong place, it's in the destructor (MainWindow::~MainWindow()) though it should be in constructor (MainWindow::MainWindow())