Qt: Fix GetBootConfirmation()
This commit is contained in:
@@ -9,6 +9,8 @@
|
|||||||
#include <QCoreApplication>
|
#include <QCoreApplication>
|
||||||
#include <QMessageBox>
|
#include <QMessageBox>
|
||||||
|
|
||||||
|
#include <thread>
|
||||||
|
|
||||||
LOG_CHANNEL(cfg_log, "CFG");
|
LOG_CHANNEL(cfg_log, "CFG");
|
||||||
|
|
||||||
namespace gui
|
namespace gui
|
||||||
@@ -188,6 +190,12 @@ void gui_settings::ShowInfoBox(const QString& title, const QString& text, const
|
|||||||
|
|
||||||
bool gui_settings::GetBootConfirmation(QWidget* parent, const gui_save& gui_save_entry)
|
bool gui_settings::GetBootConfirmation(QWidget* parent, const gui_save& gui_save_entry)
|
||||||
{
|
{
|
||||||
|
while (Emu.GetStatus(false) == system_state::stopping)
|
||||||
|
{
|
||||||
|
QCoreApplication::processEvents();
|
||||||
|
std::this_thread::sleep_for(16ms);
|
||||||
|
}
|
||||||
|
|
||||||
if (!Emu.IsStopped())
|
if (!Emu.IsStopped())
|
||||||
{
|
{
|
||||||
QString title = tr("Close Running Game?");
|
QString title = tr("Close Running Game?");
|
||||||
|
|||||||
Reference in New Issue
Block a user