if (record == null || record.getNotification() == null) {
if (DBG) Slog.d(TAG, "skipping empty notification");
return null;
}
final Notification notification = record.getNotification();
if ((notification.defaults & Notification.DEFAULT_VIBRATE) != 0 ||
notification.vibrate != null ||
(notification.defaults & Notification.DEFAULT_SOUND) != 0 ||
notification.sound != null ||
notification.fullScreenIntent != null) {
record.setRecentlyIntusive(true);
}
return new RankingReconsideration(record.getKey(), HANG_TIME_MS) {
@Override
public void work() {
// pass
}
@Override
public void applyChangesLocked(NotificationRecord record) {
record.setRecentlyIntusive(false);
}
};