mirror of
https://github.com/joel16/3DSident.git
synced 2024-11-26 21:10:24 +00:00
Refactor ANY_KEY
This is because certain headphones without buttons may cause 3DSident to exit automatically due to the fact that any key can be used to exit the app.
This commit is contained in:
parent
1f022655b3
commit
0ee6f749ba
@ -3,5 +3,9 @@
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
|
||||
#define ANY_KEY (KEY_TOUCH | KEY_A | KEY_B | KEY_X | KEY_Y | KEY_START | KEY_SELECT | \
|
||||
KEY_UP | KEY_DOWN | KEY_LEFT | KEY_RIGHT | KEY_L | KEY_R | KEY_ZL | KEY_ZR | \
|
||||
KEY_CSTICK_UP | KEY_CSTICK_DOWN | KEY_CSTICK_LEFT | KEY_CSTICK_RIGHT)
|
||||
|
||||
void getSizeString(char *string, uint64_t size);
|
||||
char * base64Encode(u8 const * input);
|
@ -170,6 +170,9 @@ AccessControlInfo:
|
||||
- gsp::Gpu
|
||||
- gsp::Lcd
|
||||
- hid:USER
|
||||
- ir:rst
|
||||
- ir:u
|
||||
- ir:USER
|
||||
- mcu::HWC
|
||||
- ndm:u
|
||||
- ps:ps
|
||||
@ -177,10 +180,8 @@ AccessControlInfo:
|
||||
- ptm:u
|
||||
- pxi:dev
|
||||
- soc:U
|
||||
- gsp::Lcd
|
||||
- y2r:u
|
||||
- ldr:ro
|
||||
- ir:USER
|
||||
- csnd:SND
|
||||
- am:u
|
||||
- ns:s
|
||||
@ -198,31 +199,33 @@ SystemControlInfo:
|
||||
ac: 0x0004013000002402
|
||||
act: 0x0004013000003802
|
||||
am: 0x0004013000001502
|
||||
boss: 0x0004013000003402L
|
||||
camera: 0x0004013000001602L
|
||||
cecd: 0x0004013000002602L
|
||||
cfg: 0x0004013000001702L
|
||||
codec: 0x0004013000001802L
|
||||
csnd: 0x0004013000002702L
|
||||
dlp: 0x0004013000002802L
|
||||
dsp: 0x0004013000001a02L
|
||||
friends: 0x0004013000003202L
|
||||
gpio: 0x0004013000001b02L
|
||||
gsp: 0x0004013000001c02L
|
||||
hid: 0x0004013000001d02L
|
||||
http: 0x0004013000002902L
|
||||
i2c: 0x0004013000001e02L
|
||||
ir: 0x0004013000003302L
|
||||
mcu: 0x0004013000001f02L
|
||||
mic: 0x0004013000002002L
|
||||
ndm: 0x0004013000002b02L
|
||||
news: 0x0004013000003502L
|
||||
nim: 0x0004013000002c02L
|
||||
nwm: 0x0004013000002d02L
|
||||
pdn: 0x0004013000002102L
|
||||
ps: 0x0004013000003102L
|
||||
ptm: 0x0004013000002202L
|
||||
ro: 0x0004013000003702L
|
||||
socket: 0x0004013000002e02L
|
||||
spi: 0x0004013000002302L
|
||||
ssl: 0x0004013000002f02L
|
||||
boss: 0x0004013000003402
|
||||
camera: 0x0004013000001602
|
||||
cecd: 0x0004013000002602
|
||||
cfg: 0x0004013000001702
|
||||
codec: 0x0004013000001802
|
||||
csnd: 0x0004013000002702
|
||||
dlp: 0x0004013000002802
|
||||
dsp: 0x0004013000001a02
|
||||
friends: 0x0004013000003202
|
||||
gpio: 0x0004013000001b02
|
||||
gsp: 0x0004013000001c02
|
||||
hid: 0x0004013000001d02
|
||||
http: 0x0004013000002902
|
||||
i2c: 0x0004013000001e02
|
||||
ir: 0x0004013000003302
|
||||
mcu: 0x0004013000001f02
|
||||
mic: 0x0004013000002002
|
||||
ndm: 0x0004013000002b02
|
||||
news: 0x0004013000003502
|
||||
nfc: 0x0004013000004002
|
||||
nim: 0x0004013000002c02
|
||||
nwm: 0x0004013000002d02
|
||||
pdn: 0x0004013000002102
|
||||
ps: 0x0004013000003102
|
||||
ptm: 0x0004013000002202
|
||||
qtm: 0x0004013020004202
|
||||
ro: 0x0004013000003702
|
||||
socket: 0x0004013000002e02
|
||||
spi: 0x0004013000002302
|
||||
ssl: 0x0004013000002f02
|
@ -244,7 +244,7 @@ int main(int argc, char *argv[])
|
||||
if ((kHeld & KEY_L) && (kHeld & KEY_R))
|
||||
captureScreenshot();
|
||||
|
||||
else if (hidKeysDown())
|
||||
else if (hidKeysDown() & ANY_KEY)
|
||||
break;
|
||||
|
||||
gfxFlushBuffers();
|
||||
@ -258,4 +258,4 @@ int main(int argc, char *argv[])
|
||||
|
||||
termServices();
|
||||
return 0;
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user