看着是没问题,不知道楼主可以提供更多的代码吗?

解决方案 »

  1.   

    不好意思,最近挺忙的Intent intent = new Intent(SystemNotificationActivity.this,
    OtherActivity.class);
    PendingIntent pi = PendingIntent.getActivity(
    SystemNotificationActivity.this, 0, intent, 0);
    Notification notify = new Notification();
    notify.icon = R.drawable.ic_launcher;
    notify.tickerText = "XXX";
    notify.when = System.currentTimeMillis();
    notify.defaults = Notification.DEFAULT_VIBRATE;
    notify.ledARGB = Color.BLUE;  //这里是颜色,我们可以尝试改变,理论上0xFF0000是红色,0x00FF00是绿色
    notify.ledOnMS = 300; 
    notify.ledOffMS = 1000;
    notify.flags = Notification.FLAG_SHOW_LIGHTS | Notification.FLAG_ONGOING_EVENT;
    notify.setLatestEventInfo(SystemNotificationActivity.this,
    "YYY~", "ZZZ", pi);
    NotificationManager notificationManager = (NotificationManager) getSystemService(NOTIFICATION_SERVICE);
    notificationManager.notify(NOTIFICATION_ID, notify);
      

  2.   


    楼主,认识我不- -两次发帖都是下班时间,不错哟
      

  3.   

    我也遇到和楼主一样的问题,请问楼主现在问题解决了吗?