diff --git a/Common/System/Request.cpp b/Common/System/Request.cpp index 059f49769b..6099071dbe 100644 --- a/Common/System/Request.cpp +++ b/Common/System/Request.cpp @@ -40,7 +40,7 @@ std::vector OnScreenDisplay::ProgressBars() { return bars_; // makes a copy. } -void OnScreenDisplay::Show(OSDType type, const std::string &text, float duration_s, const char *id) { +void OnScreenDisplay::Show(OSDType type, const std::string &text, const std::string &text2, float duration_s, const char *id) { // Automatic duration based on type. if (duration_s <= 0.0f) { switch (type) { @@ -68,7 +68,9 @@ void OnScreenDisplay::Show(OSDType type, const std::string &text, float duration Entry msg = *iter; msg.endTime = now + duration_s; msg.text = text; + msg.text2 = text2; msg.type = type; + // Move to top (should we? maybe not?) entries_.erase(iter); entries_.insert(entries_.begin(), msg); return; @@ -78,6 +80,7 @@ void OnScreenDisplay::Show(OSDType type, const std::string &text, float duration Entry msg; msg.text = text; + msg.text2 = text2; msg.endTime = now + duration_s; msg.type = type; msg.id = id; diff --git a/Common/System/System.h b/Common/System/System.h index c9908711a7..7ffea0b52f 100644 --- a/Common/System/System.h +++ b/Common/System/System.h @@ -228,7 +228,10 @@ enum class OSDType { class OnScreenDisplay { public: // If you specify 0.0f as duration, a duration will be chosen automatically depending on type. - void Show(OSDType type, const std::string &message, float duration_s = 0.0f, const char *id = nullptr); + void Show(OSDType type, const std::string &text, float duration_s = 0.0f, const char *id = nullptr) { + Show(type, text, "", duration_s, id); + } + void Show(OSDType type, const std::string &text, const std::string &text2, float duration_s = 0.0f, const char *id = nullptr); void ShowOnOff(const std::string &message, bool on, float duration_s = 0.0f); bool IsEmpty() const { return entries_.empty(); } // Shortcut to skip rendering. @@ -244,6 +247,7 @@ public: struct Entry { OSDType type; std::string text; + std::string text2; const char *id; double endTime; double duration; diff --git a/UI/EmuScreen.cpp b/UI/EmuScreen.cpp index 741fe66888..7cfc1c6fe3 100644 --- a/UI/EmuScreen.cpp +++ b/UI/EmuScreen.cpp @@ -229,6 +229,8 @@ bool EmuScreen::bootAllowStorage(const Path &filename) { } void EmuScreen::bootGame(const Path &filename) { + auto sc = GetI18NCategory(I18NCat::SCREEN); + if (PSP_IsRebooting()) return; if (PSP_IsInited()) { @@ -259,8 +261,6 @@ void EmuScreen::bootGame(const Path &filename) { if (!bootAllowStorage(filename)) return; - auto sc = GetI18NCategory(I18NCat::SCREEN); - invalid_ = true; // We don't want to boot with the wrong game specific config, so wait until info is ready.