@@ -18,10 +18,8 @@ let batchedUpdatesImpl = function(fn, bookkeeping) {
18
18
let discreteUpdatesImpl = function ( fn , a , b , c , d ) {
19
19
return fn ( a , b , c , d ) ;
20
20
} ;
21
- let batchedEventUpdatesImpl = batchedUpdatesImpl ;
22
21
23
22
let isInsideEventHandler = false ;
24
- let isBatchingEventUpdates = false ;
25
23
26
24
export function batchedUpdates ( fn , bookkeeping ) {
27
25
if ( isInsideEventHandler ) {
@@ -37,20 +35,6 @@ export function batchedUpdates(fn, bookkeeping) {
37
35
}
38
36
}
39
37
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
-
54
38
export function discreteUpdates ( fn , a , b , c , d ) {
55
39
const prevIsInsideEventHandler = isInsideEventHandler ;
56
40
isInsideEventHandler = true ;
@@ -64,9 +48,7 @@ export function discreteUpdates(fn, a, b, c, d) {
64
48
export function setBatchingImplementation (
65
49
_batchedUpdatesImpl ,
66
50
_discreteUpdatesImpl ,
67
- _batchedEventUpdatesImpl ,
68
51
) {
69
52
batchedUpdatesImpl = _batchedUpdatesImpl ;
70
53
discreteUpdatesImpl = _discreteUpdatesImpl ;
71
- batchedEventUpdatesImpl = _batchedEventUpdatesImpl ;
72
54
}
0 commit comments