Esempio n. 1
0
 /// <summary>
 ///关闭除HUD外的所有窗口
 /// </summary>
 public void CloseAllWndExceptHUD(string name)
 {
     foreach (UIWndData data in DBManager.m_DBUIWnd.GetUIWndData().Values)
     {
         UIBaseWnd wnd = UIBaseWnd.GetWndByName(data.WndName);
         if (wnd != null && !string.Equals(data.WndName, "HUD") && !string.Equals(data.WndName, name) && wnd.IsOpen())
         {
             wnd.CloseWnd();
         }
     }
 }
Esempio n. 2
0
        public void SwitchWnd(string strWndName)
        {
            UIBaseWnd wnd = UIBaseWnd.GetWndByName(strWndName);

            if (wnd == null)
            {
                Debuger.LogError("Open Window " + strWndName + "fail!");
                return;
            }

            wnd.SwitchWnd();
        }
Esempio n. 3
0
        public UIBaseWnd GetWnd(string strWndName)
        {
            UIBaseWnd wnd = UIBaseWnd.GetWndByName(strWndName);

            if (wnd == null)
            {
                Debuger.LogError("Get Window " + strWndName + "fail!");
                return(null);
            }

            return(wnd);
        }
Esempio n. 4
0
        public void CloseWnd(string strWndName)
        {
            UIBaseWnd wnd = UIBaseWnd.GetWndByName(strWndName);

            if (wnd == null)
            {
                Debuger.LogError("Close Window " + strWndName + "fail!");
                return;
            }
            //Debuger.Log("CloseWnd " + strWndName);
            wnd.CloseWnd();
        }
Esempio n. 5
0
        public void OpenWnd(string strWndName)
        {
            UIBaseWnd wnd = UIBaseWnd.GetWndByName(strWndName);

            if (wnd == null)
            {
                Debuger.LogError("Open Window " + strWndName + "fail!");
                return;
            }

            //if (GameApp.GetGuideManager() != null)
            //    GameApp.GetGuideManager().OpenWindow(strWndName);
            wnd.OpenWnd();
        }
Esempio n. 6
0
 public void CloseAllWnd()
 {
     foreach (UIWndData data in DBManager.m_DBUIWnd.GetUIWndData().Values)
     {
         UIBaseWnd wnd = UIBaseWnd.GetWndByName(data.WndName);
         if (wnd == null)
         {
             Debuger.LogWarning("CloseAllWnd is error=" + data.WndName);
         }
         else if (wnd.IsOpen())
         {
             wnd.CloseWnd();
         }
     }
 }
Esempio n. 7
0
        public bool OnlyHudOpen()
        {
            UIBaseWnd wnd = UIBaseWnd.GetWndByName("HUD");

            if (!wnd.IsOpen())
            {
                return(false);
            }

            foreach (UIBaseWnd data in UIBaseWnd.DicWnd.Values)
            {
                if (data.m_strWndName != "HUD")
                {
                    if (data.IsOpen())
                    {
                        return(false);
                    }
                }
            }
            return(true);
        }