I have an audio app and I want to control play/pause with ApplicationShortcutItem
directly, but I don't want to open the app. Is it possible?
It is not possible to leave an app in the background when choosing a Home screen quick action.
From the documentation of UIApplicationShortcutItem
:
When a user chooses one of your Home screen quick actions, the system launches or resumes your app and
UIKit
calls theapplication(_:performActionFor:completionHandler:)
method in your app delegate.
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.