mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-07-14 14:32:15 -07:00
For the automatic card database update process, disconnect signals, terminate and wait for it to finish on window_main destruction.
Took 1 minute
This commit is contained in:
parent
a69bfb8cb8
commit
e775d5581c
1 changed files with 7 additions and 0 deletions
|
|
@ -1021,6 +1021,13 @@ MainWindow::~MainWindow()
|
||||||
trayIcon->deleteLater();
|
trayIcon->deleteLater();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (cardUpdateProcess) {
|
||||||
|
cardUpdateProcess->disconnect(this);
|
||||||
|
cardUpdateProcess->terminate();
|
||||||
|
cardUpdateProcess->waitForFinished(1000);
|
||||||
|
cardUpdateProcess = nullptr;
|
||||||
|
}
|
||||||
|
|
||||||
client->deleteLater();
|
client->deleteLater();
|
||||||
clientThread->wait();
|
clientThread->wait();
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue