コード例 #1
0
        /// <summary>
        /// 移除动态面板所在层级的堆栈信息
        /// </summary>
        /// <param name="win"></param>
        public void RemoveWindowDynOrder(UIBaseWindow win)
        {
            if (win.staticLayerIndex != -1)
            {
                return;
            }

            UILayerInfo info = this.GetLayerInfo(win.WindowType);

            info.RemoveDynamicLayerIndex(win);
        }
コード例 #2
0
        /// <summary>
        /// 在面板显示之前和初始化之前设置好面板的层级,动态层级的前后关系由ShowWindow的调用顺序来决定,每个层级会有10个层的间隔用来给粒子特效使用
        /// </summary>
        /// <param name="baseWin"></param>
        public void SetWindowDynOrder(UIBaseWindow baseWin)
        {
            //静态面板不设置
            if (baseWin.staticLayerIndex != -1)
            {
                return;
            }

            UILayerInfo info = this.GetLayerInfo(baseWin.WindowType);

            int index = info.GetNewDynamicLayerIndex(baseWin);

            baseWin.SetDynamicLayerIndex(index);
        }