(events)
| 3411 | }; |
| 3412 | |
| 3413 | function runEventsInBatch(events) { |
| 3414 | if (events !== null) { |
| 3415 | eventQueue = accumulateInto(eventQueue, events); |
| 3416 | } // Set `eventQueue` to null before processing it so that we can tell if more |
| 3417 | // events get enqueued while processing. |
| 3418 | |
| 3419 | |
| 3420 | var processingEventQueue = eventQueue; |
| 3421 | eventQueue = null; |
| 3422 | |
| 3423 | if (!processingEventQueue) { |
| 3424 | return; |
| 3425 | } |
| 3426 | |
| 3427 | forEachAccumulated(processingEventQueue, executeDispatchesAndReleaseTopLevel); |
| 3428 | |
| 3429 | if (!!eventQueue) { |
| 3430 | { |
| 3431 | throw Error( "processEventQueue(): Additional events were enqueued while processing an event queue. Support for this has not yet been implemented." ); |
| 3432 | } |
| 3433 | } // This would be a good time to rethrow if any of the event handlers threw. |
| 3434 | |
| 3435 | |
| 3436 | rethrowCaughtError(); |
| 3437 | } |
| 3438 | |
| 3439 | /** |
| 3440 | * Gets the target node from a native browser event by accounting for |
no test coverage detected