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

Side by Side Diff: third_party/WebKit/Source/core/xmlhttprequest/XMLHttpRequestProgressEventThrottle.cpp

Issue 2068053002: Rename Blink constants generated from IDL files. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix unintended exception message change Created 4 years, 4 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 /* 1 /*
2 * Copyright (C) 2010 Julien Chaffraix <jchaffraix@webkit.org> All right reserv ed. 2 * Copyright (C) 2010 Julien Chaffraix <jchaffraix@webkit.org> All right reserv ed.
3 * Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies) 3 * Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies)
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. 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 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after
120 // the event handler calls xhr.abort()). In such cases a 120 // the event handler calls xhr.abort()). In such cases a
121 // readystatechange should have been already dispatched if necessary. 121 // readystatechange should have been already dispatched if necessary.
122 InspectorInstrumentation::AsyncTask asyncTask(m_target->getExecutionCont ext(), m_target, m_target->isAsync()); 122 InspectorInstrumentation::AsyncTask asyncTask(m_target->getExecutionCont ext(), m_target, m_target->isAsync());
123 m_target->dispatchEvent(event); 123 m_target->dispatchEvent(event);
124 } 124 }
125 } 125 }
126 126
127 void XMLHttpRequestProgressEventThrottle::dispatchProgressProgressEvent(Event* p rogressEvent) 127 void XMLHttpRequestProgressEventThrottle::dispatchProgressProgressEvent(Event* p rogressEvent)
128 { 128 {
129 XMLHttpRequest::State state = m_target->readyState(); 129 XMLHttpRequest::State state = m_target->readyState();
130 if (m_target->readyState() == XMLHttpRequest::LOADING && m_hasDispatchedProg ressProgressEvent) { 130 if (m_target->readyState() == XMLHttpRequest::kLoading && m_hasDispatchedPro gressProgressEvent) {
131 TRACE_EVENT1("devtools.timeline", "XHRReadyStateChange", "data", Inspect orXhrReadyStateChangeEvent::data(m_target->getExecutionContext(), m_target)); 131 TRACE_EVENT1("devtools.timeline", "XHRReadyStateChange", "data", Inspect orXhrReadyStateChangeEvent::data(m_target->getExecutionContext(), m_target));
132 InspectorInstrumentation::AsyncTask asyncTask(m_target->getExecutionCont ext(), m_target, m_target->isAsync()); 132 InspectorInstrumentation::AsyncTask asyncTask(m_target->getExecutionCont ext(), m_target, m_target->isAsync());
133 m_target->dispatchEvent(Event::create(EventTypeNames::readystatechange)) ; 133 m_target->dispatchEvent(Event::create(EventTypeNames::readystatechange)) ;
134 TRACE_EVENT_INSTANT1(TRACE_DISABLED_BY_DEFAULT("devtools.timeline"), "Up dateCounters", TRACE_EVENT_SCOPE_THREAD, "data", InspectorUpdateCountersEvent::d ata()); 134 TRACE_EVENT_INSTANT1(TRACE_DISABLED_BY_DEFAULT("devtools.timeline"), "Up dateCounters", TRACE_EVENT_SCOPE_THREAD, "data", InspectorUpdateCountersEvent::d ata());
135 } 135 }
136 136
137 if (m_target->readyState() != state) 137 if (m_target->readyState() != state)
138 return; 138 return;
139 139
140 m_hasDispatchedProgressProgressEvent = true; 140 m_hasDispatchedProgressProgressEvent = true;
(...skipping 30 matching lines...) Expand all
171 // event-handler could insert new active DOM objects to the list. 171 // event-handler could insert new active DOM objects to the list.
172 startOneShot(0, BLINK_FROM_HERE); 172 startOneShot(0, BLINK_FROM_HERE);
173 } 173 }
174 174
175 DEFINE_TRACE(XMLHttpRequestProgressEventThrottle) 175 DEFINE_TRACE(XMLHttpRequestProgressEventThrottle)
176 { 176 {
177 visitor->trace(m_target); 177 visitor->trace(m_target);
178 } 178 }
179 179
180 } // namespace blink 180 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698