/// <summary> /// 关闭并卸载UI /// </summary> /// <param name="behaviourName"></param> public void CloseUI(string behaviourName) { IUIBehaviour behaviour = null; mAllUI.TryGetValue(behaviourName, out behaviour); if (null != behaviour) { behaviour.Close(); mAllUI.Remove(behaviourName); } }
/// <summary> /// 关闭并卸载UI /// </summary> /// <param name="behaviourName"></param> public void CloseUI(string behaviourName) { IUIBehaviour behaviour = null; mAllUI.TryGetValue(behaviourName, out behaviour); if (null != behaviour) { behaviour.Close(); mAllUI.Remove(behaviourName); mUIPanelStack.RemoveUI(behaviourName, behaviour); mLayerLogic.OnUIPanelClose(behaviour as QUIBehaviour); ReSetLayerIndexDirty(); } }