Watchkit - 如何仅为 Apple Watch 安排通知?
Watchkit - How to schedule notification only for Apple Watch?
我已经创建了一个带有 Apple Watch 扩展的应用程序。
我想知道是否可以安排只在 Apple Watch 上显示的通知。相反,我们可以安排一个通知只出现在 iPhone 上吗?
在 Apple 官方文档中,他们说:
Apple Watch takes full advantage of the existing interactive
notification support on iOS. If your iOS app supports notifications,
Apple Watch displays those notifications at appropriate times. When
one of your app’s local or remote notifications arrives on the user’s
iPhone, iOS decides whether to display that notification on the iPhone
or on the Apple Watch. For notifications sent to Apple Watch, the
system lets the the user know subtly that a notification is available.
If the user chooses to view the notification, the system displays an
abbreviated version of the notification first, followed by a more
detailed version. The user can dismiss the detailed notification,
launch your WatchKit app, or act on the notification by tapping an
available action button.
所以我认为你可以告诉 iOS 你的通知行为(当你的应用程序的本地或远程通知之一到达用户的
iPhone、iOS 决定是否在 iPhone 上显示该通知
或在 Apple Watch 上。对于发送到 Apple Watch 的通知,
系统让用户巧妙地知道通知可用。)
这是一个很好的问题,但遗憾的是目前无法解决。苹果正试图在如何引导通知方面非常务实。如果您 iPhone 已解锁,他们会假设您正在查看它并将通知发送到那里。如果您 iPhone 被锁定,那么所有通知都将发送到您的 Apple Watch。他们希望不惜一切代价避免在两个位置重复通知。
目前无法强制将远程或本地通知直接路由到 Watch。如果您对这个功能有强烈的感觉,那么我建议您使用 Apple 错误报告系统提交增强 radar。
我已经创建了一个带有 Apple Watch 扩展的应用程序。
我想知道是否可以安排只在 Apple Watch 上显示的通知。相反,我们可以安排一个通知只出现在 iPhone 上吗?
在 Apple 官方文档中,他们说:
Apple Watch takes full advantage of the existing interactive notification support on iOS. If your iOS app supports notifications, Apple Watch displays those notifications at appropriate times. When one of your app’s local or remote notifications arrives on the user’s iPhone, iOS decides whether to display that notification on the iPhone or on the Apple Watch. For notifications sent to Apple Watch, the system lets the the user know subtly that a notification is available. If the user chooses to view the notification, the system displays an abbreviated version of the notification first, followed by a more detailed version. The user can dismiss the detailed notification, launch your WatchKit app, or act on the notification by tapping an available action button.
所以我认为你可以告诉 iOS 你的通知行为(当你的应用程序的本地或远程通知之一到达用户的 iPhone、iOS 决定是否在 iPhone 上显示该通知 或在 Apple Watch 上。对于发送到 Apple Watch 的通知, 系统让用户巧妙地知道通知可用。)
这是一个很好的问题,但遗憾的是目前无法解决。苹果正试图在如何引导通知方面非常务实。如果您 iPhone 已解锁,他们会假设您正在查看它并将通知发送到那里。如果您 iPhone 被锁定,那么所有通知都将发送到您的 Apple Watch。他们希望不惜一切代价避免在两个位置重复通知。
目前无法强制将远程或本地通知直接路由到 Watch。如果您对这个功能有强烈的感觉,那么我建议您使用 Apple 错误报告系统提交增强 radar。