예제 #1
0
 public void ToggleQuestList()
 {
     CEventSystem.Instance.PushEvent(GAME_EVENT_ID.GE_TOGLE_MISSION);
     if (questList == null)
     {
         questList = UIWindowMng.Instance.GetWindow("QuestListWindow");
     }
 }
예제 #2
0
 public void ToggleRoleWindow()
 {
     CEventSystem.Instance.PushEvent(GAME_EVENT_ID.GE_ROLE_TIPWINDOW);
     if (roleTipWin == null)
     {
         roleTipWin = UIWindowMng.Instance.GetWindow("RoleTipWindow");
     }
 }
예제 #3
0
 public void ToggleSkillWindow()
 {
     CEventSystem.Instance.PushEvent(GAME_EVENT_ID.GE_TOGLE_COMMONSKILL_PAGE);
     if (skillWin == null)
     {
         skillWin = UIWindowMng.Instance.GetWindow("RoleStudyWindow");
     }
 }
예제 #4
0
 public void ToggleSceneMap()
 {
     CEventSystem.Instance.PushEvent(GAME_EVENT_ID.GE_TOGLE_SCENEMAP);
     if (sceneMap == null)
     {
         sceneMap = UIWindowMng.Instance.GetWindow("SceneMapWindow");
     }
 }
예제 #5
0
    public void BringWindowForward(string windowName)
    {
        UIWindowItem win = GetWindow(windowName);

        if (win != null)
        {
            win.BringForward();
        }
    }
예제 #6
0
    public void HideWindow(string windowName)
    {
        UIWindowItem win = GetWindow(windowName);

        if (win != null)
        {
            win.Hide();
        }
    }
예제 #7
0
    public void ShowWindow(string windowName)
    {
        UIWindowItem win = GetWindow(windowName);

        if (win != null)
        {
            win.Show();
        }
    }
예제 #8
0
    public bool IsWindowShow(string winName)
    {
        UIWindowItem win = GetWindow(winName, false);

        if (win == null)
        {
            return(false);
        }
        return(win.winGo.active);
    }
예제 #9
0
    public GameObject GetWindowGo(string windowName)
    {
        UIWindowItem win = GetWindow(windowName);

        if (win != null)
        {
            return(win.winGo);
        }
        return(null);
    }
예제 #10
0
    void AskWindowDown(string winName)
    {
        // 如果找不到该窗口,则请求下载 [4/1/2012 Ivan]
        foreach (_DBC_UI_LAYOUTDEFINE layout in allLayouts.StructDict.Values)
        {
            if (layout.szName == winName)
            {
                UIWindowItem window = new UIWindowItem(layout);
                //预加载窗口
                window.PreLoadWindow();

                allWindows.Add(window);
            }
        }
    }
예제 #11
0
    public void BringForward()
    {
        if (lastWin == this || this.DemiseType == 0)
        {
            return;
        }
        Vector3 oldPos = winGo.transform.localPosition;

        winGo.transform.localPosition = new Vector3(oldPos.x, oldPos.y, UIZDepthManager.NearWinZ);

        if (lastWin != null && lastWin != this)
        {
            lastWin.ResetZDepth();
        }

        lastWin = this;
    }
예제 #12
0
    internal void DemiseWindow(UIWindowItem window)
    {
        if (window.IsCanDemise())
        {
            switch (window.DemiseType)
            {
            case 2:
            {
                HideDemiseWindow(window.DemiseType);
            }
            break;

            case 3:
            {
                HideDemiseWindow(window.DemiseType);
            }
            break;

            case 4:
            case 6:
            {
                CloseAllWindow();
                break;
            }

            case 5:     // 自适应窗口
            {
                //pItem->PositionSelf();
            }
            break;

            default:
                break;
            }
        }
    }