public static void Remove(AbstractWindow window) { if (Instance._Windows.Count == 0) { return; } Instance._Windows.Remove(window); }
public static void AddToList(AbstractWindow window) { var type = window.GetType(); if (type != typeof(ConsoleLog) && type != typeof(NavigationWindow)) { Instance._Windows.Add(window); window.transform.SetParent(Instance.transform, false); window.transform.ToRect().anchoredPosition = Vector2.one * -25 * Instance._Windows.Count; } }
public static AbstractWindow GetWindow(Transform current) { if (current != null) { AbstractWindow window = current.GetComponent <AbstractWindow>(); if (window == null) { return(GetWindow(current.parent)); } return(window); } return(null); }