Skip to content

Commit

Permalink
Extend ReactShadowNode API to expose flex props
Browse files Browse the repository at this point in the history
Summary:
This diff extends the ReactShadowNode API to expose flex props, this is going to be used by some components that require access to it

changeLog: [Android][Added] Exposed getFlex method as part of ReactShadowNode API

Reviewed By: JoshuaGross

Differential Revision: D21554663

fbshipit-source-id: 26c9a3fe5f72a84120b16b553ab08231817c0efa
  • Loading branch information
mdvacca authored and facebook-github-bot committed May 13, 2020
1 parent d269844 commit 6570f78
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -288,6 +288,8 @@ public interface ReactShadowNode<T extends ReactShadowNode> {

YogaValue getStyleHeight();

float getFlex();

void setStyleHeight(float heightPx);

void setStyleHeightPercent(float percent);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -779,6 +779,11 @@ public void setStyleMaxHeightPercent(float percent) {
mYogaNode.setMaxHeightPercent(percent);
}

@Override
public float getFlex() {
return mYogaNode.getFlex();
}

@Override
public void setFlex(float flex) {
mYogaNode.setFlex(flex);
Expand Down

0 comments on commit 6570f78

Please sign in to comment.