Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(242)

Unified Diff: ui/message_center/cocoa/popup_collection.mm

Issue 14735009: mac: Minor tweaks to notifications code. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: tweak text metrics Created 7 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/message_center/cocoa/notification_controller.mm ('k') | ui/message_center/message_center.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/message_center/cocoa/popup_collection.mm
diff --git a/ui/message_center/cocoa/popup_collection.mm b/ui/message_center/cocoa/popup_collection.mm
index 60547e0b95c0b448b14df1caeb1322dfe5135ff2..bf3df413235d10096f2b29e806c94bb543919ed1 100644
--- a/ui/message_center/cocoa/popup_collection.mm
+++ b/ui/message_center/cocoa/popup_collection.mm
@@ -51,10 +51,9 @@ class PopupCollectionObserver : public message_center::MessageCenterObserver {
virtual void OnNotificationAdded(
const std::string& notification_id) OVERRIDE {
- const auto& popups = message_center_->GetPopupNotifications();
- for (auto it = popups.begin(); it != popups.end(); ++it) {
- if ((*it)->id() == notification_id) {
- [popup_collection_ addNotification:*it];
+ for (const auto& notification : message_center_->GetPopupNotifications()) {
+ if (notification->id() == notification_id) {
+ [popup_collection_ addNotification:notification];
return;
}
}
« no previous file with comments | « ui/message_center/cocoa/notification_controller.mm ('k') | ui/message_center/message_center.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698