(nativeEvent)
| 4702 | } |
| 4703 | |
| 4704 | function manualDispatchChangeEvent(nativeEvent) { |
| 4705 | var event = createAndAccumulateChangeEvent(activeElementInst, nativeEvent, getEventTarget(nativeEvent)); |
| 4706 | |
| 4707 | // If change and propertychange bubbled, we'd just bind to it like all the |
| 4708 | // other events and have it go through ReactBrowserEventEmitter. Since it |
| 4709 | // doesn't, we manually listen for the events and so we have to enqueue and |
| 4710 | // process the abstract event manually. |
| 4711 | // |
| 4712 | // Batching is necessary here in order to ensure that all event handlers run |
| 4713 | // before the next rerender (including event handlers attached to ancestor |
| 4714 | // elements instead of directly on the input). Without this, controlled |
| 4715 | // components don't work properly in conjunction with event bubbling because |
| 4716 | // the component is rerendered and the value reverted before all the event |
| 4717 | // handlers can run. See https://github.com/facebook/react/issues/708. |
| 4718 | batchedUpdates(runEventInBatch, event); |
| 4719 | } |
| 4720 | |
| 4721 | function runEventInBatch(event) { |
| 4722 | runEventsInBatch(event, false); |
no test coverage detected