am 68c3c751: Use LED for notification (same parameters as Gmail and GTalk services)

Merge commit '68c3c7518e132bdbfd17a0b122fbe09c08e0acdc'

* commit '68c3c7518e132bdbfd17a0b122fbe09c08e0acdc':
  Use LED for notification (same parameters as Gmail and GTalk services)
This commit is contained in:
Marc Blank 2009-08-25 11:11:22 -07:00 committed by Android Git Automerger
commit e996b7f455

View File

@ -578,9 +578,16 @@ public class MailService extends Service {
pending); pending);
notification.sound = ringtone; notification.sound = ringtone;
notification.defaults = vibrate // Use same code here as in Gmail and GTalk for vibration
? Notification.DEFAULT_LIGHTS | Notification.DEFAULT_VIBRATE if (vibrate) {
: Notification.DEFAULT_LIGHTS; notification.defaults |= Notification.DEFAULT_VIBRATE;
}
// This code is identical to that used by Gmail and GTalk for notifications
notification.flags |= Notification.FLAG_SHOW_LIGHTS;
notification.ledARGB = 0xff00ff00;
notification.ledOnMS = 500;
notification.ledOffMS = 2000;
NotificationManager notificationManager = NotificationManager notificationManager =
(NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE); (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);