mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-11-20 04:44:22 +01:00
Drop the thread from Qt audio loop. Makes exit cleaner.
Probably needs to be reworked or replaced with SDL it seems.
This commit is contained in:
1 parent
2ba8e36b2b
commit
14d2fa9a39
2 files changed
+5
-14
No files matched your search
+2
-11
@@ -162,21 +162,12 @@ static int mainInternal(QApplication &a)
|
||||
SDL_CloseAudio();
|
||||
}
|
||||
}
|
||||
|
||||
// Audio must be unpaused _after_ NativeInit()
|
||||
SDL_PauseAudio(0);
|
||||
#else
|
||||
QScopedPointer<QThread> thread(new QThread);
|
||||
QScopedPointer<MainAudio> audio(new MainAudio());
|
||||
audio->moveToThread(thread.data());
|
||||
QObject::connect(thread.data(), SIGNAL(started()), audio.data(), SLOT(run()));
|
||||
thread->start();
|
||||
audio->run();
|
||||
#endif
|
||||
int ret = a.exec();
|
||||
#ifndef QT_HAS_SDL
|
||||
thread->terminate();
|
||||
#endif
|
||||
return ret;
|
||||
return a.exec();
|
||||
}
|
||||
|
||||
#ifndef QT_HAS_SDL
|
||||
|
||||
Reference in new issue
Block a user