mirror of
https://github.com/GreemDev/Ryujinx.git
synced 2024-11-24 18:20:12 +01:00
Fix some GLXBadDrawable crashes on linux (#1900)
Fixes the crashes on linux when you stop emulation, and when you try to exit the emulator while a game is running. Also tested on windows without problems on my side.
This commit is contained in:
parent
734747ae58
commit
2fe3b8e58c
@ -593,7 +593,6 @@ namespace Ryujinx.Ui
|
|||||||
ToggleExtraWidgets(true);
|
ToggleExtraWidgets(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
_viewBox.Remove(GlRendererWidget);
|
|
||||||
GlRendererWidget.Exit();
|
GlRendererWidget.Exit();
|
||||||
|
|
||||||
if(GlRendererWidget.Window != Window && GlRendererWidget.Window != null)
|
if(GlRendererWidget.Window != Window && GlRendererWidget.Window != null)
|
||||||
@ -606,6 +605,7 @@ namespace Ryujinx.Ui
|
|||||||
_windowsMultimediaTimerResolution?.Dispose();
|
_windowsMultimediaTimerResolution?.Dispose();
|
||||||
_windowsMultimediaTimerResolution = null;
|
_windowsMultimediaTimerResolution = null;
|
||||||
|
|
||||||
|
_viewBox.Remove(GlRendererWidget);
|
||||||
_viewBox.Add(_gameTableWindow);
|
_viewBox.Add(_gameTableWindow);
|
||||||
|
|
||||||
_gameTableWindow.Expand = true;
|
_gameTableWindow.Expand = true;
|
||||||
@ -713,6 +713,7 @@ namespace Ryujinx.Ui
|
|||||||
|
|
||||||
// Wait for the other thread to dispose the HLE context before exiting.
|
// Wait for the other thread to dispose the HLE context before exiting.
|
||||||
_deviceExitStatus.WaitOne();
|
_deviceExitStatus.WaitOne();
|
||||||
|
GlRendererWidget.Dispose();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1202,4 +1203,4 @@ namespace Ryujinx.Ui
|
|||||||
UpdateGameTable();
|
UpdateGameTable();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user