mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Revert batching for mount operations accumulated before root view attached (#44724)
Summary: Pull Request resolved: https://github.com/facebook/react-native/pull/44724 Changelog: [internal] Batching operations at this layer was wrong because these are the operations that were already flushed by the mounting layer but were accumulated in `SurfaceMountingManager` because the root view wasn't created. These operations should be executed before anything else that's scheduled in the `MountItemDispatcher`, so we should never batch them. The problem this was trying to solve is solved in a different way in D57968937. This was gated so this shouldn't affect any current usages. Reviewed By: sammy-SC Differential Revision: D57968939 fbshipit-source-id: e9131614cdc76e9d553540757611bc8b0736c927
This commit is contained in:
committed by
Facebook GitHub Bot
parent
c0692ab063
commit
958c2e840a
+1
-9
@@ -66,7 +66,6 @@ import com.facebook.react.fabric.mounting.mountitems.DispatchCommandMountItem;
|
||||
import com.facebook.react.fabric.mounting.mountitems.MountItem;
|
||||
import com.facebook.react.fabric.mounting.mountitems.MountItemFactory;
|
||||
import com.facebook.react.interfaces.fabric.SurfaceHandler;
|
||||
import com.facebook.react.internal.featureflags.ReactNativeFeatureFlags;
|
||||
import com.facebook.react.internal.interop.InteropEventEmitter;
|
||||
import com.facebook.react.modules.core.ReactChoreographer;
|
||||
import com.facebook.react.modules.i18nmanager.I18nUtil;
|
||||
@@ -214,14 +213,7 @@ public class FabricUIManager
|
||||
public void executeItems(Queue<MountItem> items) {
|
||||
// This executor can be technically accessed before the dispatcher is created,
|
||||
// but if that happens, something is terribly wrong
|
||||
if (ReactNativeFeatureFlags.forceBatchingMountItemsOnAndroid()) {
|
||||
for (MountItem mountItem : items) {
|
||||
mMountItemDispatcher.addMountItem(mountItem);
|
||||
}
|
||||
mMountItemDispatcher.tryDispatchMountItems();
|
||||
} else {
|
||||
mMountItemDispatcher.dispatchMountItems(items);
|
||||
}
|
||||
mMountItemDispatcher.dispatchMountItems(items);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user