mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-04-08 22:42:05 +08:00
Add directional clipping command manager.
Summary: Add directional aware clipping to DrawCommandManager. Currently not attached to FlatViewGroup logic, with the plan to keep this unattached until we are clipping the way we want to in the final state. Reviewed By: ahmedre Differential Revision: D3622253
This commit is contained in:
committed by
Ahmed El-Helw
parent
f850e61fdb
commit
e96f6fa585
@@ -536,6 +536,17 @@ import com.facebook.react.uimanager.events.EventDispatcher;
|
||||
ensureBackingViewIsCreated(node);
|
||||
|
||||
addNativeChild(node);
|
||||
updated = collectStateForMountableNode(
|
||||
node,
|
||||
0, // left - left
|
||||
0, // top - top
|
||||
right - left,
|
||||
bottom - top,
|
||||
parentClipLeft - left,
|
||||
parentClipTop - top,
|
||||
parentClipRight - left,
|
||||
parentClipBottom - top);
|
||||
|
||||
if (!parentIsAndroidView) {
|
||||
mDrawCommands.add(node.collectDrawView(
|
||||
left,
|
||||
@@ -548,17 +559,6 @@ import com.facebook.react.uimanager.events.EventDispatcher;
|
||||
parentClipBottom));
|
||||
}
|
||||
|
||||
updated = collectStateForMountableNode(
|
||||
node,
|
||||
0, // left - left
|
||||
0, // top - top
|
||||
right - left,
|
||||
bottom - top,
|
||||
parentClipLeft - left,
|
||||
parentClipTop - top,
|
||||
parentClipRight - left,
|
||||
parentClipBottom - top);
|
||||
|
||||
if (!needsCustomLayout) {
|
||||
updateViewBounds(node, left, top, right, bottom);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user