Reacting to Dark Mode for ios 13

Hi! I want my cocos game to react to dark mode change on ios 13 like the following video:

https://discuss.cocos2d-x.org/uploads/default/original/3X/4/e/4e8be8efa96da1525e57273695cdd1f04649b613.mov

I noticed that when i change ios 13 dark mode on/off, cocos will not react to changes and draw until all native ios screens in front are removed. The reason is because the app correctly checks in CCDirectorCaller-ios.mm if the app is active before drawing.

18%20AM

If i remove isAppActive check, the issue is fixed but i guess it is potentially dangerous for crashes. What if I change the check to become inactive from UIApplicationWillResignActiveNotification to UIApplicationDidEnterBackgroundNotification? This will allow the app to draw in more cases but still pause on background. Is it safe? Is app allowed to draw if UIApplicationWillResignActiveNotification is called but not UIApplicationDidEnterBackgroundNotification?

willResignActive - Can app still draw?
didEnterBackround - App CANNOT draw here 100%.

Also is there a way to make cocos draw a single frame?

@zhangxm i guess u will know the answer )