代码在我的服务的Oncreate里面
Intent intent = new Intent(this,MainActivity.class);
PendingIntent pendingIntent = PendingIntent.getActivity(this,0,intent,0);
Notification notification = new NotificationCompat.Builder(this)
.setContentTitle("TITLE")
.setContentText("TEXT")
.setContentIntent(pendingIntent)
.build();
startForeground(1,notification);
但是通知并非我的内容 而是
“MUSICPLAYER”正在运行
点击了解详情或停止应用