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

Side by Side Diff: ui/message_center/notification.cc

Issue 2143653007: Remove icon bg color for message center notifications. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 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 | « ui/message_center/notification.h ('k') | ui/message_center/views/notification_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 #include "ui/message_center/notification.h" 5 #include "ui/message_center/notification.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "ui/message_center/notification_delegate.h" 8 #include "ui/message_center/notification_delegate.h"
9 #include "ui/message_center/notification_types.h" 9 #include "ui/message_center/notification_types.h"
10 10
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 const base::string16& display_source, 70 const base::string16& display_source,
71 const GURL& origin_url, 71 const GURL& origin_url,
72 const NotifierId& notifier_id, 72 const NotifierId& notifier_id,
73 const RichNotificationData& optional_fields, 73 const RichNotificationData& optional_fields,
74 NotificationDelegate* delegate) 74 NotificationDelegate* delegate)
75 : type_(type), 75 : type_(type),
76 id_(id), 76 id_(id),
77 title_(title), 77 title_(title),
78 message_(message), 78 message_(message),
79 icon_(icon), 79 icon_(icon),
80 draw_icon_background_(true),
81 display_source_(display_source), 80 display_source_(display_source),
82 origin_url_(origin_url), 81 origin_url_(origin_url),
83 notifier_id_(notifier_id), 82 notifier_id_(notifier_id),
84 serial_number_(g_next_serial_number_++), 83 serial_number_(g_next_serial_number_++),
85 optional_fields_(optional_fields), 84 optional_fields_(optional_fields),
86 shown_as_popup_(false), 85 shown_as_popup_(false),
87 is_read_(false), 86 is_read_(false),
88 delegate_(delegate) {} 87 delegate_(delegate) {}
89 88
90 Notification::Notification(const std::string& id, const Notification& other) 89 Notification::Notification(const std::string& id, const Notification& other)
91 : type_(other.type_), 90 : type_(other.type_),
92 id_(id), 91 id_(id),
93 title_(other.title_), 92 title_(other.title_),
94 message_(other.message_), 93 message_(other.message_),
95 icon_(other.icon_), 94 icon_(other.icon_),
96 draw_icon_background_(other.draw_icon_background_),
97 display_source_(other.display_source_), 95 display_source_(other.display_source_),
98 origin_url_(other.origin_url_), 96 origin_url_(other.origin_url_),
99 notifier_id_(other.notifier_id_), 97 notifier_id_(other.notifier_id_),
100 serial_number_(other.serial_number_), 98 serial_number_(other.serial_number_),
101 optional_fields_(other.optional_fields_), 99 optional_fields_(other.optional_fields_),
102 shown_as_popup_(other.shown_as_popup_), 100 shown_as_popup_(other.shown_as_popup_),
103 is_read_(other.is_read_), 101 is_read_(other.is_read_),
104 delegate_(other.delegate_) {} 102 delegate_(other.delegate_) {}
105 103
106 Notification::Notification(const Notification& other) 104 Notification::Notification(const Notification& other)
107 : type_(other.type_), 105 : type_(other.type_),
108 id_(other.id_), 106 id_(other.id_),
109 title_(other.title_), 107 title_(other.title_),
110 message_(other.message_), 108 message_(other.message_),
111 icon_(other.icon_), 109 icon_(other.icon_),
112 draw_icon_background_(other.draw_icon_background_),
113 display_source_(other.display_source_), 110 display_source_(other.display_source_),
114 origin_url_(other.origin_url_), 111 origin_url_(other.origin_url_),
115 notifier_id_(other.notifier_id_), 112 notifier_id_(other.notifier_id_),
116 serial_number_(other.serial_number_), 113 serial_number_(other.serial_number_),
117 optional_fields_(other.optional_fields_), 114 optional_fields_(other.optional_fields_),
118 shown_as_popup_(other.shown_as_popup_), 115 shown_as_popup_(other.shown_as_popup_),
119 is_read_(other.is_read_), 116 is_read_(other.is_read_),
120 delegate_(other.delegate_) {} 117 delegate_(other.delegate_) {}
121 118
122 Notification& Notification::operator=(const Notification& other) { 119 Notification& Notification::operator=(const Notification& other) {
123 type_ = other.type_; 120 type_ = other.type_;
124 id_ = other.id_; 121 id_ = other.id_;
125 title_ = other.title_; 122 title_ = other.title_;
126 message_ = other.message_; 123 message_ = other.message_;
127 icon_ = other.icon_; 124 icon_ = other.icon_;
128 draw_icon_background_ = other.draw_icon_background_;
129 display_source_ = other.display_source_; 125 display_source_ = other.display_source_;
130 origin_url_ = other.origin_url_; 126 origin_url_ = other.origin_url_;
131 notifier_id_ = other.notifier_id_; 127 notifier_id_ = other.notifier_id_;
132 serial_number_ = other.serial_number_; 128 serial_number_ = other.serial_number_;
133 optional_fields_ = other.optional_fields_; 129 optional_fields_ = other.optional_fields_;
134 shown_as_popup_ = other.shown_as_popup_; 130 shown_as_popup_ = other.shown_as_popup_;
135 is_read_ = other.is_read_; 131 is_read_ = other.is_read_;
136 delegate_ = other.delegate_; 132 delegate_ = other.delegate_;
137 133
138 return *this; 134 return *this;
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
180 NOTIFICATION_TYPE_SIMPLE, notification_id, title, message, icon, 176 NOTIFICATION_TYPE_SIMPLE, notification_id, title, message, icon,
181 base::string16() /* display_source */, GURL(), 177 base::string16() /* display_source */, GURL(),
182 NotifierId(NotifierId::SYSTEM_COMPONENT, system_component_id), 178 NotifierId(NotifierId::SYSTEM_COMPONENT, system_component_id),
183 RichNotificationData(), 179 RichNotificationData(),
184 new HandleNotificationClickedDelegate(click_callback))); 180 new HandleNotificationClickedDelegate(click_callback)));
185 notification->SetSystemPriority(); 181 notification->SetSystemPriority();
186 return notification; 182 return notification;
187 } 183 }
188 184
189 } // namespace message_center 185 } // namespace message_center
OLDNEW
« no previous file with comments | « ui/message_center/notification.h ('k') | ui/message_center/views/notification_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698