| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2010 Julien Chaffraix <jchaffraix@webkit.org> All right | 2 * Copyright (C) 2010 Julien Chaffraix <jchaffraix@webkit.org> All right |
| 3 * reserved. | 3 * reserved. |
| 4 * Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies) | 4 * Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies) |
| 5 * | 5 * |
| 6 * Redistribution and use in source and binary forms, with or without | 6 * Redistribution and use in source and binary forms, with or without |
| 7 * modification, are permitted provided that the following conditions | 7 * modification, are permitted provided that the following conditions |
| 8 * are met: | 8 * are met: |
| 9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. Redistributions of source code must retain the above copyright |
| 10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
| (...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 141 Event* progressEvent) { | 141 Event* progressEvent) { |
| 142 XMLHttpRequest::State state = m_target->readyState(); | 142 XMLHttpRequest::State state = m_target->readyState(); |
| 143 if (m_target->readyState() == XMLHttpRequest::kLoading && | 143 if (m_target->readyState() == XMLHttpRequest::kLoading && |
| 144 m_hasDispatchedProgressProgressEvent) { | 144 m_hasDispatchedProgressProgressEvent) { |
| 145 TRACE_EVENT1("devtools.timeline", "XHRReadyStateChange", "data", | 145 TRACE_EVENT1("devtools.timeline", "XHRReadyStateChange", "data", |
| 146 InspectorXhrReadyStateChangeEvent::data( | 146 InspectorXhrReadyStateChangeEvent::data( |
| 147 m_target->getExecutionContext(), m_target)); | 147 m_target->getExecutionContext(), m_target)); |
| 148 probe::AsyncTask asyncTask(m_target->getExecutionContext(), m_target, | 148 probe::AsyncTask asyncTask(m_target->getExecutionContext(), m_target, |
| 149 m_target->isAsync()); | 149 m_target->isAsync()); |
| 150 m_target->dispatchEvent(Event::create(EventTypeNames::readystatechange)); | 150 m_target->dispatchEvent(Event::create(EventTypeNames::readystatechange)); |
| 151 TRACE_EVENT_INSTANT1(TRACE_DISABLED_BY_DEFAULT("devtools.timeline"), | |
| 152 "UpdateCounters", TRACE_EVENT_SCOPE_THREAD, "data", | |
| 153 InspectorUpdateCountersEvent::data()); | |
| 154 } | 151 } |
| 155 | 152 |
| 156 if (m_target->readyState() != state) | 153 if (m_target->readyState() != state) |
| 157 return; | 154 return; |
| 158 | 155 |
| 159 m_hasDispatchedProgressProgressEvent = true; | 156 m_hasDispatchedProgressProgressEvent = true; |
| 160 probe::AsyncTask asyncTask(m_target->getExecutionContext(), m_target, | 157 probe::AsyncTask asyncTask(m_target->getExecutionContext(), m_target, |
| 161 m_target->isAsync()); | 158 m_target->isAsync()); |
| 162 m_target->dispatchEvent(progressEvent); | 159 m_target->dispatchEvent(progressEvent); |
| 163 } | 160 } |
| (...skipping 24 matching lines...) Expand all Loading... |
| 188 // over the list of SuspendableObjects to resume them, and any activated JS | 185 // over the list of SuspendableObjects to resume them, and any activated JS |
| 189 // event-handler could insert new SuspendableObjects to the list. | 186 // event-handler could insert new SuspendableObjects to the list. |
| 190 startOneShot(0, BLINK_FROM_HERE); | 187 startOneShot(0, BLINK_FROM_HERE); |
| 191 } | 188 } |
| 192 | 189 |
| 193 DEFINE_TRACE(XMLHttpRequestProgressEventThrottle) { | 190 DEFINE_TRACE(XMLHttpRequestProgressEventThrottle) { |
| 194 visitor->trace(m_target); | 191 visitor->trace(m_target); |
| 195 } | 192 } |
| 196 | 193 |
| 197 } // namespace blink | 194 } // namespace blink |
| OLD | NEW |