diff --git a/Source/Engine/Engine/NativeInterop.Managed.cs b/Source/Engine/Engine/NativeInterop.Managed.cs
index bc240275f..538703d4e 100644
--- a/Source/Engine/Engine/NativeInterop.Managed.cs
+++ b/Source/Engine/Engine/NativeInterop.Managed.cs
@@ -16,6 +16,9 @@ namespace FlaxEngine.Interop
///
/// Wrapper for managed arrays which are passed to unmanaged code.
///
+#if FLAX_EDITOR
+ [HideInEditor]
+#endif
public unsafe class ManagedArray
{
private ManagedHandle _pinnedArrayHandle;
@@ -266,6 +269,9 @@ namespace FlaxEngine.Interop
}
}
+#if FLAX_EDITOR
+ [HideInEditor]
+#endif
internal static class ManagedString
{
internal static ManagedHandle EmptyStringHandle = ManagedHandle.Alloc(string.Empty);
@@ -315,6 +321,9 @@ namespace FlaxEngine.Interop
///
/// Handle to managed objects which can be stored in native code.
///
+#if FLAX_EDITOR
+ [HideInEditor]
+#endif
public struct ManagedHandle
{
private IntPtr handle;
diff --git a/Source/Engine/Engine/NativeInterop.Marshallers.cs b/Source/Engine/Engine/NativeInterop.Marshallers.cs
index 148f02539..a3531d11d 100644
--- a/Source/Engine/Engine/NativeInterop.Marshallers.cs
+++ b/Source/Engine/Engine/NativeInterop.Marshallers.cs
@@ -12,6 +12,9 @@ using System.Runtime.InteropServices.Marshalling;
namespace FlaxEngine.Interop
{
+#if FLAX_EDITOR
+ [HideInEditor]
+#endif
[CustomMarshaller(typeof(object), MarshalMode.ManagedToUnmanagedIn, typeof(ManagedHandleMarshaller.ManagedToNative))]
[CustomMarshaller(typeof(object), MarshalMode.UnmanagedToManagedOut, typeof(ManagedHandleMarshaller.ManagedToNative))]
[CustomMarshaller(typeof(object), MarshalMode.ElementIn, typeof(ManagedHandleMarshaller.ManagedToNative))]
@@ -23,6 +26,9 @@ namespace FlaxEngine.Interop
[CustomMarshaller(typeof(object), MarshalMode.ElementRef, typeof(ManagedHandleMarshaller))]
public static class ManagedHandleMarshaller
{
+#if FLAX_EDITOR
+ [HideInEditor]
+#endif
public static class NativeToManaged
{
public static object ConvertToManaged(IntPtr unmanaged) => unmanaged == IntPtr.Zero ? null : ManagedHandle.FromIntPtr(unmanaged).Target;
@@ -33,6 +39,9 @@ namespace FlaxEngine.Interop
}
}
+#if FLAX_EDITOR
+ [HideInEditor]
+#endif
public static class ManagedToNative
{
public static IntPtr ConvertToUnmanaged(object managed) => managed != null ? ManagedHandle.ToIntPtr(managed, GCHandleType.Weak) : IntPtr.Zero;
@@ -48,6 +57,9 @@ namespace FlaxEngine.Interop
}
}
+#if FLAX_EDITOR
+ [HideInEditor]
+#endif
public struct Bidirectional
{
object managed;
@@ -99,6 +111,9 @@ namespace FlaxEngine.Interop
}
}
+#if FLAX_EDITOR
+ [HideInEditor]
+#endif
[CustomMarshaller(typeof(Type), MarshalMode.Default, typeof(SystemTypeMarshaller))]
public static class SystemTypeMarshaller
{
@@ -118,6 +133,9 @@ namespace FlaxEngine.Interop
}
}
+#if FLAX_EDITOR
+ [HideInEditor]
+#endif
[CustomMarshaller(typeof(Exception), MarshalMode.Default, typeof(ExceptionMarshaller))]
public static class ExceptionMarshaller
{
@@ -126,6 +144,9 @@ namespace FlaxEngine.Interop
public static void Free(IntPtr unmanaged) => ManagedHandleMarshaller.Free(unmanaged);
}
+#if FLAX_EDITOR
+ [HideInEditor]
+#endif
[CustomMarshaller(typeof(FlaxEngine.Object), MarshalMode.ManagedToUnmanagedIn, typeof(ObjectMarshaller.ManagedToNative))]
[CustomMarshaller(typeof(FlaxEngine.Object), MarshalMode.UnmanagedToManagedOut, typeof(ObjectMarshaller.ManagedToNative))]
[CustomMarshaller(typeof(FlaxEngine.Object), MarshalMode.ElementIn, typeof(ObjectMarshaller.ManagedToNative))]
@@ -134,17 +155,26 @@ namespace FlaxEngine.Interop
[CustomMarshaller(typeof(FlaxEngine.Object), MarshalMode.ElementOut, typeof(ObjectMarshaller.NativeToManaged))]
public static class ObjectMarshaller
{
+#if FLAX_EDITOR
+ [HideInEditor]
+#endif
public static class NativeToManaged
{
public static FlaxEngine.Object ConvertToManaged(IntPtr unmanaged) => unmanaged != IntPtr.Zero ? Unsafe.As(ManagedHandle.FromIntPtr(unmanaged).Target) : null;
}
+#if FLAX_EDITOR
+ [HideInEditor]
+#endif
public static class ManagedToNative
{
public static IntPtr ConvertToUnmanaged(FlaxEngine.Object managed) => Unsafe.As