Expose alignContent to java
Summary: Expose already existing alignContent property to java Reviewed By: IanChilds Differential Revision: D3709071 fbshipit-source-id: 421d75924ecc12d6d0975e342f3862cf5592f65f
This commit is contained in:
committed by
Facebook Github Bot 7
parent
916170f6ac
commit
e307dc22d1
@@ -319,6 +319,19 @@ public class CSSNode implements CSSNodeAPI<CSSNode> {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public CSSAlign getAlignContent() {
|
||||||
|
return style.alignContent;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void setAlignContent(CSSAlign alignContent) {
|
||||||
|
if (style.alignContent != alignContent) {
|
||||||
|
style.alignContent = alignContent;
|
||||||
|
dirty();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get this node's position type, as defined by style.
|
* Get this node's position type, as defined by style.
|
||||||
*/
|
*/
|
||||||
|
@@ -47,6 +47,8 @@ public interface CSSNodeAPI<CSSNodeType extends CSSNodeAPI> {
|
|||||||
void setAlignItems(CSSAlign alignItems);
|
void setAlignItems(CSSAlign alignItems);
|
||||||
CSSAlign getAlignSelf();
|
CSSAlign getAlignSelf();
|
||||||
void setAlignSelf(CSSAlign alignSelf);
|
void setAlignSelf(CSSAlign alignSelf);
|
||||||
|
CSSAlign getAlignContent();
|
||||||
|
void setAlignContent(CSSAlign alignContent);
|
||||||
CSSPositionType getPositionType();
|
CSSPositionType getPositionType();
|
||||||
void setPositionType(CSSPositionType positionType);
|
void setPositionType(CSSPositionType positionType);
|
||||||
void setWrap(CSSWrap flexWrap);
|
void setWrap(CSSWrap flexWrap);
|
||||||
|
@@ -230,6 +230,20 @@ public class CSSNodeJNI implements CSSNodeAPI<CSSNodeJNI> {
|
|||||||
jni_CSSNodeStyleSetAlignSelf(mNativePointer, alignSelf.ordinal());
|
jni_CSSNodeStyleSetAlignSelf(mNativePointer, alignSelf.ordinal());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private native int jni_CSSNodeStyleGetAlignContent(int nativePointer);
|
||||||
|
@Override
|
||||||
|
public CSSAlign getAlignContent() {
|
||||||
|
assertNativeInstance();
|
||||||
|
return CSSAlign.values()[jni_CSSNodeStyleGetAlignContent(mNativePointer)];
|
||||||
|
}
|
||||||
|
|
||||||
|
private native void jni_CSSNodeStyleSetAlignContent(int nativePointer, int alignContent);
|
||||||
|
@Override
|
||||||
|
public void setAlignContent(CSSAlign alignContent) {
|
||||||
|
assertNativeInstance();
|
||||||
|
jni_CSSNodeStyleSetAlignContent(mNativePointer, alignContent.ordinal());
|
||||||
|
}
|
||||||
|
|
||||||
private native int jni_CSSNodeStyleGetPositionType(int nativePointer);
|
private native int jni_CSSNodeStyleGetPositionType(int nativePointer);
|
||||||
@Override
|
@Override
|
||||||
public CSSPositionType getPositionType() {
|
public CSSPositionType getPositionType() {
|
||||||
|
@@ -140,6 +140,7 @@ CSS_NODE_JNI_STYLE_PROP(jint, CSSFlexDirection, FlexDirection);
|
|||||||
CSS_NODE_JNI_STYLE_PROP(jint, CSSJustify, JustifyContent);
|
CSS_NODE_JNI_STYLE_PROP(jint, CSSJustify, JustifyContent);
|
||||||
CSS_NODE_JNI_STYLE_PROP(jint, CSSAlign, AlignItems);
|
CSS_NODE_JNI_STYLE_PROP(jint, CSSAlign, AlignItems);
|
||||||
CSS_NODE_JNI_STYLE_PROP(jint, CSSAlign, AlignSelf);
|
CSS_NODE_JNI_STYLE_PROP(jint, CSSAlign, AlignSelf);
|
||||||
|
CSS_NODE_JNI_STYLE_PROP(jint, CSSAlign, AlignContent);
|
||||||
CSS_NODE_JNI_STYLE_PROP(jint, CSSPositionType, PositionType);
|
CSS_NODE_JNI_STYLE_PROP(jint, CSSPositionType, PositionType);
|
||||||
CSS_NODE_JNI_STYLE_PROP(jint, CSSWrapType, FlexWrap);
|
CSS_NODE_JNI_STYLE_PROP(jint, CSSWrapType, FlexWrap);
|
||||||
CSS_NODE_JNI_STYLE_PROP(jint, CSSOverflow, Overflow);
|
CSS_NODE_JNI_STYLE_PROP(jint, CSSOverflow, Overflow);
|
||||||
|
Reference in New Issue
Block a user