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

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

Issue 2337963003: Plumb through notification action types and placeholders on Android (Closed)
Patch Set: Put =default back in .cc file Created 4 years, 2 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/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
11 namespace message_center { 11 namespace message_center {
12 12
13 namespace { 13 namespace {
14 14
15 unsigned g_next_serial_number_ = 0; 15 unsigned g_next_serial_number_ = 0;
16 16
17 } // namespace 17 } // namespace
18 18
19 NotificationItem::NotificationItem(const base::string16& title, 19 NotificationItem::NotificationItem(const base::string16& title,
20 const base::string16& message) 20 const base::string16& message)
21 : title(title), 21 : title(title),
22 message(message) { 22 message(message) {
23 } 23 }
24 24
25 ButtonInfo::ButtonInfo(const base::string16& title) 25 ButtonInfo::ButtonInfo(const base::string16& title)
26 : title(title) { 26 : title(title) {
27 } 27 }
28 28
29 ButtonInfo::ButtonInfo(const ButtonInfo& other) = default;
30
31 ButtonInfo::~ButtonInfo() = default;
32
33 ButtonInfo& ButtonInfo::operator=(const ButtonInfo& other) = default;
34
29 RichNotificationData::RichNotificationData() 35 RichNotificationData::RichNotificationData()
30 : priority(DEFAULT_PRIORITY), 36 : priority(DEFAULT_PRIORITY),
31 never_timeout(false), 37 never_timeout(false),
32 timestamp(base::Time::Now()), 38 timestamp(base::Time::Now()),
33 context_message(base::string16()), 39 context_message(base::string16()),
34 progress(0), 40 progress(0),
35 should_make_spoken_feedback_for_popup_updates(true), 41 should_make_spoken_feedback_for_popup_updates(true),
36 clickable(true), 42 clickable(true),
37 #if defined(OS_CHROMEOS) 43 #if defined(OS_CHROMEOS)
38 pinned(false), 44 pinned(false),
(...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after
177 NOTIFICATION_TYPE_SIMPLE, notification_id, title, message, icon, 183 NOTIFICATION_TYPE_SIMPLE, notification_id, title, message, icon,
178 base::string16() /* display_source */, GURL(), 184 base::string16() /* display_source */, GURL(),
179 NotifierId(NotifierId::SYSTEM_COMPONENT, system_component_id), 185 NotifierId(NotifierId::SYSTEM_COMPONENT, system_component_id),
180 RichNotificationData(), 186 RichNotificationData(),
181 new HandleNotificationClickedDelegate(click_callback))); 187 new HandleNotificationClickedDelegate(click_callback)));
182 notification->SetSystemPriority(); 188 notification->SetSystemPriority();
183 return notification; 189 return notification;
184 } 190 }
185 191
186 } // namespace message_center 192 } // namespace message_center
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698