【发布时间】:2015-05-04 15:17:10
【问题描述】:
当用户在 Android Wear 中滑动到通知的下一页时,我需要实现一个活动来显示一些项目列表。这怎么可能?
现在我们可以在添加的通知页面上添加按钮。请帮助我。
【问题讨论】:
标签: android notifications android-notifications wear-os android-wear-notification
当用户在 Android Wear 中滑动到通知的下一页时,我需要实现一个活动来显示一些项目列表。这怎么可能?
现在我们可以在添加的通知页面上添加按钮。请帮助我。
【问题讨论】:
标签: android notifications android-notifications wear-os android-wear-notification
您需要致电setDisplayIntent,将您要启动的Activity 的PendingIntent 提供给WearableExtender。例如
wearableExtender.setDisplayIntent(activityPendingIntent);
wearableExtender.setCustomSizePreset(Notification.WearableExtender.SIZE_FULL_SCREEN);
需要第二行才能全屏显示Activity
【讨论】:
action吗? 当我点击那个按钮时,我调用一个类并执行相同的方法:你在调用哪个?您介意发布不起作用的代码吗?