From 15436e02a71a871f37ef1916d5e7b0a5e8ac39df Mon Sep 17 00:00:00 2001 From: profi200 Date: Tue, 16 Jul 2024 21:02:42 +0200 Subject: [PATCH] Updated submodules. Fixed compatibility with latest libn3ds. --- libraries/inih | 2 +- libraries/libn3ds | 2 +- source/arm11/filebrowser.c | 9 +++++---- source/arm11/main.c | 2 +- 4 files changed, 8 insertions(+), 7 deletions(-) diff --git a/libraries/inih b/libraries/inih index 077174e..ed45251 160000 --- a/libraries/inih +++ b/libraries/inih @@ -1 +1 @@ -Subproject commit 077174edcb92990d1a1c3c7da943a5638a543be1 +Subproject commit ed4525140dacc54e5924f60b25a00c69371866a0 diff --git a/libraries/libn3ds b/libraries/libn3ds index 3bd2168..f5e5e8e 160000 --- a/libraries/libn3ds +++ b/libraries/libn3ds @@ -1 +1 @@ -Subproject commit 3bd21685705cbcc4ada9aab2c0f43faeeb304151 +Subproject commit f5e5e8efb3a33959ee5489e2f13f1aecf62f1e04 diff --git a/source/arm11/filebrowser.c b/source/arm11/filebrowser.c index e977777..6b8f348 100644 --- a/source/arm11/filebrowser.c +++ b/source/arm11/filebrowser.c @@ -129,9 +129,9 @@ static void showDirList(const DirList *const dList, u32 start) for(u32 i = start; i < listLength; i++) { const char *const printStr = - (*dList->ptrs[i] == ENT_TYPE_FILE ? "\x1b[%lu;H\x1b[37m %.51s" : "\x1b[%lu;H\x1b[33m %.51s"); + (*dList->ptrs[i] == ENT_TYPE_FILE ? "\x1b[%lu;H\x1b[37;1m %.52s" : "\x1b[%lu;H\x1b[33;1m %.52s"); - ee_printf(printStr, i - start, &dList->ptrs[i][1]); + ee_printf(printStr, i - start + 1, &dList->ptrs[i][1]); } } @@ -156,8 +156,9 @@ Result browseFiles(const char *const basePath, char selected[512]) s32 oldCursorPos = 0; while(1) { - ee_printf("\x1b[%lu;H ", oldCursorPos - windowPos); // Clear old cursor. - ee_printf("\x1b[%lu;H\x1b[37m>", cursorPos - windowPos); // Draw cursor. + ee_printf("\x1b[%lu;H ", oldCursorPos - windowPos + 1); // Clear old cursor. + ee_printf("\x1b[%lu;H\x1b[37m>", cursorPos - windowPos + 1); // Draw cursor. + GFX_flushBuffers(); u32 kDown; do diff --git a/source/arm11/main.c b/source/arm11/main.c index 8f1243d..5bf6b90 100644 --- a/source/arm11/main.c +++ b/source/arm11/main.c @@ -31,7 +31,7 @@ int main(void) { Result res = oafParseConfigEarly(); - GFX_init(GFX_BGR8, GFX_R5G6B5, GFX_TOP_2D); + GFX_init(GFX_BGR8, GFX_BGR565, GFX_TOP_2D); changeBacklight(0); // Apply backlight config. consoleInit(GFX_LCD_BOT, NULL); //CODEC_init();