예제 #1
0
        public UIDisplay GetAreaDisplay(string name)
        {
            UIDisplay result = default;

            if (mMapper.ContainsKey(name))
            {
                int index = mMapper[name];
                result = m_Displays[index];
            }
            else
            {
            }

            return(result);
        }
예제 #2
0
        private void OnDestroy()
        {
            Events?.Clean();

            mMapper?.Dispose();
            mUIAreaNotice?.ToPool();
            mUIAreaNotice = default;
            mCurrent      = default;

            UIDisplay item;
            int       max = m_Displays.Length;

            for (int i = 0; i < max; i++)
            {
                item = m_Displays[i];
                item.Events?.RemoveListener(UIDisplay.N_UI_DISPLAY_SELECTED, OnUIDisplayChanged);
            }
            Utils.Reclaim(ref m_Displays);
        }
예제 #3
0
        public void DisplayView(string groupID, bool displayFlag, bool invalidPrevAllTargets = false)
        {
            if (mUIAreaNotice != default & mMapper.ContainsKey(groupID))
            {
                int       index = mMapper[groupID];
                UIDisplay item  = m_Displays[index];
                if (item != default)
                {
                    if (mCurrent != default)
                    {
                        if (invalidPrevAllTargets)
                        {
                            mCurrent.AllTargetInvalid();
                        }
                        else
                        {
                        }
                    }
                    else
                    {
                    }

                    if (item.IsRadio)
                    {
                        mCurrent = item;
                    }
                    else
                    {
                    }

                    item.Valid = displayFlag;
                }
                else
                {
                }
            }
            else
            {
                "error:Do not contais UIDisplay whitch named {0}".Log(groupID);
            }
        }