Summary: Added a new API `YGNodeSetLayoutStyleInputs` to pass layout style inputs from java to native code. All the style inputs are passed in a float array in [key1, key2, value2, key3, value3a, value3b .....] format over JNI layer. There are three types of style inputs - do not need any value to be passed along with them like WidthAuto, HeightAuto - need one value to be passed like Width, Height - need two values to be passed like Margin, Padding (edge value and actual margin, padding value) Reviewed By: davidaurelio Differential Revision: D14166948 fbshipit-source-id: 4bea64d6a429959c3962c87e337914dcd99199fd
54 lines
2.1 KiB
Java
54 lines
2.1 KiB
Java
/**
|
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
*
|
|
* This source code is licensed under the MIT license found in the LICENSE
|
|
* file in the root directory of this source tree.
|
|
*/
|
|
package com.facebook.yoga;
|
|
|
|
import com.facebook.proguard.annotations.DoNotStrip;
|
|
|
|
@DoNotStrip
|
|
public class YogaStyleInputs {
|
|
public static final short LAYOUT_DIRECTION = 0;
|
|
public static final short FLEX_DIRECTION = 1;
|
|
public static final short FLEX = 2;
|
|
public static final short FLEX_GROW = 3;
|
|
public static final short FLEX_SHRINK = 4;
|
|
public static final short FLEX_BASIS = 5;
|
|
public static final short FLEX_BASIS_PERCENT = 6;
|
|
public static final short FLEX_BASIS_AUTO = 7;
|
|
public static final short FLEX_WRAP = 8;
|
|
public static final short WIDTH = 9;
|
|
public static final short WIDTH_PERCENT = 10;
|
|
public static final short WIDTH_AUTO = 11;
|
|
public static final short MIN_WIDTH = 12;
|
|
public static final short MIN_WIDTH_PERCENT = 13;
|
|
public static final short MAX_WIDTH = 14;
|
|
public static final short MAX_WIDTH_PERCENT = 15;
|
|
public static final short HEIGHT = 16;
|
|
public static final short HEIGHT_PERCENT = 17;
|
|
public static final short HEIGHT_AUTO = 18;
|
|
public static final short MIN_HEIGHT = 19;
|
|
public static final short MIN_HEIGHT_PERCENT = 20;
|
|
public static final short MAX_HEIGHT = 21;
|
|
public static final short MAX_HEIGHT_PERCENT = 22;
|
|
public static final short JUSTIFY_CONTENT = 23;
|
|
public static final short ALIGN_ITEMS = 24;
|
|
public static final short ALIGN_SELF = 25;
|
|
public static final short ALIGN_CONTENT = 26;
|
|
public static final short POSITION_TYPE = 27;
|
|
public static final short ASPECT_RATIO = 28;
|
|
public static final short OVERFLOW = 29;
|
|
public static final short DISPLAY = 30;
|
|
public static final short MARGIN = 31;
|
|
public static final short MARGIN_PERCENT = 32;
|
|
public static final short MARGIN_AUTO = 33;
|
|
public static final short PADDING = 34;
|
|
public static final short PADDING_PERCENT = 35;
|
|
public static final short BORDER = 36;
|
|
public static final short POSITION = 37;
|
|
public static final short POSITION_PERCENT = 38;
|
|
public static final short IS_REFERENCE_BASELINE = 39;
|
|
}
|