Skip to content

Commit 5102509

Browse files
committed
Fix using wrong type
1 parent 37e90ee commit 5102509

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

RuntimeUnityEditor.Core/Utils/Abstractions/GUILayoutShim.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ public static GUILayoutOption MaxWidth(float width)
1717
public static GUILayoutOption ExpandWidth(bool expand)
1818
{
1919
#if IL2CPP
20-
var entity = new UnityEngine.GUILayoutOption(GUILayoutOption.Type.stretchWidth, expand);
20+
var entity = new UnityEngine.GUILayoutOption(GUILayoutOption.Type.stretchWidth, !expand ? 0 : 1);
2121
return entity;
2222
#else
2323
return GUILayout.ExpandWidth(expand);
@@ -27,7 +27,7 @@ public static GUILayoutOption ExpandWidth(bool expand)
2727
public static GUILayoutOption ExpandHeight(bool expand)
2828
{
2929
#if IL2CPP
30-
var entity = new UnityEngine.GUILayoutOption(GUILayoutOption.Type.stretchHeight, expand);
30+
var entity = new UnityEngine.GUILayoutOption(GUILayoutOption.Type.stretchHeight, !expand ? 0 : 1);
3131
return entity;
3232
#else
3333
return GUILayout.ExpandHeight(expand);

0 commit comments

Comments
 (0)