Example #1
0
        IEnumerator HideUIBase(IUIBase i_ui_base, Action on_hided = null)
        {
            if (i_ui_base == null)
            {
                yield break;
            }
            yield return(i_ui_base.PlayLeaveAnim());

            if (i_ui_base.GameObject.activeInHierarchy)
            {
                UIHelper.SetActive(i_ui_base.GameObject, false);
                i_ui_base.OnHide();
                if (!i_ui_base.IsStateUI)
                {
                    Backward(i_ui_base);
                }
            }

            if (on_hided != null)
            {
                on_hided();
            }
        }