From 65414130217bbb57759a5f8a01fbe70546647371 Mon Sep 17 00:00:00 2001 From: "Unknown W. Brackets" Date: Sun, 2 Apr 2017 10:56:41 -0700 Subject: [PATCH] UI: Improve documentation on pop up use. --- UI/GameScreen.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/UI/GameScreen.cpp b/UI/GameScreen.cpp index 8863afd992..f5710f9034 100644 --- a/UI/GameScreen.cpp +++ b/UI/GameScreen.cpp @@ -443,6 +443,8 @@ void SetBackgroundPopupScreen::update() { UI::EventReturn GameScreen::OnSetBackground(UI::EventParams &e) { I18NCategory *ga = GetI18NCategory("Game"); + // This popup is used to prevent any race condition: + // g_gameInfoCache may take time to load the data, and a crash could happen if they exit before then. SetBackgroundPopupScreen *pop = new SetBackgroundPopupScreen(ga->T("Setting Background"), gamePath_); if (e.v) pop->SetPopupOrigin(e.v);