mirror of
https://github.com/facebook/react.git
synced 2025-11-01 09:12:30 +00:00
Revert "Use highest priority lane to detect interruptions (#21088)"
This reverts commit b4044f8a07323bcad7d55cbaedc35c35b4acf7e0. Instead of LanePriority. I'm removing all uses of LanePriority so I can delete it.
This commit is contained in:
@@ -300,16 +300,15 @@ export function getNextLanes(root: FiberRoot, wipLanes: Lanes): Lanes {
|
||||
// bother waiting until the root is complete.
|
||||
(wipLanes & suspendedLanes) === NoLanes
|
||||
) {
|
||||
const nextLane = getHighestPriorityLane(nextLanes);
|
||||
const wipLane = getHighestPriorityLane(wipLanes);
|
||||
getHighestPriorityLanes(wipLanes);
|
||||
const wipLanePriority = return_highestLanePriority;
|
||||
if (
|
||||
// Tests whether the next lane is equal or lower priority than the wip
|
||||
// one. This works because the bits decrease in priority as you go left.
|
||||
nextLane >= wipLane ||
|
||||
nextLanePriority <= wipLanePriority ||
|
||||
// Default priority updates should not interrupt transition updates. The
|
||||
// only difference between default updates and transition updates is that
|
||||
// default updates do not support refresh transitions.
|
||||
(nextLane === DefaultLane && (wipLane & TransitionLanes) !== NoLanes)
|
||||
(nextLanePriority === DefaultLanePriority &&
|
||||
wipLanePriority === TransitionPriority)
|
||||
) {
|
||||
// Keep working on the existing in-progress tree. Do not interrupt.
|
||||
return wipLanes;
|
||||
|
||||
@@ -300,16 +300,15 @@ export function getNextLanes(root: FiberRoot, wipLanes: Lanes): Lanes {
|
||||
// bother waiting until the root is complete.
|
||||
(wipLanes & suspendedLanes) === NoLanes
|
||||
) {
|
||||
const nextLane = getHighestPriorityLane(nextLanes);
|
||||
const wipLane = getHighestPriorityLane(wipLanes);
|
||||
getHighestPriorityLanes(wipLanes);
|
||||
const wipLanePriority = return_highestLanePriority;
|
||||
if (
|
||||
// Tests whether the next lane is equal or lower priority than the wip
|
||||
// one. This works because the bits decrease in priority as you go left.
|
||||
nextLane >= wipLane ||
|
||||
nextLanePriority <= wipLanePriority ||
|
||||
// Default priority updates should not interrupt transition updates. The
|
||||
// only difference between default updates and transition updates is that
|
||||
// default updates do not support refresh transitions.
|
||||
(nextLane === DefaultLane && (wipLane & TransitionLanes) !== NoLanes)
|
||||
(nextLanePriority === DefaultLanePriority &&
|
||||
wipLanePriority === TransitionPriority)
|
||||
) {
|
||||
// Keep working on the existing in-progress tree. Do not interrupt.
|
||||
return wipLanes;
|
||||
|
||||
Reference in New Issue
Block a user