move YGSetLogger and YGConfigFree with global ref to vanilla jni

Summary: Move YGSetLogger and YGConfigFree methods to vanilla JNI

Reviewed By: amir-shalem

Differential Revision: D17754999

fbshipit-source-id: 8dfcf1a54e4d54ebf91e38c6513e6a703a40ae92
This commit is contained in:
Sidharth Guglani
2019-10-09 09:26:47 -07:00
committed by Facebook Github Bot
parent 2ef674edd3
commit d6591439d1
4 changed files with 93 additions and 14 deletions

View File

@@ -116,14 +116,14 @@ public class YogaNative {
// JNI methods that use Vanilla JNI
// YGConfig related
static native long jni_YGConfigNewJNI();
// static native void jni_YGConfigFreeJNI(long nativePointer);
static native void jni_YGConfigFreeJNI(long nativePointer);
static native void jni_YGConfigSetExperimentalFeatureEnabledJNI(long nativePointer, int feature, boolean enabled);
static native void jni_YGConfigSetUseWebDefaultsJNI(long nativePointer, boolean useWebDefaults);
static native void jni_YGConfigSetPrintTreeFlagJNI(long nativePointer, boolean enable);
static native void jni_YGConfigSetPointScaleFactorJNI(long nativePointer, float pixelsInPoint);
static native void jni_YGConfigSetUseLegacyStretchBehaviourJNI(long nativePointer, boolean useLegacyStretchBehaviour);
static native void jni_YGConfigSetShouldDiffLayoutWithoutLegacyStretchBehaviourJNI(long nativePointer, boolean shouldDiffLayoutWithoutLegacyStretchBehaviour);
// static native void jni_YGConfigSetLoggerJNI(long nativePointer, Object logger);
static native void jni_YGConfigSetLoggerJNI(long nativePointer, YogaLogger logger);
// YGNode related
static native long jni_YGNodeNewJNI();