Fix imgui windows flickering

This commit is contained in:
js6pak committed 2021-10-30 13:43:36 +02:00
1 parent dd3e49144d
commit ade1cfc35f
1 file changed
+5 -1
+5 -1
View File
@@ -114,7 +114,11 @@ namespace Reactor.Extensions
{
if (Enabled)
{
Rect = Rect.ResetSize();
if (Event.current.type == EventType.Layout)
{
Rect = Rect.ResetSize();
}
Rect = GUILayout.Window(Id, Rect, Func, Title, new Il2CppReferenceArray<GUILayoutOption>(0));
if ((Input.GetMouseButtonDown(0) || Input.GetMouseButtonDown(1)) && Rect.Contains(new Vector2(Input.mousePosition.x, Screen.height - Input.mousePosition.y)))