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

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

Issue 1750323002: Keep XHR progress throttle interval an implementation detail. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 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> 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 92 matching lines...) Expand 10 before | Expand all | Expand 10 after
103 PassRefPtrWillBeRawPtr<Event> take(); 103 PassRefPtrWillBeRawPtr<Event> take();
104 104
105 private: 105 private:
106 unsigned long long m_loaded; 106 unsigned long long m_loaded;
107 unsigned long long m_total; 107 unsigned long long m_total;
108 bool m_lengthComputable; 108 bool m_lengthComputable;
109 109
110 bool m_isSet; 110 bool m_isSet;
111 }; 111 };
112 112
113 static const double minimumProgressEventDispatchingIntervalInSeconds;
114
115 void fired() override; 113 void fired() override;
116 114
117 Member<XMLHttpRequest> m_target; 115 Member<XMLHttpRequest> m_target;
118 116
119 // A slot for the deferred "progress" ProgressEvent. When multiple events 117 // A slot for the deferred "progress" ProgressEvent. When multiple events
120 // arrive, only the last one is stored and others are discarded. 118 // arrive, only the last one is stored and others are discarded.
121 DeferredEvent m_deferred; 119 DeferredEvent m_deferred;
122 120
123 // True if any "progress" progress event has been dispatched since 121 // True if any "progress" progress event has been dispatched since
124 // |m_target|'s readyState changed. 122 // |m_target|'s readyState changed.
125 bool m_hasDispatchedProgressProgressEvent; 123 bool m_hasDispatchedProgressProgressEvent;
126 }; 124 };
127 125
128 } // namespace blink 126 } // namespace blink
129 127
130 #endif // XMLHttpRequestProgressEventThrottle_h 128 #endif // XMLHttpRequestProgressEventThrottle_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698