Example #1
0
 private void CheckData()
 {
     if (this.isLocalFileExist)
     {
         if (ButtonGroupState.ActiveGroup == CloudUI.SubMenuGroupButton)
         {
             ButtonGroupState.SetButtonEnable(this.UploadButton, true);
         }
         this.uploadButtonLabel.color = FF9TextTool.White;
     }
     else
     {
         if (ButtonGroupState.ActiveGroup == CloudUI.SubMenuGroupButton)
         {
             ButtonGroupState.SetButtonEnable(this.UploadButton, false);
         }
         this.uploadButtonLabel.color = FF9TextTool.Gray;
     }
     if (this.isCloudFileExist)
     {
         if (ButtonGroupState.ActiveGroup == CloudUI.SubMenuGroupButton)
         {
             ButtonGroupState.SetButtonEnable(this.DownloadButton, true);
         }
         this.downloadButtonLabel.color = FF9TextTool.White;
     }
     else
     {
         if (ButtonGroupState.ActiveGroup == CloudUI.SubMenuGroupButton)
         {
             ButtonGroupState.SetButtonEnable(this.DownloadButton, false);
         }
         this.downloadButtonLabel.color = FF9TextTool.Gray;
     }
 }
Example #2
0
    private void SetAvalableCharacter(Boolean includeEmpty)
    {
        List <CharacterDetailHUD> characterDetailHudList = new List <CharacterDetailHUD>();

        if (!includeEmpty)
        {
            using (List <CharacterDetailHUD> .Enumerator enumerator = _targetHudList.GetEnumerator())
            {
                while (enumerator.MoveNext())
                {
                    CharacterDetailHUD current = enumerator.Current;
                    if (current.Content.activeSelf)
                    {
                        characterDetailHudList.Add(current);
                        ButtonGroupState.SetButtonEnable(current.Self, true);
                    }
                    else
                    {
                        ButtonGroupState.SetButtonEnable(current.Self, false);
                    }
                }
            }
        }
        else
        {
            using (List <CharacterDetailHUD> .Enumerator enumerator = _targetHudList.GetEnumerator())
            {
                while (enumerator.MoveNext())
                {
                    CharacterDetailHUD current = enumerator.Current;
                    characterDetailHudList.Add(current);
                    ButtonGroupState.SetButtonEnable(current.Self, true);
                }
            }
        }
        for (Int32 index1 = 0; index1 < characterDetailHudList.Count; ++index1)
        {
            Int32 index2 = index1 - 1;
            Int32 index3 = index1 + 1;
            if (index1 == 0)
            {
                index2 = characterDetailHudList.Count - 1;
            }
            if (index1 == characterDetailHudList.Count - 1)
            {
                index3 = 0;
            }
            UIKeyNavigation component = characterDetailHudList[index1].Self.GetComponent <UIKeyNavigation>();
            component.onUp   = characterDetailHudList[index2].Self;
            component.onDown = characterDetailHudList[index3].Self;
        }
    }
Example #3
0
    private void SetAvalableCharacter(Boolean includeEmpty)
    {
        List <CharacterDetailHUD> list = new List <CharacterDetailHUD>();

        if (!includeEmpty)
        {
            foreach (CharacterDetailHUD characterDetailHUD in this.CharacterHUDList)
            {
                if (characterDetailHUD.Content.activeSelf)
                {
                    list.Add(characterDetailHUD);
                    ButtonGroupState.SetButtonEnable(characterDetailHUD.Self, true);
                }
                else
                {
                    ButtonGroupState.SetButtonEnable(characterDetailHUD.Self, false);
                }
            }
        }
        else
        {
            foreach (CharacterDetailHUD characterDetailHUD2 in this.CharacterHUDList)
            {
                list.Add(characterDetailHUD2);
                ButtonGroupState.SetButtonEnable(characterDetailHUD2.Self, true);
            }
        }
        for (Int32 i = 0; i < list.Count; i++)
        {
            Int32 index  = i - 1;
            Int32 index2 = i + 1;
            if (i == 0)
            {
                index = list.Count - 1;
            }
            if (i == list.Count - 1)
            {
                index2 = 0;
            }
            UIKeyNavigation component = list[i].Self.GetComponent <UIKeyNavigation>();
            component.onUp   = list[index].Self;
            component.onDown = list[index2].Self;
        }
    }
Example #4
0
 public override Boolean OnKeyConfirm(GameObject go)
 {
     if (base.OnKeyConfirm(go))
     {
         if (ButtonGroupState.ActiveGroup == SelectCharGroupButton)
         {
             FF9Sfx.FF9SFX_Play(103);
             this.currentCharacterSelect = this.GetCurrentSelect(go);
             this.currentCharacterId     = this.GetCurrentId(go);
             ButtonGroupState.SetCursorStartSelect((this.currentCharacterSelect.Group != Mode.Menu) ? go.GetChild(0) : go.GetChild(2), MoveCharGroupButton);
             ButtonGroupState.RemoveCursorMemorize(MoveCharGroupButton);
             ButtonGroupState.ActiveGroup = MoveCharGroupButton;
             ButtonGroupState.HoldActiveStateOnGroup(SelectCharGroupButton);
             foreach (CharacterOutsidePartyHud current in this.outsidePartyHudList)
             {
                 ButtonGroupState.SetButtonEnable(current.MoveButton, this.currentCharacterId == FF9PARTY_NONE || !this.info.fix[this.currentCharacterId]);
             }
         }
         else if (ButtonGroupState.ActiveGroup == MoveCharGroupButton)
         {
             PartySelect currentSelect = this.GetCurrentSelect(go);
             Byte        currentId     = this.GetCurrentId(go);
             if (this.currentCharacterSelect.Group == Mode.Select && currentId != FF9PARTY_NONE && this.info.fix[currentId])
             {
                 FF9Sfx.FF9SFX_Play(102);
             }
             else
             {
                 FF9Sfx.FF9SFX_Play(103);
                 this.SwapCharacter(this.currentCharacterSelect, currentSelect);
                 this.DisplayCharacter();
                 this.DisplayCharacterInfo(this.currentCharacterId);
                 ButtonGroupState.SetCursorMemorize(go.transform.parent.gameObject, SelectCharGroupButton);
                 ButtonGroupState.ActiveGroup = SelectCharGroupButton;
             }
         }
     }
     return(true);
 }