@@ -18,10 +18,8 @@ let batchedUpdatesImpl = function(fn, bookkeeping) {
1818let discreteUpdatesImpl = function ( fn , a , b , c , d ) {
1919 return fn ( a , b , c , d ) ;
2020} ;
21- let batchedEventUpdatesImpl = batchedUpdatesImpl ;
2221
2322let isInsideEventHandler = false ;
24- let isBatchingEventUpdates = false ;
2523
2624export function batchedUpdates ( fn , bookkeeping ) {
2725 if ( isInsideEventHandler ) {
@@ -37,20 +35,6 @@ export function batchedUpdates(fn, bookkeeping) {
3735 }
3836}
3937
40- export function batchedEventUpdates ( fn , a , b ) {
41- if ( isBatchingEventUpdates ) {
42- // If we are currently inside another batch, we need to wait until it
43- // fully completes before restoring state.
44- return fn ( a , b ) ;
45- }
46- isBatchingEventUpdates = true ;
47- try {
48- return batchedEventUpdatesImpl ( fn , a , b ) ;
49- } finally {
50- isBatchingEventUpdates = false ;
51- }
52- }
53-
5438export function discreteUpdates ( fn , a , b , c , d ) {
5539 const prevIsInsideEventHandler = isInsideEventHandler ;
5640 isInsideEventHandler = true ;
@@ -64,9 +48,7 @@ export function discreteUpdates(fn, a, b, c, d) {
6448export function setBatchingImplementation (
6549 _batchedUpdatesImpl ,
6650 _discreteUpdatesImpl ,
67- _batchedEventUpdatesImpl ,
6851) {
6952 batchedUpdatesImpl = _batchedUpdatesImpl ;
7053 discreteUpdatesImpl = _discreteUpdatesImpl ;
71- batchedEventUpdatesImpl = _batchedEventUpdatesImpl ;
7254}
0 commit comments