mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-10-11 21:46:23 +02:00
Enable --escape-exit for all relevant platforms. It makes PPSSPP more front-end friendly by letting escape quit the emu.
This commit is contained in:
1 parent
4394d034b3
commit
6bedad2aa5
4 files changed
+18
-9
No files matched your search
@@ -320,6 +320,10 @@ void NativeInit(int argc, const char *argv[],
|
||||
fileToLog = argv[i] + strlen("--log=");
|
||||
if (!strncmp(argv[i], "--state=", strlen("--state=")) && strlen(argv[i]) > strlen("--state="))
|
||||
stateToLoad = argv[i] + strlen("--state=");
|
||||
#if !defined(MOBILE_DEVICE)
|
||||
if (!strncmp(__argv[i], "--escape-exit", strlen("--escape-exit")))
|
||||
g_Config.bEscapeExitsEmulator = true;
|
||||
#endif
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
@@ -684,6 +688,11 @@ void NativeTouch(const TouchInput &touch) {
|
||||
|
||||
void NativeKey(const KeyInput &key) {
|
||||
// ILOG("Key code: %i flags: %i", key.keyCode, key.flags);
|
||||
#if !defined(MOBILE_DEVICE)
|
||||
if (g_Config.bEscapeExitsEmulator && key.keyCode == NKCODE_ESCAPE) {
|
||||
System_SendMessage("finish", "");
|
||||
}
|
||||
#endif
|
||||
g_buttonTracker.Process(key);
|
||||
if (screenManager)
|
||||
screenManager->key(key);
|
||||
|
||||
Reference in new issue
Block a user