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

Side by Side Diff: ui/message_center/views/message_popup_collection.cc

Issue 1868363002: Replace scoped_ptr with std::unique_ptr in //ui (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@scopedptrcc
Patch Set: scopedptrui: rebase-make_scoped_ptr Created 4 years, 8 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ui/message_center/views/message_popup_collection.h" 5 #include "ui/message_center/views/message_popup_collection.h"
6 6
7 #include <set> 7 #include <set>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/i18n/rtl.h" 10 #include "base/i18n/rtl.h"
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
97 // Don't remove the notification only when it's not pinned. 97 // Don't remove the notification only when it's not pinned.
98 if (!notification->pinned()) 98 if (!notification->pinned())
99 message_center_->RemoveNotification(notification_id, by_user); 99 message_center_->RemoveNotification(notification_id, by_user);
100 else 100 else
101 message_center_->MarkSinglePopupAsShown(notification_id, true /* read */); 101 message_center_->MarkSinglePopupAsShown(notification_id, true /* read */);
102 102
103 break; 103 break;
104 } 104 }
105 } 105 }
106 106
107 scoped_ptr<ui::MenuModel> MessagePopupCollection::CreateMenuModel( 107 std::unique_ptr<ui::MenuModel> MessagePopupCollection::CreateMenuModel(
108 const NotifierId& notifier_id, 108 const NotifierId& notifier_id,
109 const base::string16& display_source) { 109 const base::string16& display_source) {
110 return tray_->CreateNotificationMenuModel(notifier_id, display_source); 110 return tray_->CreateNotificationMenuModel(notifier_id, display_source);
111 } 111 }
112 112
113 bool MessagePopupCollection::HasClickedListener( 113 bool MessagePopupCollection::HasClickedListener(
114 const std::string& notification_id) { 114 const std::string& notification_id) {
115 return message_center_->HasClickedListener(notification_id); 115 return message_center_->HasClickedListener(notification_id);
116 } 116 }
117 117
(...skipping 420 matching lines...) Expand 10 before | Expand all | Expand 10 after
538 views::Widget* widget = (*iter)->GetWidget(); 538 views::Widget* widget = (*iter)->GetWidget();
539 if (widget) 539 if (widget)
540 return widget->GetWindowBoundsInScreen(); 540 return widget->GetWindowBoundsInScreen();
541 break; 541 break;
542 } 542 }
543 } 543 }
544 return gfx::Rect(); 544 return gfx::Rect();
545 } 545 }
546 546
547 } // namespace message_center 547 } // namespace message_center
OLDNEW
« no previous file with comments | « ui/message_center/views/message_popup_collection.h ('k') | ui/message_center/views/message_popup_collection_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698