summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKay Sievers <kay@vrfy.org>2013-12-22 21:48:45 +0100
committerKay Sievers <kay@vrfy.org>2013-12-22 21:48:45 +0100
commit30030cb9c76f8efbd4393f1323fd19fa06c0b217 (patch)
treebad5d89e3e5a364832fb55bb4c8626b92d70c32c
parent0f4945c4aca5586063ba85fb0be32cf7c123ea6f (diff)
cosmetics for 'P' splash loop
-rw-r--r--src/efi/gummiboot.c36
1 files changed, 18 insertions, 18 deletions
diff --git a/src/efi/gummiboot.c b/src/efi/gummiboot.c
index e018ffd..90770c8 100644
--- a/src/efi/gummiboot.c
+++ b/src/efi/gummiboot.c
@@ -381,32 +381,32 @@ static VOID print_status(Config *config, EFI_FILE *root_dir, CHAR16 *loaded_imag
uefi_call_wrapper(ST->ConOut->SetAttribute, 2, ST->ConOut, EFI_LIGHTGRAY|EFI_BACKGROUND_BLACK);
uefi_call_wrapper(ST->ConOut->ClearScreen, 1, ST->ConOut);
+ /* show splash and wait for key */
for (;;) {
+ static const EFI_GRAPHICS_OUTPUT_BLT_PIXEL colors[] = {
+ { .Red = 255, .Green = 255, .Blue = 255 },
+ { .Red = 255, .Green = 0, .Blue = 0 },
+ { .Red = 0, .Green = 255, .Blue = 0 },
+ { .Red = 0, .Green = 0, .Blue = 255 },
+ { .Red = 0, .Green = 0, .Blue = 0 },
+ };
err = EFI_NOT_FOUND;
if (config->splash)
err = graphics_splash(root_dir, config->splash, pixel);
if (EFI_ERROR(err))
err = graphics_splash(root_dir, L"\\EFI\\gummiboot\\splash.bmp", pixel);
- if (!EFI_ERROR(err)) {
- static const EFI_GRAPHICS_OUTPUT_BLT_PIXEL colors[] = {
- { .Red = 255, .Green = 255, .Blue = 255 },
- { .Red = 255, .Green = 0, .Blue = 0 },
- { .Red = 0, .Green = 255, .Blue = 0 },
- { .Red = 0, .Green = 0, .Blue = 255 },
- { .Red = 0, .Green = 0, .Blue = 0 },
- };
-
- console_key_read(&key, TRUE);
-
- /* 'b' rotates through background colors */
- if (key == KEYPRESS(0, 0, 'b')) {
- pixel = &colors[color++];
- if (color == ELEMENTSOF(colors))
- color = 0;
+ if (EFI_ERROR(err))
+ break;
- continue;
- }
+ /* 'b' rotates through background colors */
+ console_key_read(&key, TRUE);
+ if (key == KEYPRESS(0, 0, 'b')) {
+ pixel = &colors[color++];
+ if (color == ELEMENTSOF(colors))
+ color = 0;
+
+ continue;
}
graphics_mode(FALSE);