mirror of
https://github.com/overte-org/overte.git
synced 2025-08-09 20:23:06 +02:00
Put ModelUploder on a different thread, not to block the rendering of the main window
This commit is contained in:
parent
cec99caa47
commit
b21fe02fa2
1 changed files with 6 additions and 3 deletions
|
@ -3245,9 +3245,12 @@ void Application::toggleRunningScriptsWidget()
|
||||||
|
|
||||||
void Application::uploadFST(bool isHead) {
|
void Application::uploadFST(bool isHead) {
|
||||||
ModelUploader* uploader = new ModelUploader(isHead);
|
ModelUploader* uploader = new ModelUploader(isHead);
|
||||||
if (uploader->zip()) {
|
QThread* thread = new QThread();
|
||||||
uploader->send();
|
thread->connect(uploader, SIGNAL(destroyed()), SLOT(quit()));
|
||||||
}
|
thread->connect(thread, SIGNAL(finished()), SLOT(deleteLater()));
|
||||||
|
uploader->connect(thread, SIGNAL(started()), SLOT(send()));
|
||||||
|
|
||||||
|
thread->start();
|
||||||
}
|
}
|
||||||
|
|
||||||
void Application::uploadHead() {
|
void Application::uploadHead() {
|
||||||
|
|
Loading…
Reference in a new issue