[英]Open corresponding app on Handheld without notification from Android Wearable (Gear live)
I would like to develop an app on the wearable wich should be able to launch an app on my Handheld device, without the notification standard ("open on device") action. 我想在可穿戴设备上开发一个应用程序,应该能够在我的手持设备上启动一个应用程序,而无需执行通知标准(“在设备上打开”)操作。 It should start the app on the handheld, even if the Handheld App is closed at the moment. 即使此时手持式应用程序已关闭,它也应在手持式计算机上启动该应用程序。 Is there a solution to achieve this. 是否有解决方案来实现这一目标。 I can't find it in the documentation. 我在文档中找不到它。 If I overread that in the official doc., please post a link. 如果我在官方文档中过度阅读了该文章,请发布链接。
To do that, you have to use the Wearable Data Layer API . 为此,您必须使用Wearable Data Layer API 。
Just send a message using the Message API from the Android Wear device to the handheld's one. 只需使用Message API将消息从Android Wear设备发送到掌上电脑的设备即可。 The WearableListenerService of your handheld app can then launch an Intent
to open the app. 然后,您的手持式应用程序的WearableListenerService可以启动一个Intent
以打开该应用程序。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.