Exemplo n.º 1
0
    void Awake()
    {
        GetComponent <M4uContextRoot>().Context = this;

        if (AndroidBackKeyManager.HasInstance)
        {
            //バックキーが押された時のアクションを登録
            AndroidBackKeyManager.Instance.StackPush(gameObject, OnSelectReturn);
        }

        GameObject charParent = null;

        if (m_CharaImageRoot.Length > 0)
        {
            charParent = m_CharaImageRoot[0];
        }
        m_Character = GeneralWindowCharacterView.Attach(charParent);

        for (int i = 0; i < (int)ButtonEventType.MAX; ++i)
        {
            m_ButtunActionList[i] = null;
        }

        SetUpButtons();

        m_WindowRect = m_Window.GetComponent <RectTransform>();
        m_Window.SetPosition(new Vector2(m_WindowRect.rect.width, m_WindowRect.anchoredPosition.y));
        m_Window.transform.localScale = new Vector3(0, 0, 0);
    }
Exemplo n.º 2
0
    void Awake()
    {
        GetComponent <M4uContextRoot>().Context = this;
        if (AndroidBackKeyManager.HasInstance)
        {
            //バックキーが押された時のアクションを登録
            AndroidBackKeyManager.Instance.StackPush(gameObject, OnClose);
        }

        m_WindowRect = m_Window.GetComponent <RectTransform>();
        m_Window.SetPosition(new Vector2(m_WindowRect.rect.width, m_WindowRect.anchoredPosition.y));
        m_Window.transform.localScale     = new Vector3(0, 0, 0);
        m_ScrollRect.transform.localScale = new Vector3(0, 0, 0);
        SetUpButtons();
    }