| Index: chrome/browser/notifications/notification_ui_manager.cc
|
| ===================================================================
|
| --- chrome/browser/notifications/notification_ui_manager.cc (revision 30967)
|
| +++ chrome/browser/notifications/notification_ui_manager.cc (working copy)
|
| @@ -58,6 +58,18 @@
|
| CheckAndShowNotifications();
|
| }
|
|
|
| +bool NotificationUIManager::Cancel(const Notification& notification) {
|
| + // First look through the notifications that haven't been shown.
|
| + NotificationDeque::iterator iter;
|
| + for (iter = show_queue_.begin(); iter != show_queue_.end(); ++iter) {
|
| + if (notification.IsSame((*iter)->notification())) {
|
| + show_queue_.erase(iter);
|
| + return true;
|
| + }
|
| + }
|
| + return balloon_collection_->Remove(notification);
|
| +}
|
| +
|
| void NotificationUIManager::CheckAndShowNotifications() {
|
| // TODO(johnnyg): http://crbug.com/25061 - Check for user idle/presentation.
|
| ShowNotifications();
|
|
|