| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2010 Julien Chaffraix <jchaffraix@webkit.org> | 2 * Copyright (C) 2010 Julien Chaffraix <jchaffraix@webkit.org> |
| 3 * All right reserved. | 3 * All right reserved. |
| 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 20 matching lines...) Expand all Loading... |
| 31 #include "platform/heap/Handle.h" | 31 #include "platform/heap/Handle.h" |
| 32 #include "wtf/OwnPtr.h" | 32 #include "wtf/OwnPtr.h" |
| 33 #include "wtf/PassRefPtr.h" | 33 #include "wtf/PassRefPtr.h" |
| 34 #include "wtf/Vector.h" | 34 #include "wtf/Vector.h" |
| 35 #include "wtf/text/AtomicString.h" | 35 #include "wtf/text/AtomicString.h" |
| 36 | 36 |
| 37 namespace blink { | 37 namespace blink { |
| 38 | 38 |
| 39 class Event; | 39 class Event; |
| 40 class EventTarget; | 40 class EventTarget; |
| 41 class XMLHttpRequestProgressEvent; | |
| 42 | 41 |
| 43 // This class implements the XHR2 ProgressEvent dispatching: | 42 // This class implements the XHR2 ProgressEvent dispatching: |
| 44 // "dispatch a progress event named progress about every 50ms or for every | 43 // "dispatch a progress event named progress about every 50ms or for every |
| 45 // byte received, whichever is least frequent". | 44 // byte received, whichever is least frequent". |
| 46 // | 45 // |
| 47 // readystatechange events also go through this class since ProgressEvents and | 46 // readystatechange events also go through this class since ProgressEvents and |
| 48 // readystatechange events affect each other. | 47 // readystatechange events affect each other. |
| 49 // | 48 // |
| 50 // In the comments for this class: | 49 // In the comments for this class: |
| 51 // - "progress" event means an event named "progress" | 50 // - "progress" event means an event named "progress" |
| (...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 98 RawPtrWillBeMember<EventTarget> m_target; | 97 RawPtrWillBeMember<EventTarget> m_target; |
| 99 | 98 |
| 100 // A slot for the deferred "progress" ProgressEvent. When multiple events | 99 // A slot for the deferred "progress" ProgressEvent. When multiple events |
| 101 // arrive, only the last one is stored and others are discarded. | 100 // arrive, only the last one is stored and others are discarded. |
| 102 const OwnPtr<DeferredEvent> m_deferred; | 101 const OwnPtr<DeferredEvent> m_deferred; |
| 103 }; | 102 }; |
| 104 | 103 |
| 105 } // namespace blink | 104 } // namespace blink |
| 106 | 105 |
| 107 #endif // XMLHttpRequestProgressEventThrottle_h | 106 #endif // XMLHttpRequestProgressEventThrottle_h |
| OLD | NEW |