Update UIModule.cs

This commit is contained in:
ALEXTANG
2023-04-11 16:58:03 +08:00
parent c99500f723
commit 8da93ff447

View File

@@ -6,15 +6,6 @@ using YooAsset;
namespace TEngine namespace TEngine
{ {
public enum EUIGroup
{
Bottom,
UI,
Top,
Tips,
System,
}
/// <summary> /// <summary>
/// UI模块。 /// UI模块。
/// </summary> /// </summary>
@@ -31,6 +22,7 @@ namespace TEngine
private readonly List<UIWindow> _stack = new List<UIWindow>(100); private readonly List<UIWindow> _stack = new List<UIWindow>(100);
public const int LAYER_DEEP = 2000;
public const int WINDOW_DEEP = 100; public const int WINDOW_DEEP = 100;
public const int WINDOW_HIDE_LAYER = 2; // Ignore Raycast public const int WINDOW_HIDE_LAYER = 2; // Ignore Raycast
public const int WINDOW_SHOW_LAYER = 5; // UI public const int WINDOW_SHOW_LAYER = 5; // UI
@@ -333,7 +325,7 @@ namespace TEngine
private void OnSortWindowDepth(int layer) private void OnSortWindowDepth(int layer)
{ {
int depth = layer; int depth = layer * LAYER_DEEP;
for (int i = 0; i < _stack.Count; i++) for (int i = 0; i < _stack.Count; i++)
{ {
if (_stack[i].WindowLayer == layer) if (_stack[i].WindowLayer == layer)