mirror of
https://github.com/flutter/flutter.git
synced 2026-02-20 02:29:02 +08:00
According to Apple's [OpenGL ES Programming guide][1], applications should pause any animations in applicationWillResignActive. Any GL calls after applicationDidEnterBackground will cause the app to be terminated immedidately by iOS. The surfaceUpdated:YES call is moved to the handler for the applicationDidBecomeActive notification to handle cases where the application becomes inactive then active again without being backgrounded (e.g. home button double-tap then return to app directly). [1]: https://developer.apple.com/library/archive/documentation/3DDrawing/Conceptual/OpenGLES_ProgrammingGuide/ImplementingaMultitasking-awareOpenGLESApplication/ImplementingaMultitasking-awareOpenGLESApplication.html#//apple_ref/doc/uid/TP40008793-CH5-SW1