标签:android style io color 使用 sp on div cti
//发送通知
NotificationManager manger = (NotificationManager) this.getSystemService(NOTIFICATION_SERVICE);
Notification noti = new Notification(R.drawable.icon,"电话录音",System.currentTimeMillis());
Intent it = new Intent();
it.setClass(this, MainActivity.class);//点击通知后要跳向的页面
PendingIntent pi = PendingIntent.getActivity(this, 0, it, 0);
noti.setLatestEventInfo(this, "电话录音", "正在监听...", pi);
noti.defaults = Notification.DEFAULT_ALL;//有4种
manger.notify(10, noti);// id=10
//取消
NotificationManager manger = (NotificationManager)this.getSystemService(NOTIFICATION_SERVICE);
manger.cancel(10);
Android Notification使用及取消
标签:android style io color 使用 sp on div cti
原文地址:http://www.cnblogs.com/dongweiq/p/4125894.html