Outputs: Say the menus are on the device, instead of showing black

When no screen on the stack shows anything on an output (we're in the
menus), the background screen draws "Menus are on your device" there.
UI drawn to an output gets the primary's DPI scale, over the whole output.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
Henrik RydgårdandClaude Opus 5.5 committed 2026-10-22 18:42:53 +02:00
1 parent 923611b445
commit 3ca76c674c
3 files changed
+37 -1

No files matched your search

+14
View File
@@ -97,6 +97,20 @@ void HandleCommonMessages(UIMessage message, const char *value, ScreenManager *m
}
}
// Nothing on the stack shows anything there, so we're in the menus.
bool BackgroundScreen::renderOutput(const OutputDisplay &output) {
if (output.role != OutputRole::Game) {
return false;
}
UIContext &dc = *screenManager()->getUIContext();
auto di = GetI18NCategory(I18NCat::DIALOG);
const Bounds &bounds = dc.GetBounds();
dc.Begin();
dc.DrawText(di->T("Menus are on your device"), bounds.centerX(), bounds.centerY(), 0xFF505050, ALIGN_CENTER);
dc.Flush();
return true;
}
ScreenRenderFlags BackgroundScreen::render(ScreenRenderMode mode) {
UIContext *uiContext = screenManager()->getUIContext();