| Index: ash/system/chromeos/session/tray_session_length_limit.cc
|
| diff --git a/ash/system/chromeos/session/tray_session_length_limit.cc b/ash/system/chromeos/session/tray_session_length_limit.cc
|
| index 6666c021c3b61d0a8ebbed1ebdd8c8d8d6b97d55..136c75bb361185570709027f83197898d21ba5d7 100644
|
| --- a/ash/system/chromeos/session/tray_session_length_limit.cc
|
| +++ b/ash/system/chromeos/session/tray_session_length_limit.cc
|
| @@ -123,7 +123,7 @@ void TraySessionLengthLimit::UpdateNotification() {
|
| // If state hasn't changed and the notification has already been acknowledged,
|
| // we won't re-create it.
|
| if (limit_state_ == last_limit_state_ &&
|
| - !message_center->HasNotification(kNotificationId)) {
|
| + message_center->FindVisibleNotificationById(kNotificationId) == NULL) {
|
| return;
|
| }
|
|
|
| @@ -132,7 +132,7 @@ void TraySessionLengthLimit::UpdateNotification() {
|
| // (and in the rare case of state change towards LIMIT_NONE to make the
|
| // notification disappear).
|
| if (limit_state_ != last_limit_state_ &&
|
| - message_center->HasNotification(kNotificationId)) {
|
| + message_center->FindVisibleNotificationById(kNotificationId) != NULL) {
|
| message_center::MessageCenter::Get()->RemoveNotification(
|
| kNotificationId, false /* by_user */);
|
| }
|
| @@ -162,7 +162,7 @@ void TraySessionLengthLimit::UpdateNotification() {
|
| data,
|
| NULL /* delegate */));
|
| notification->SetSystemPriority();
|
| - if (message_center->HasNotification(kNotificationId))
|
| + if (message_center->FindVisibleNotificationById(kNotificationId) != NULL)
|
| message_center->UpdateNotification(kNotificationId, notification.Pass());
|
| else
|
| message_center->AddNotification(notification.Pass());
|
|
|