Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 0 additions & 13 deletions packages/react-native/ReactAndroid/api/ReactAndroid.api
Original file line number Diff line number Diff line change
Expand Up @@ -4890,19 +4890,6 @@ public final class com/facebook/react/uimanager/events/TouchEventType$Companion
public final fun getJSEventName (Lcom/facebook/react/uimanager/events/TouchEventType;)Ljava/lang/String;
}

public class com/facebook/react/uimanager/layoutanimation/LayoutAnimationController {
public fun <init> ()V
public fun applyLayoutUpdate (Landroid/view/View;IIII)V
public fun deleteView (Landroid/view/View;Lcom/facebook/react/uimanager/layoutanimation/LayoutAnimationListener;)V
public final fun initializeFromConfig (Lcom/facebook/react/bridge/ReadableMap;Lcom/facebook/react/bridge/Callback;)V
public fun reset ()V
public fun shouldAnimateLayout (Landroid/view/View;)Z
}

public abstract interface class com/facebook/react/uimanager/layoutanimation/LayoutAnimationListener {
public abstract fun onAnimationEnd ()V
}

public final class com/facebook/react/uimanager/style/BackgroundImageLayer {
public static final field Companion Lcom/facebook/react/uimanager/style/BackgroundImageLayer$Companion;
public fun <init> ()V
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,6 @@
import com.facebook.react.common.annotations.internal.LegacyArchitectureLogger;
import com.facebook.react.common.build.ReactBuildConfig;
import com.facebook.react.touch.JSResponderHandler;
import com.facebook.react.uimanager.layoutanimation.LayoutAnimationController;
import com.facebook.react.uimanager.layoutanimation.LayoutAnimationListener;
import com.facebook.systrace.Systrace;
import com.facebook.systrace.SystraceMessage;
import com.facebook.yoga.YogaDirection;
Expand Down Expand Up @@ -86,7 +84,6 @@ public class NativeViewHierarchyManager {
private final ViewManagerRegistry mViewManagers;
private final JSResponderHandler mJSResponderHandler = new JSResponderHandler();
private final RootViewManager mRootViewManager;
private final LayoutAnimationController mLayoutAnimator = new LayoutAnimationController();
private final RectF mBoundingBox = new RectF();

private volatile boolean mLayoutAnimationEnabled;
Expand Down Expand Up @@ -265,9 +262,7 @@ public synchronized long getInstanceHandle(int reactTag) {
}

private void updateLayout(View viewToUpdate, int x, int y, int width, int height) {
if (mLayoutAnimationEnabled && mLayoutAnimator.shouldAnimateLayout(viewToUpdate)) {
mLayoutAnimator.applyLayoutUpdate(viewToUpdate, x, y, width, height);
} else {
if (!mLayoutAnimationEnabled) {
viewToUpdate.layout(x, y, x + width, y + height);
}
}
Expand Down Expand Up @@ -464,14 +459,7 @@ public synchronized void manageChildren(
viewToManage, viewManager, indicesToRemove, viewsToAdd, tagsToDelete));
}

View viewToRemove = viewManager.getChildAt(viewToManage, indexToRemove);

if (mLayoutAnimationEnabled
&& mLayoutAnimator.shouldAnimateLayout(viewToRemove)
&& arrayContains(tagsToDelete, viewToRemove.getId())) {
// The view will be removed and dropped by the 'delete' layout animation
// instead, so do nothing
} else {
if (!mLayoutAnimationEnabled) {
viewManager.removeViewAt(viewToManage, indexToRemove);
}

Expand All @@ -492,26 +480,7 @@ && arrayContains(tagsToDelete, viewToRemove.getId())) {
viewToManage, viewManager, indicesToRemove, viewsToAdd, tagsToDelete));
}

if (mLayoutAnimationEnabled && mLayoutAnimator.shouldAnimateLayout(viewToDestroy)) {
pendingDeletionTags.add(tagToDelete);
mLayoutAnimator.deleteView(
viewToDestroy,
new LayoutAnimationListener() {
@Override
public void onAnimationEnd() {
// This should be called only on the UI thread, because
// onAnimationEnd is called (indirectly) by Android View Animation.
UiThreadUtil.assertOnUiThread();

viewManager.removeView(viewToManage, viewToDestroy);
dropView(viewToDestroy);
pendingDeletionTags.remove(viewToDestroy.getId());
if (pendingDeletionTags.isEmpty()) {
mPendingDeletionsForTag.remove(tag);
}
}
});
} else {
if (!mLayoutAnimationEnabled) {
dropView(viewToDestroy);
}
}
Expand Down Expand Up @@ -828,11 +797,11 @@ public synchronized void clearJSResponder() {

synchronized void configureLayoutAnimation(
final ReadableMap config, final Callback onAnimationComplete) {
mLayoutAnimator.initializeFromConfig(config, onAnimationComplete);
// no-op
}

synchronized void clearLayoutAnimation() {
mLayoutAnimator.reset();
// no-op
}

@Deprecated
Expand Down

This file was deleted.

This file was deleted.