Merge pull request #1646 from piepacker/jake/osd_locking_opt

optimize locking mechanism for OSD messages (deadlock-proofing)
This commit is contained in:
Connor McLaughlin
2021-02-22 12:21:12 +10:00
committed by GitHub
3 changed files with 71 additions and 54 deletions

View File

@ -2712,12 +2712,7 @@ void DrawStatsOverlay()
void DrawOSDMessages()
{
if (!g_settings.display_show_osd_messages)
{
// we still need to remove them from the queue
s_host_interface->EnumerateOSDMessages([](const std::string& message, float time_remaining) { return true; });
return;
}
s_host_interface->AcquirePendingOSDMessages();
ImGui::PushFont(g_large_font);