MCPcopy
hub / github.com/facebook/react / flushGestureMutations

Function flushGestureMutations

packages/react-reconciler/src/ReactFiberWorkLoop.js:4295–4322  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

4293}
4294
4295function flushGestureMutations(): void {
4296 if (!enableGestureTransition) {
4297 return;
4298 }
4299 if (pendingEffectsStatus !== PENDING_GESTURE_MUTATION_PHASE) {
4300 return;
4301 }
4302 pendingEffectsStatus = NO_PENDING_EFFECTS;
4303 const root = pendingEffectsRoot;
4304 const finishedWork = pendingFinishedWork;
4305
4306 const prevTransition = ReactSharedInternals.T;
4307 ReactSharedInternals.T = null;
4308 const previousPriority = getCurrentUpdatePriority();
4309 setCurrentUpdatePriority(DiscreteEventPriority);
4310 const prevExecutionContext = executionContext;
4311 executionContext |= CommitContext;
4312 try {
4313 applyDepartureTransitions(root, finishedWork);
4314 } finally {
4315 // Reset the priority to the previous non-sync value.
4316 executionContext = prevExecutionContext;
4317 setCurrentUpdatePriority(previousPriority);
4318 ReactSharedInternals.T = prevTransition;
4319 }
4320
4321 pendingEffectsStatus = PENDING_GESTURE_ANIMATION_PHASE;
4322}
4323
4324function flushGestureAnimations(): void {
4325 if (!enableGestureTransition) {

Callers 2

flushGestureAnimationsFunction · 0.85
flushPendingEffectsFunction · 0.85

Calls 3

getCurrentUpdatePriorityFunction · 0.90
setCurrentUpdatePriorityFunction · 0.90

Tested by

no test coverage detected