MCPcopy Create free account
hub / github.com/devkitPro/3ds-hbmenu / uiUpdate

Function uiUpdate

source/ui.c:65–88  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

63}
64
65bool uiUpdate(void)
66{
67 // Read input state
68 hidScanInput();
69 hidTouchRead(&g_touchPos);
70 hidCstickRead(&g_cstickPos);
71 g_cstickPos.dx = iabs(g_cstickPos.dx)<5 ? 0 : g_cstickPos.dx;
72 g_cstickPos.dy = iabs(g_cstickPos.dy)<5 ? 0 : g_cstickPos.dy;
73
74 const uiStateInfo_s* ui;
75
76 // Update background
77 ui = g_uiStateBg;
78 if (ui->update) ui->update();
79
80 if (!s_stateBusy)
81 {
82 // Update current state
83 ui = uiGetStateInfo();
84 if (ui->update) ui->update();
85 }
86
87 return !s_shouldExit;
88}

Callers 1

mainFunction · 0.85

Calls 2

uiGetStateInfoFunction · 0.85
iabsFunction · 0.70

Tested by

no test coverage detected