所以我设置了一个 2 页的 Android 磨损通知(从设备发送):
final NotificationCompat.Builder mainNotificationBuilder = new NotificationCompat.Builder(this)
.setDefaults(android.app.Notification.DEFAULT_ALL)
.setSmallIcon(R.drawable.icon)
.setStyle(bigStyle)
.setContentIntent(contentIntent);
android.app.Notification secondNotification = new NotificationCompat.Builder(this)
.setSmallIcon(R.drawable.icon)
.setLargeIcon(balanceBackgroundImage)
.setStyle(bigStyle2)
.build();
android.app.Notification twoPageNotif = mainNotificationBuilder
.extend(new NotificationCompat.WearableExtender()
.setContentIcon(R.drawable.icon)
.setBackground(backgroundImage)
.addPage(secondNotification)
)
.setSmallIcon(R.drawable.icon)
.build();
但是,小图标只出现在第一页上,但我希望它出现在两个页面上!
这可能吗?我感觉不是,而且图标只能出现在多页 watch 通知的第一页,但我想得到大家的确认。
提前致谢:\
最佳答案
您的想法是正确的:小图标只出现在通知的首页。
关于具有多个页面的 Android Wear Smartwatch 通知 - 小图标仅显示在第一页上?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/27049147/