summaryrefslogtreecommitdiff
path: root/Assets/uGUI-2017.1/UnityEngine.UI/UI/Core/CanvasUpdateRegistry.cs
diff options
context:
space:
mode:
authorchai <chaifix@163.com>2021-07-16 18:52:50 +0800
committerchai <chaifix@163.com>2021-07-16 18:52:50 +0800
commita257e8db13ed740c016d1acebc6f9edc2801dac8 (patch)
treeefea3ab6b510b91814c588e10f22d7a5680dac06 /Assets/uGUI-2017.1/UnityEngine.UI/UI/Core/CanvasUpdateRegistry.cs
parentac839e2315f362cc1085ff647cedbca90df2e16f (diff)
*misc
Diffstat (limited to 'Assets/uGUI-2017.1/UnityEngine.UI/UI/Core/CanvasUpdateRegistry.cs')
-rw-r--r--Assets/uGUI-2017.1/UnityEngine.UI/UI/Core/CanvasUpdateRegistry.cs11
1 files changed, 11 insertions, 0 deletions
diff --git a/Assets/uGUI-2017.1/UnityEngine.UI/UI/Core/CanvasUpdateRegistry.cs b/Assets/uGUI-2017.1/UnityEngine.UI/UI/Core/CanvasUpdateRegistry.cs
index 6690060..ad6e8c2 100644
--- a/Assets/uGUI-2017.1/UnityEngine.UI/UI/Core/CanvasUpdateRegistry.cs
+++ b/Assets/uGUI-2017.1/UnityEngine.UI/UI/Core/CanvasUpdateRegistry.cs
@@ -1,6 +1,7 @@
using System;
using System.Collections.Generic;
using UnityEngine.UI.Collections;
+using System.Threading;
namespace UnityEngine.UI
{
@@ -110,12 +111,22 @@ namespace UnityEngine.UI
}
}
+ private void Foo()
+ {
+ GameObject go = GameObject.Find("Canvas");
+ UISystemProfilerApi.AddMarker("MaskableGraphic.cullingChanged", go);
+ Thread.Sleep(100);
+ }
+
private static readonly Comparison<ICanvasElement> s_SortLayoutFunction = SortLayoutList;
// 在渲染canvas之前对canvas下的元素进行rebuild
// 进行 prelayout -> layout -> postlayout -> prerender -> LatePreRender 流程
private void PerformUpdate()
{
UISystemProfilerApi.BeginSample(UISystemProfilerApi.SampleType.Layout);
+
+ Foo();
+
CleanInvalidItems();
m_PerformingLayoutUpdate = true;