简体   繁体   中英

Is there a private API to be able to detect what is current foreground app on iOS?

I am not planning to send this app to AppStore. It's just an experimental app. So, I am not worried about AppStore approval/rejection.

I am looking for a way, how I can determine

a) What is the current foreground app (my app will be in the background at that moment. I may use audio player or voip for this)

b) Detect when new application became foreground app

It looks like this question has this answer for mine question. how to determine which apps are background and which app is foreground on iOS by application id

It boils down to SBFrontmostApplicationDisplayIdentifier private API

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM