mirror of https://github.com/mgba-emu/mgba.git
GUI, 3DS: Fix some warnings
This commit is contained in:
parent
11d9b492cd
commit
03d97baeec
|
@ -22,6 +22,8 @@
|
|||
#include <3ds/types.h>
|
||||
#include <3ds/svc.h>
|
||||
|
||||
#include "util/common.h"
|
||||
|
||||
extern char* fake_heap_start;
|
||||
extern char* fake_heap_end;
|
||||
u32 __linear_heap;
|
||||
|
@ -69,6 +71,8 @@ void __system_allocateHeaps() {
|
|||
|
||||
void __attribute__((noreturn)) __libctru_exit(int rc)
|
||||
{
|
||||
UNUSED(rc);
|
||||
|
||||
u32 tmp=0;
|
||||
|
||||
// Unmap the linear heap
|
||||
|
|
|
@ -122,6 +122,7 @@ static void _drawTex(bool faded) {
|
|||
sf2d_draw_texture_scale_blend(tex, 80, 296, 1, -1, 0xFFFFFF3F | (faded ? 0 : 0xC0));
|
||||
break;
|
||||
case SM_PA_BOTTOM:
|
||||
default:
|
||||
sf2d_draw_texture_scale_blend(tex, 40, 296, 1, -1, 0xFFFFFF3F | (faded ? 0 : 0xC0));
|
||||
break;
|
||||
case SM_AF_TOP:
|
||||
|
@ -141,8 +142,8 @@ static void _drawTex(bool faded) {
|
|||
|
||||
static void _drawFrame(struct GBAGUIRunner* runner, bool faded) {
|
||||
UNUSED(runner);
|
||||
GSPGPU_FlushDataCache(0, renderer.outputBuffer, 256 * VIDEO_VERTICAL_PIXELS * 2);
|
||||
GX_SetDisplayTransfer(0, renderer.outputBuffer, GX_BUFFER_DIM(256, VIDEO_VERTICAL_PIXELS), tex->data, GX_BUFFER_DIM(256, VIDEO_VERTICAL_PIXELS), 0x000002202);
|
||||
GSPGPU_FlushDataCache(0, (u8*) renderer.outputBuffer, 256 * VIDEO_VERTICAL_PIXELS * 2);
|
||||
GX_SetDisplayTransfer(0, (u32*) renderer.outputBuffer, GX_BUFFER_DIM(256, VIDEO_VERTICAL_PIXELS), tex->data, GX_BUFFER_DIM(256, VIDEO_VERTICAL_PIXELS), 0x000002202);
|
||||
_drawTex(faded);
|
||||
#if RESAMPLE_LIBRARY == RESAMPLE_BLIP_BUF
|
||||
if (!hasSound) {
|
||||
|
@ -173,6 +174,7 @@ static void _drawScreenshot(struct GBAGUIRunner* runner, const uint32_t* pixels,
|
|||
}
|
||||
|
||||
static uint16_t _pollGameInput(struct GBAGUIRunner* runner) {
|
||||
UNUSED(runner);
|
||||
hidScanInput();
|
||||
uint32_t activeKeys = hidKeysHeld() & 0xF00003FF;
|
||||
activeKeys |= activeKeys >> 24;
|
||||
|
|
|
@ -74,7 +74,7 @@ static bool _refreshDirectory(struct GUIParams* params, const char* currentPath,
|
|||
params->guiPrepare();
|
||||
}
|
||||
GUIFontPrintf(params->font, 0, GUIFontHeight(params->font), GUI_TEXT_LEFT, 0xFFFFFFFF, "%s", currentPath);
|
||||
GUIFontPrintf(params->font, 0, GUIFontHeight(params->font) * 2, GUI_TEXT_LEFT, 0xFFFFFFFF, "(scanning for items: %lu)", i);
|
||||
GUIFontPrintf(params->font, 0, GUIFontHeight(params->font) * 2, GUI_TEXT_LEFT, 0xFFFFFFFF, "(scanning for items: %zu)", i);
|
||||
if (params->guiFinish) {
|
||||
params->guiFinish();
|
||||
}
|
||||
|
@ -104,7 +104,7 @@ static bool _refreshDirectory(struct GUIParams* params, const char* currentPath,
|
|||
params->guiPrepare();
|
||||
}
|
||||
GUIFontPrintf(params->font, 0, GUIFontHeight(params->font), GUI_TEXT_LEFT, 0xFFFFFFFF, "%s", currentPath);
|
||||
GUIFontPrintf(params->font, 0, GUIFontHeight(params->font) * 2, GUI_TEXT_LEFT, 0xFFFFFFFF, "(scanning item %lu of %lu)", i, items);
|
||||
GUIFontPrintf(params->font, 0, GUIFontHeight(params->font) * 2, GUI_TEXT_LEFT, 0xFFFFFFFF, "(scanning item %zu of %zu)", i, items);
|
||||
if (params->guiFinish) {
|
||||
params->guiFinish();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue