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

Side by Side Diff: ui/message_center/views/message_center_view.h

Issue 2833403002: [Notifications] Fix crash in AddNotification. (Closed)
Patch Set: Add TODO Created 3 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
« no previous file with comments | « no previous file | ui/message_center/views/message_center_view.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 #ifndef UI_MESSAGE_CENTER_VIEWS_MESSAGE_CENTER_VIEW_H_ 5 #ifndef UI_MESSAGE_CENTER_VIEWS_MESSAGE_CENTER_VIEW_H_
6 #define UI_MESSAGE_CENTER_VIEWS_MESSAGE_CENTER_VIEW_H_ 6 #define UI_MESSAGE_CENTER_VIEWS_MESSAGE_CENTER_VIEW_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after
115 115
116 static bool disable_animation_for_testing; 116 static bool disable_animation_for_testing;
117 117
118 void AddNotificationAt(const Notification& notification, int index); 118 void AddNotificationAt(const Notification& notification, int index);
119 base::string16 GetButtonBarTitle() const; 119 base::string16 GetButtonBarTitle() const;
120 void Update(bool animate); 120 void Update(bool animate);
121 void SetVisibilityMode(Mode mode, bool animate); 121 void SetVisibilityMode(Mode mode, bool animate);
122 void UpdateButtonBarStatus(); 122 void UpdateButtonBarStatus();
123 void EnableCloseAllIfAppropriate(); 123 void EnableCloseAllIfAppropriate();
124 void SetNotificationViewForTest(MessageView* view); 124 void SetNotificationViewForTest(MessageView* view);
125 void UpdateNotification(const std::string& notification_id);
125 126
126 MessageCenter* message_center_; // Weak reference. 127 MessageCenter* message_center_; // Weak reference.
127 MessageCenterTray* tray_; // Weak reference. 128 MessageCenterTray* tray_; // Weak reference.
128 129
129 // Map notification_id->MessageView*. It contains all MessageViews currently 130 // Map notification_id->MessageView*. It contains all MessageViews currently
130 // displayed in MessageCenter. 131 // displayed in MessageCenter.
131 typedef std::map<std::string, MessageView*> NotificationViewsMap; 132 typedef std::map<std::string, MessageView*> NotificationViewsMap;
132 NotificationViewsMap notification_views_; // Weak. 133 NotificationViewsMap notification_views_; // Weak.
133 134
134 // Child views. 135 // Child views.
(...skipping 29 matching lines...) Expand all
164 std::unique_ptr<MessageViewContextMenuController> context_menu_controller_; 165 std::unique_ptr<MessageViewContextMenuController> context_menu_controller_;
165 166
166 views::FocusManager* focus_manager_ = nullptr; 167 views::FocusManager* focus_manager_ = nullptr;
167 168
168 DISALLOW_COPY_AND_ASSIGN(MessageCenterView); 169 DISALLOW_COPY_AND_ASSIGN(MessageCenterView);
169 }; 170 };
170 171
171 } // namespace message_center 172 } // namespace message_center
172 173
173 #endif // UI_MESSAGE_CENTER_VIEWS_MESSAGE_CENTER_VIEW_H_ 174 #endif // UI_MESSAGE_CENTER_VIEWS_MESSAGE_CENTER_VIEW_H_
OLDNEW
« no previous file with comments | « no previous file | ui/message_center/views/message_center_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698