mirror of
https://github.com/azahar-emu/azahar.git
synced 2026-11-18 03:44:48 +01:00
Qt: Fix intermittent crash on exit (#6612)
* Fix null pointer deref on exit * Fix from review
This commit is contained in:
1 parent
238a574645
commit
d807cdfe62
1 file changed
+3
-1
@@ -587,7 +587,9 @@ bool GRenderWindow::event(QEvent* event) {
|
||||
|
||||
void GRenderWindow::focusOutEvent(QFocusEvent* event) {
|
||||
QWidget::focusOutEvent(event);
|
||||
InputCommon::GetKeyboard()->ReleaseAllKeys();
|
||||
if (auto* keyboard = InputCommon::GetKeyboard(); keyboard) {
|
||||
keyboard->ReleaseAllKeys();
|
||||
}
|
||||
has_focus = false;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user