我已经创建了Android穿戴通知。通知正常出来。我还为通知添加了addAction。我有两个问题:Android穿戴通知
我不知道为什么我收到了三滑页(在底部的三个点),
a. Notificaiton text b. A black background image (second slide) c. Add action button (third slide)
我想上的通知点击打开新意图它不工作:
这是我曾尝试代码:
Intent notificationIntent = new Intent(this, Wear.class);
PendingIntent contentIntent = PendingIntent.getActivity(this, 0, notificationIntent, 0);
int notificationId = 001;
Bitmap background = BitmapFactory.decodeResource(getResources(), R.drawable.backgroundwatch);
NotificationCompat.Builder notificationBuilder =
new NotificationCompat.Builder(this)
.setSmallIcon(R.drawable.launchericon)
.setContentTitle("Mail ME")
.setContentText("Are you in need of help?? Click or slide to request help!")
.setLargeIcon(background)
.setStyle(new NotificationCompat.BigPictureStyle().bigPicture(background))
.addAction(R.drawable.launchericon,"Help", contentIntent);
我不知道我哪里出错了?
谢谢!
在你问你关于android战争的问题,和android穿在你的描述中,你在说什么;);) –
你试过.show()方法吗? –