Rename java API

Summary: Rename java api to new use yoga naming

Reviewed By: IanChilds

Differential Revision: D4265345

fbshipit-source-id: 69ecfd8fac214f86b8b70647b9b909acd83d78b5
This commit is contained in:
Emil Sjolander
2016-12-03 04:40:23 -08:00
committed by Facebook Github Bot
parent 6339467b6d
commit c6100d0771
22 changed files with 366 additions and 352 deletions

View File

@@ -18,11 +18,11 @@ import static org.junit.Assert.assertEquals;
public class YGMinMaxDimensionTest {
@Test
public void test_max_width() {
final CSSNode root = new CSSNode();
final YogaNode root = new YogaNode();
root.setWidth(100f);
root.setHeight(100f);
final CSSNode root_child0 = new CSSNode();
final YogaNode root_child0 = new YogaNode();
root_child0.setMaxWidth(50f);
root_child0.setHeight(10f);
root.addChildAt(root_child0, 0);
@@ -55,12 +55,12 @@ public class YGMinMaxDimensionTest {
@Test
public void test_max_height() {
final CSSNode root = new CSSNode();
final YogaNode root = new YogaNode();
root.setFlexDirection(YogaFlexDirection.ROW);
root.setWidth(100f);
root.setHeight(100f);
final CSSNode root_child0 = new CSSNode();
final YogaNode root_child0 = new YogaNode();
root_child0.setWidth(10f);
root_child0.setMaxHeight(50f);
root.addChildAt(root_child0, 0);
@@ -93,16 +93,16 @@ public class YGMinMaxDimensionTest {
@Test
public void test_min_height() {
final CSSNode root = new CSSNode();
final YogaNode root = new YogaNode();
root.setWidth(100f);
root.setHeight(100f);
final CSSNode root_child0 = new CSSNode();
final YogaNode root_child0 = new YogaNode();
root_child0.setFlexGrow(1f);
root_child0.setMinHeight(60f);
root.addChildAt(root_child0, 0);
final CSSNode root_child1 = new CSSNode();
final YogaNode root_child1 = new YogaNode();
root_child1.setFlexGrow(1f);
root.addChildAt(root_child1, 1);
root.setDirection(YogaDirection.LTR);
@@ -144,17 +144,17 @@ public class YGMinMaxDimensionTest {
@Test
public void test_min_width() {
final CSSNode root = new CSSNode();
final YogaNode root = new YogaNode();
root.setFlexDirection(YogaFlexDirection.ROW);
root.setWidth(100f);
root.setHeight(100f);
final CSSNode root_child0 = new CSSNode();
final YogaNode root_child0 = new YogaNode();
root_child0.setFlexGrow(1f);
root_child0.setMinWidth(60f);
root.addChildAt(root_child0, 0);
final CSSNode root_child1 = new CSSNode();
final YogaNode root_child1 = new YogaNode();
root_child1.setFlexGrow(1f);
root.addChildAt(root_child1, 1);
root.setDirection(YogaDirection.LTR);
@@ -196,13 +196,13 @@ public class YGMinMaxDimensionTest {
@Test
public void test_justify_content_min_max() {
final CSSNode root = new CSSNode();
final YogaNode root = new YogaNode();
root.setJustifyContent(YogaJustify.CENTER);
root.setWidth(100f);
root.setMinHeight(100f);
root.setMaxHeight(200f);
final CSSNode root_child0 = new CSSNode();
final YogaNode root_child0 = new YogaNode();
root_child0.setWidth(60f);
root_child0.setHeight(60f);
root.addChildAt(root_child0, 0);
@@ -235,13 +235,13 @@ public class YGMinMaxDimensionTest {
@Test
public void test_align_items_min_max() {
final CSSNode root = new CSSNode();
final YogaNode root = new YogaNode();
root.setAlignItems(YogaAlign.CENTER);
root.setMinWidth(100f);
root.setMaxWidth(200f);
root.setHeight(100f);
final CSSNode root_child0 = new CSSNode();
final YogaNode root_child0 = new YogaNode();
root_child0.setWidth(60f);
root_child0.setHeight(60f);
root.addChildAt(root_child0, 0);
@@ -274,22 +274,22 @@ public class YGMinMaxDimensionTest {
@Test
public void test_justify_content_overflow_min_max() {
final CSSNode root = new CSSNode();
final YogaNode root = new YogaNode();
root.setJustifyContent(YogaJustify.CENTER);
root.setMinHeight(100f);
root.setMaxHeight(110f);
final CSSNode root_child0 = new CSSNode();
final YogaNode root_child0 = new YogaNode();
root_child0.setWidth(50f);
root_child0.setHeight(50f);
root.addChildAt(root_child0, 0);
final CSSNode root_child1 = new CSSNode();
final YogaNode root_child1 = new YogaNode();
root_child1.setWidth(50f);
root_child1.setHeight(50f);
root.addChildAt(root_child1, 1);
final CSSNode root_child2 = new CSSNode();
final YogaNode root_child2 = new YogaNode();
root_child2.setWidth(50f);
root_child2.setHeight(50f);
root.addChildAt(root_child2, 2);
@@ -342,16 +342,16 @@ public class YGMinMaxDimensionTest {
@Test
public void test_flex_grow_within_max_width() {
final CSSNode root = new CSSNode();
final YogaNode root = new YogaNode();
root.setWidth(200f);
root.setHeight(100f);
final CSSNode root_child0 = new CSSNode();
final YogaNode root_child0 = new YogaNode();
root_child0.setFlexDirection(YogaFlexDirection.ROW);
root_child0.setMaxWidth(100f);
root.addChildAt(root_child0, 0);
final CSSNode root_child0_child0 = new CSSNode();
final YogaNode root_child0_child0 = new YogaNode();
root_child0_child0.setFlexGrow(1f);
root_child0_child0.setHeight(20f);
root_child0.addChildAt(root_child0_child0, 0);
@@ -394,16 +394,16 @@ public class YGMinMaxDimensionTest {
@Test
public void test_flex_grow_within_constrained_max_width() {
final CSSNode root = new CSSNode();
final YogaNode root = new YogaNode();
root.setWidth(200f);
root.setHeight(100f);
final CSSNode root_child0 = new CSSNode();
final YogaNode root_child0 = new YogaNode();
root_child0.setFlexDirection(YogaFlexDirection.ROW);
root_child0.setMaxWidth(300f);
root.addChildAt(root_child0, 0);
final CSSNode root_child0_child0 = new CSSNode();
final YogaNode root_child0_child0 = new YogaNode();
root_child0_child0.setFlexGrow(1f);
root_child0_child0.setHeight(20f);
root_child0.addChildAt(root_child0_child0, 0);