| Summary: | iOS [UIViewController setNeedsUpdateOfHomeIndicatorAutoHidden] needs delay | ||
|---|---|---|---|
| Product: | SDL | Reporter: | Dominik Reichardt <sdl-bugzilla> |
| Component: | thread | Assignee: | Sam Lantinga <slouken> |
| Status: | RESOLVED DUPLICATE | QA Contact: | Sam Lantinga <slouken> |
| Severity: | normal | ||
| Priority: | P2 | ||
| Version: | HG 2.1 | ||
| Hardware: | iPhone/iPod touch | ||
| OS: | iOS (All) | ||
| Attachments: | test patch for fireworks demo | ||
The delay is to wait for root SDL_uikitviewcontroller to be shown |
Created attachment 3809 [details] test patch for fireworks demo For some iOS apps it seems that a delay is needed for the hint SDL_HINT_IOS_HIDE_HOME_INDICATOR to work. A quick test patch is attached for the Fireworks iOS Demo. It has a delay callback and the hint is set to hide the HomeIndicator until you touch the screen. And that works with the added delay. Also the hint is added but commented to quickly test and see that it isn't working without the delay. This is with lock stock iOS 12 SDK. As for iOS 13 SDK: We've been doing this [callback delay] in Exult for iOS but when I took the beta SDK of iOS 13 for a quick spin this crashed in [UIViewController setNeedsUpdateOfHomeIndicatorAutoHidden] That's SDL_uiviewcontroller.m:60 if (@available(iOS 11.0, *)) { [viewcontroller setNeedsUpdateOfHomeIndicatorAutoHidden]; [viewcontroller setNeedsUpdateOfScreenEdgesDeferringSystemGestures]; } The debug information informed me that "-[UIViewController setNeedsUpdateOfHomeIndicatorAutoHidden] must be used from main thread only". So this workaround delay isn't safe to use in the future it seems. Probably not important enough to be a 2.0.10 blocker. OTOH iOS 13 is likely to drop before SDL 2.0.11