关闭或重新启动时,Windows无法终止进程。 Qt的

时间:2014-03-02 15:25:44

标签: c++ windows qt winapi

我有一个明确的项目,其中只有一个插槽onbuttonclick并且只有一个命令this-> hide();当我按下它并且表单隐藏时我无法关闭或重启我的窗口,直到我关闭应用程序或显示表单。你能帮帮我吗? Qt 5.2.1静态

#include "mainwindow.h"
#include "ui_mainwindow.h"

MainWindow::MainWindow(QWidget *parent) :
    QMainWindow(parent),
    ui(new Ui::MainWindow)
{
    ui->setupUi(this);
}

MainWindow::~MainWindow()
{
    delete ui;
}

void MainWindow::on_pushButton_clicked()
{
    this->hide();
}

0 个答案:

没有答案