From 48881bb810d03c84a18697bb8cfcaa93118b03ea Mon Sep 17 00:00:00 2001 From: Pk11 Date: Sat, 18 Dec 2021 20:24:41 -0600 Subject: [PATCH] Fix color changing after opening keyboard (#126) --- arm9/source/file_browse.cpp | 4 ++++ arm9/source/hexEditor.cpp | 2 ++ 2 files changed, 6 insertions(+) diff --git a/arm9/source/file_browse.cpp b/arm9/source/file_browse.cpp index 0cf7f5c..5f910bd 100644 --- a/arm9/source/file_browse.cpp +++ b/arm9/source/file_browse.cpp @@ -773,6 +773,8 @@ std::string browseForFile (void) { videoSetModeSub(MODE_5_2D); bgShow(bgInitSub(2, BgType_Bmp8, BgSize_B8_256x256, 3, 0)); + BG_PALETTE_SUB[0] = 0x0000; + BG_PALETTE_SUB[1] = 0x7FFF; if (newName[0] != '\0') { // Check for unsupported characters @@ -903,6 +905,8 @@ std::string browseForFile (void) { videoSetModeSub(MODE_5_2D); bgShow(bgInitSub(2, BgType_Bmp8, BgSize_B8_256x256, 3, 0)); + BG_PALETTE_SUB[0] = 0x0000; + BG_PALETTE_SUB[1] = 0x7FFF; if (newName[0] != '\0') { // Check for unsupported characters diff --git a/arm9/source/hexEditor.cpp b/arm9/source/hexEditor.cpp index bf6fc1d..850ac54 100644 --- a/arm9/source/hexEditor.cpp +++ b/arm9/source/hexEditor.cpp @@ -102,6 +102,8 @@ u32 search(u32 offset, FILE *file) { videoSetModeSub(MODE_5_2D); bgShow(bgInitSub(2, BgType_Bmp8, BgSize_B8_256x256, 3, 0)); + BG_PALETTE_SUB[0] = 0x0000; + BG_PALETTE_SUB[1] = 0x7FFF; BG_PALETTE_SUB[0x1F] = 0x9CF7; BG_PALETTE_SUB[0x2F] = 0xB710;