check if control center is used

ε祈祈猫儿з 提交于 2019-12-02 03:13:47

You can't do it. The most you can know is that your app was deactivated and then activated again, but you have no way of finding out why. It could be because of the control center, it could be because of the notification center, it could be because a phone call came in, it could be because the user went into the app switcher and came back again... If you think you have a use case for being able obtain this particular information, submit an enhancement request to Apple.

You can use applicationDidBecomeActive: in your app delegate. You don't know what the reason is for that part being called, but it will be called after coming back to the app from control center. From there you can refresh things.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!