mirror of
https://github.com/stenzek/duckstation.git
synced 2025-06-12 22:37:21 +00:00
Qt: Fix possible race/crash on shutdown
This commit is contained in:
parent
8f82987341
commit
d80aaf3880
@ -225,7 +225,9 @@ void QtHostInterface::onDisplayWindowKeyEvent(int key, bool pressed)
|
|||||||
|
|
||||||
void QtHostInterface::onDisplayWindowMouseMoveEvent(int x, int y)
|
void QtHostInterface::onDisplayWindowMouseMoveEvent(int x, int y)
|
||||||
{
|
{
|
||||||
|
// display might be null here if the event happened after shutdown
|
||||||
DebugAssert(isOnWorkerThread());
|
DebugAssert(isOnWorkerThread());
|
||||||
|
if (m_display)
|
||||||
m_display->SetMousePosition(x, y);
|
m_display->SetMousePosition(x, y);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user