Add basic Xamarin.iOS support

This commit is contained in:
Rui Marinho
2016-12-08 19:09:02 +00:00
parent 25b206ac53
commit 00e862173c
20 changed files with 812 additions and 9 deletions

View File

@@ -14,22 +14,22 @@ namespace Facebook.Yoga
{
internal static class Native
{
#if UNITY_IOS && !UNITY_EDITOR
#if UNITY_IOS && !UNITY_EDITOR || __IOS__
private const string DllName = "__Internal";
#else
private const string DllName = "yoga";
#endif
#if !__IOS__
[DllImport(DllName)]
public static extern void YGInteropSetLogger(
[MarshalAs(UnmanagedType.FunctionPtr)] YogaLogger.Func func);
#endif
[DllImport(DllName)]
public static extern IntPtr YGNodeNew();
#if !__IOS__
[DllImport(DllName)]
public static extern void YGNodeInit(IntPtr node);
#endif
[DllImport(DllName)]
public static extern void YGNodeFree(IntPtr node);