Пример #1
0
    private void Hide_BotherPanels(UIMenuListItem item)
    {
        List <UIMenuListItem> childList = GetChildItems(item.Parent);

        for (int i = 0; i < childList.Count; i++)
        {
            if (childList[i] != item)
            {
                UIMenuPanel panel_bother = FindMenuPanel(childList[i]);
                if (panel_bother != null)
                {
                    if (panel_bother.isShow)
                    {
                        Hide_ChildPanel(childList[i]);
                        panel_bother.Hide();
                    }
                }
            }
        }
    }
Пример #2
0
    private void Hide_ChildPanel(UIMenuListItem item)
    {
        List <UIMenuListItem> childList = GetChildItems(item);

        for (int i = 0; i < childList.Count; i++)
        {
            if (childList[i].IsHaveChild)
            {
                UIMenuPanel panel_child = FindMenuPanel(childList[i]);
                if (panel_child != null)
                {
                    if (panel_child.isShow)
                    {
                        if (childList[i].IsHaveChild)
                        {
                            Hide_ChildPanel(childList[i]);
                        }
                        panel_child.Hide();
                    }
                }
            }
        }
    }
Пример #3
0
 public void Hide()
 {
     Hide_ChildPanel(null);
     rootPanel.Hide();
     IsShow = false;
 }