From 9039d91d0ad4d27ccfea0ba019fdf53a0fa45311 Mon Sep 17 00:00:00 2001 From: Maschell Date: Thu, 30 Dec 2021 16:21:29 +0100 Subject: [PATCH] Improve UI when no envionments where found --- source/main.cpp | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/source/main.cpp b/source/main.cpp index b82cb17..aa3834e 100644 --- a/source/main.cpp +++ b/source/main.cpp @@ -320,10 +320,14 @@ std::string EnvironmentSelectionScreen(const std::map // draw bottom bar DrawUtils::drawRectFilled(8, SCREEN_HEIGHT - 24 - 8 - 4, SCREEN_WIDTH - 8 * 2, 3, COLOR_WHITE); DrawUtils::setFontSize(18); - DrawUtils::print(16, SCREEN_HEIGHT - 8, "\ue07d Navigate "); - DrawUtils::print(SCREEN_WIDTH - 16, SCREEN_HEIGHT - 8, "\ue000 Choose", true); - const char *autobootHints = "\ue002 Clear Default / \ue003 Select Default"; - DrawUtils::print(SCREEN_WIDTH / 2 + DrawUtils::getTextWidth(autobootHints) / 2, SCREEN_HEIGHT - 8, autobootHints, true); + if (!payloads.empty()) { + DrawUtils::print(16, SCREEN_HEIGHT - 8, "\ue07d Navigate "); + DrawUtils::print(SCREEN_WIDTH - 16, SCREEN_HEIGHT - 8, "\ue000 Choose", true); + const char *autobootHints = "\ue002 Clear Default / \ue003 Select Default"; + DrawUtils::print(SCREEN_WIDTH / 2 + DrawUtils::getTextWidth(autobootHints) / 2, SCREEN_HEIGHT - 8, autobootHints, true); + } else { + DrawUtils::print(SCREEN_WIDTH - 20, SCREEN_HEIGHT - 8, "\ue000 Wii U Menu", true); + } DrawUtils::endDraw();