Expose alignContent to java
Reviewed By: IanChilds Differential Revision: D3709071 fbshipit-source-id: 421d75924ecc12d6d0975e342f3862cf5592f65f
This commit is contained in:
parent
ce2f119222
commit
c2a41e42f2
|
@ -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.
|
||||
*/
|
||||
|
|
|
@ -47,6 +47,8 @@ public interface CSSNodeAPI<CSSNodeType extends CSSNodeAPI> {
|
|||
void setAlignItems(CSSAlign alignItems);
|
||||
CSSAlign getAlignSelf();
|
||||
void setAlignSelf(CSSAlign alignSelf);
|
||||
CSSAlign getAlignContent();
|
||||
void setAlignContent(CSSAlign alignContent);
|
||||
CSSPositionType getPositionType();
|
||||
void setPositionType(CSSPositionType positionType);
|
||||
void setWrap(CSSWrap flexWrap);
|
||||
|
|
|
@ -230,6 +230,20 @@ public class CSSNodeJNI implements CSSNodeAPI<CSSNodeJNI> {
|
|||
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);
|
||||
@Override
|
||||
public CSSPositionType getPositionType() {
|
||||
|
|
Loading…
Reference in New Issue