iPhone App can autolaunch after device boot?

梦想的初衷 提交于 2019-11-30 08:41:36

问题


Saw an app called PhoneRecover on the AppStore.

They advertise the following:

  • PhoneRecover will automatically restart after a reboot on the iPhone 3GS and the iPhone 4 running iOS4.

How is this possible? What APIs are used to auto-launch an app after a boot?


回答1:


It's built into multi-tasking. "Backgrounded" apps are still in background after a reboot. Presumably the app does some work to re-instantiate itself and get its state going again the first time Core Location hits it in the background, but there's no other magic happening here. Any background-aware app will survive a reboot in a backgrounded state.




回答2:


I wouldn't count on this. I was running MotionX GPS and let the battery run completely dead. Upon restart MotionX was no longer running, broadcasting my position or tracking my position. The broadcast option is persistent too (survives app restart).



来源:https://stackoverflow.com/questions/5109305/iphone-app-can-autolaunch-after-device-boot

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