IOS7: Don't suspend the application in iOS when pressing menu

The Apple guidelines for Apple TV tells that when pressing the menu
button from the root view the user shall be brought to the "Home"
screen, suspending the app. Prevent this to be done in iOS.
This commit is contained in:
Lars Sundström 2023-10-05 13:58:20 +02:00
parent f6585ae5f5
commit 857b7553aa

View File

@ -713,9 +713,14 @@ bool iOS7_fetchEvent(InternalEvent *event) {
- (void)handleMainMenuKey {
if ([self isInGame]) {
[self addEvent:InternalEvent(kInputMainMenu, 0, 0)];
} else {
}
#if TARGET_OS_TV
else {
// According to Apple's guidelines the app should return to the
// home screen when pressing the menu button from the root view.
[[UIApplication sharedApplication] performSelector:@selector(suspend)];
}
#endif
}
- (void)applicationSuspend {