OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 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 170 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
181 explicit EventQueue(EventTarget*); | 181 explicit EventQueue(EventTarget*); |
182 | 182 |
183 // Dispatches queued events if this queue is active. | 183 // Dispatches queued events if this queue is active. |
184 // Does nothing otherwise. | 184 // Does nothing otherwise. |
185 void dispatchQueuedEvents(); | 185 void dispatchQueuedEvents(); |
186 void resumeTimerFired(TimerBase*); | 186 void resumeTimerFired(TimerBase*); |
187 | 187 |
188 State m_state; | 188 State m_state; |
189 Member<EventTarget> m_target; | 189 Member<EventTarget> m_target; |
190 HeapDeque<Member<Event>> m_events; | 190 HeapDeque<Member<Event>> m_events; |
191 Timer<EventQueue> m_resumeTimer; | 191 TaskRunnerTimer<EventQueue> m_resumeTimer; |
192 }; | 192 }; |
193 | 193 |
194 enum WebSocketSendType { | 194 enum WebSocketSendType { |
195 WebSocketSendTypeString, | 195 WebSocketSendTypeString, |
196 WebSocketSendTypeArrayBuffer, | 196 WebSocketSendTypeArrayBuffer, |
197 WebSocketSendTypeArrayBufferView, | 197 WebSocketSendTypeArrayBufferView, |
198 WebSocketSendTypeBlob, | 198 WebSocketSendTypeBlob, |
199 WebSocketSendTypeMax, | 199 WebSocketSendTypeMax, |
200 }; | 200 }; |
201 | 201 |
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
246 // later. It will be cleared once reflected. | 246 // later. It will be cleared once reflected. |
247 uint64_t m_consumedBufferedAmount; | 247 uint64_t m_consumedBufferedAmount; |
248 uint64_t m_bufferedAmountAfterClose; | 248 uint64_t m_bufferedAmountAfterClose; |
249 BinaryType m_binaryType; | 249 BinaryType m_binaryType; |
250 int m_binaryTypeChangesAfterOpen; | 250 int m_binaryTypeChangesAfterOpen; |
251 // The subprotocol the server selected. | 251 // The subprotocol the server selected. |
252 String m_subprotocol; | 252 String m_subprotocol; |
253 String m_extensions; | 253 String m_extensions; |
254 | 254 |
255 Member<EventQueue> m_eventQueue; | 255 Member<EventQueue> m_eventQueue; |
256 Timer<DOMWebSocket> m_bufferedAmountConsumeTimer; | 256 TaskRunnerTimer<DOMWebSocket> m_bufferedAmountConsumeTimer; |
257 }; | 257 }; |
258 | 258 |
259 } // namespace blink | 259 } // namespace blink |
260 | 260 |
261 #endif // DOMWebSocket_h | 261 #endif // DOMWebSocket_h |
OLD | NEW |