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

Side by Side Diff: third_party/WebKit/Source/modules/notifications/Notification.cpp

Issue 2567913002: Rename ActiveDOMObject to SuspendableObject (Closed)
Patch Set: Created 4 years 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 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 notification->setNotificationId(notificationId); 128 notification->setNotificationId(notificationId);
129 129
130 notification->suspendIfNeeded(); 130 notification->suspendIfNeeded();
131 return notification; 131 return notification;
132 } 132 }
133 133
134 Notification::Notification(ExecutionContext* context, 134 Notification::Notification(ExecutionContext* context,
135 Type type, 135 Type type,
136 const WebNotificationData& data) 136 const WebNotificationData& data)
137 : ActiveScriptWrappable(this), 137 : ActiveScriptWrappable(this),
138 ActiveDOMObject(context), 138 SuspendableObject(context),
139 m_type(type), 139 m_type(type),
140 m_state(State::Loading), 140 m_state(State::Loading),
141 m_data(data) { 141 m_data(data) {
142 DCHECK(notificationManager()); 142 DCHECK(notificationManager());
143 } 143 }
144 144
145 Notification::~Notification() {} 145 Notification::~Notification() {}
146 146
147 void Notification::schedulePrepareShow() { 147 void Notification::schedulePrepareShow() {
148 DCHECK_EQ(m_state, State::Loading); 148 DCHECK_EQ(m_state, State::Loading);
(...skipping 248 matching lines...) Expand 10 before | Expand all | Expand 10 after
397 if (m_type == Type::NonPersistent) 397 if (m_type == Type::NonPersistent)
398 return m_state != State::Closed; 398 return m_state != State::Closed;
399 399
400 return false; 400 return false;
401 } 401 }
402 402
403 DEFINE_TRACE(Notification) { 403 DEFINE_TRACE(Notification) {
404 visitor->trace(m_prepareShowMethodRunner); 404 visitor->trace(m_prepareShowMethodRunner);
405 visitor->trace(m_loader); 405 visitor->trace(m_loader);
406 EventTargetWithInlineData::trace(visitor); 406 EventTargetWithInlineData::trace(visitor);
407 ActiveDOMObject::trace(visitor); 407 SuspendableObject::trace(visitor);
408 } 408 }
409 409
410 } // namespace blink 410 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698