ui-system-fix #4

Merged
BitterSmile merged 12 commits from ui-system-fix into main 2024-02-12 19:06:53 +01:00
2 changed files with 4 additions and 1 deletions
Showing only changes of commit d9fc097783 - Show all commits

View File

@ -36,7 +36,7 @@ namespace NEG.UI.Area
public void OpenWindow(IWindow window, object data = null) => DefaultWindowSlot.AttachWindow(window, data); public void OpenWindow(IWindow window, object data = null) => DefaultWindowSlot.AttachWindow(window, data);
private void Awake() protected virtual void Awake()
{ {
if (setAsDefaultArea) if (setAsDefaultArea)
UiManager.Instance.CurrentArea = this; UiManager.Instance.CurrentArea = this;

View File

@ -1,4 +1,5 @@
using KBCore.Refs; using KBCore.Refs;
using NEG.UI.UnityUi.Window;
using NegUtils.NEG.UI; using NegUtils.NEG.UI;
using System; using System;
using UnityEngine; using UnityEngine;
@ -11,6 +12,8 @@ namespace NEG.UI.UnityUi
[SerializeField, Self] protected InterfaceRef<IControllable> controllable; [SerializeField, Self] protected InterfaceRef<IControllable> controllable;
protected MonoWindow ControllableAsWindow => (MonoWindow)controllable.Value;
protected virtual void Awake() protected virtual void Awake()
{ {
controllable.Value.OnOpened += OnOpened; controllable.Value.OnOpened += OnOpened;