1
0
Fork 1
forked from suyu/suyu

Merge pull request #81 from lioncash/qt-bootmgr

bootmanager: Minor tidiness/correctness changes
This commit is contained in:
bunnei 2018-01-17 20:24:56 -05:00 committed by GitHub
commit 62a8c61e36
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 7 deletions

View file

@ -15,8 +15,7 @@
#include "input_common/motion_emu.h"
#include "yuzu/bootmanager.h"
EmuThread::EmuThread(GRenderWindow* render_window)
: exec_step(false), running(false), stop_run(false), render_window(render_window) {}
EmuThread::EmuThread(GRenderWindow* render_window) : render_window(render_window) {}
void EmuThread::run() {
render_window->MakeCurrent();

View file

@ -58,7 +58,7 @@ public:
* @return True if the emulation thread is running, otherwise false
* @note This function is thread-safe
*/
bool IsRunning() {
bool IsRunning() const {
return running;
}
@ -68,12 +68,12 @@ public:
void RequestStop() {
stop_run = true;
SetRunning(false);
};
}
private:
bool exec_step;
bool running;
std::atomic<bool> stop_run;
bool exec_step = false;
bool running = false;
std::atomic<bool> stop_run{false};
std::mutex running_mutex;
std::condition_variable running_cv;