22 lines
551 B
C#
22 lines
551 B
C#
using System;
|
|
using System.Threading;
|
|
using Cysharp.Threading.Tasks;
|
|
using UnityEngine;
|
|
using UnityEngine.AddressableAssets;
|
|
|
|
namespace Code.Infrastructure.UI
|
|
{
|
|
public abstract class UIPanel : MonoBehaviour, IDisposable
|
|
{
|
|
public UIPanelType PanelType { get; set; }
|
|
|
|
public abstract UniTask Open(CancellationToken cts = default);
|
|
public abstract UniTask Close(CancellationToken cts = default);
|
|
|
|
public void Dispose()
|
|
{
|
|
Addressables.ReleaseInstance(gameObject);
|
|
}
|
|
}
|
|
|
|
} |