예제 #1
0
    protected override void OnEnable()
    {
        CurrenciesUIViewModel.Show(true);
        CurrenciesUIViewModel.Instance.SetSubUI(true, ResourceManager.GetIconSprite("nav_font_lcxs"), string.Empty, delegate
        {
            base.Show(false);
            UIStackManager.Instance.PopUIPrevious(base.uiType);
        }, false);
        ChangePetChooseUI changePetChooseUI = UIManagerControl.Instance.OpenUI("ChangePetChooseUI", null, false, UIType.NonPush) as ChangePetChooseUI;

        if (changePetChooseUI != null)
        {
            changePetChooseUI.RefreshUI(PetFormationType.FORMATION_TYPE.Bounty, base.get_transform(), 0);
            Canvas canvas = changePetChooseUI.get_gameObject().AddComponent <Canvas>();
            canvas.set_overrideSorting(true);
            canvas.set_sortingOrder(2020);
            changePetChooseUI.get_gameObject().AddComponent <GraphicRaycaster>();
        }
        this.RefreshUI();
        this.GettingReward = false;
        this.FxUidList.Add(FXSpineManager.Instance.ReplaySpine(0, 1706, base.get_transform(), "BountyUI", 2002, null, "UI", -127f, 0f, 1f, 1f, false, FXMaskLayer.MaskState.None));
        this.FxUidList.Add(FXSpineManager.Instance.ReplaySpine(0, 1707, base.get_transform(), "BountyUI", 2002, null, "UI", -127f, 0f, 1f, 1f, false, FXMaskLayer.MaskState.None));
        this.FxUidList.Add(FXSpineManager.Instance.ReplaySpine(0, 1708, base.get_transform(), "BountyUI", 2003, null, "UI", -127f, 0f, 1f, 1f, false, FXMaskLayer.MaskState.None));
        CurrenciesUIView currenciesUIView = UIManagerControl.Instance.GetUIIfExist("CurrenciesUI") as CurrenciesUIView;

        if (currenciesUIView != null)
        {
            Canvas canvas2 = currenciesUIView.get_gameObject().AddComponent <Canvas>();
            canvas2.set_overrideSorting(true);
            canvas2.set_sortingOrder(2020);
            currenciesUIView.get_gameObject().AddComponent <GraphicRaycaster>();
        }
    }
예제 #2
0
 protected override void ReleaseSelf(bool calledDestroy)
 {
     if (SystemConfig.IsReleaseResourceOn && calledDestroy)
     {
         CurrenciesUIView.Instance      = null;
         CurrenciesUIViewModel.Instance = null;
         base.ReleaseSelf(true);
     }
 }
예제 #3
0
    protected override void OnDisable()
    {
        base.OnDisable();
        for (int i = 0; i < this.FxUidList.get_Count(); i++)
        {
            FXSpineManager.Instance.DeleteSpine(this.FxUidList.get_Item(i), true);
        }
        ChangePetChooseUI changePetChooseUI = UIManagerControl.Instance.OpenUI("ChangePetChooseUI", null, false, UIType.NonPush) as ChangePetChooseUI;

        if (changePetChooseUI != null)
        {
            Object.Destroy(changePetChooseUI.GetComponent <GraphicRaycaster>());
            Object.Destroy(changePetChooseUI.GetComponent <Canvas>());
        }
        CurrenciesUIView currenciesUIView = UIManagerControl.Instance.GetUIIfExist("CurrenciesUI") as CurrenciesUIView;

        if (currenciesUIView != null)
        {
            Object.Destroy(currenciesUIView.GetComponent <GraphicRaycaster>());
            Object.Destroy(currenciesUIView.GetComponent <Canvas>());
        }
        UIManagerControl.Instance.HideUI("ChangePetChooseUI");
    }
예제 #4
0
 private void Awake()
 {
     CurrenciesUIView.Instance = this;
     base.AwakeBase(BindingContext.BindingContextMode.MonoBinding, false);
 }