YogaLayout addView by index & params #803
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Report
The problem is;
-Something looks like wrong when i addView the child by index & params. Child does not place itself in specified position. Even if i give -1 does not add the child at the last position.
Issues and Steps to Reproduce
Expected Behavior
As i expect, added child should be placed in the specified position
Actual Behavior
Child does not placed in given position.
change:
”mYogaNode.addChildAt(childNode, mYogaNode.getChildCount());“
to
if (index > 0) {
mYogaNode.addChildAt(childNode, index);
} else {
mYogaNode.addChildAt(childNode, mYogaNode.getChildCount());
}
We're deprecating the
com.facebook.yoga.android.YogaLayout
ViewGroup in the next major release of Yoga. We intend to still push out a new version aligned to the core Yoga 2.0. I have bulk closed ViewGroup issues to reflect that we are not planning to invest time into functional changes of the ViewGroup. and eventually intend to remove it from the repo.