macos close button fix
This commit is contained in:
parent
6765142ebc
commit
c5ce417d79
1 changed files with 5 additions and 2 deletions
|
|
@ -219,8 +219,11 @@ void MainWindow::keyPressEvent(QKeyEvent *event)
|
||||||
|
|
||||||
void MainWindow::closeEvent(QCloseEvent *event)
|
void MainWindow::closeEvent(QCloseEvent *event)
|
||||||
{
|
{
|
||||||
event->ignore();
|
if (currentPage() == Page::Start || currentPage() == Page::NewServer) qApp->quit();
|
||||||
hide();
|
else {
|
||||||
|
hide();
|
||||||
|
event->ignore();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void MainWindow::showEvent(QShowEvent *event)
|
void MainWindow::showEvent(QShowEvent *event)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue