Exemple #1
0
 private void OnSortChange(int idx)
 {
     if ((FriendList.eSortType)idx == this.mSortType || 0 > idx || idx >= 3)
     {
         return;
     }
     this.mSortType = (FriendList.eSortType)idx;
     this.Refresh();
     if (string.IsNullOrEmpty(PlayerPrefsUtility.PREFS_KEY_FRIEND_SORT))
     {
         return;
     }
     PlayerPrefsUtility.SetInt(PlayerPrefsUtility.PREFS_KEY_FRIEND_SORT, idx, true);
 }
Exemple #2
0
 private void OnSortChange(int idx)
 {
     if ((FriendList.eSortType)idx == this.mSortType || 0 > idx || idx >= 3)
     {
         return;
     }
     this.mSortType = (FriendList.eSortType)idx;
     this.Refresh();
     if (string.IsNullOrEmpty("FRIENDLIST_SORTTYPE"))
     {
         return;
     }
     PlayerPrefs.SetInt("FRIENDLIST_SORTTYPE", idx);
     PlayerPrefs.Save();
 }
Exemple #3
0
 private void SortPulldownInit()
 {
     if (!string.IsNullOrEmpty("FRIENDLIST_SORTTYPE") && PlayerPrefs.HasKey("FRIENDLIST_SORTTYPE"))
     {
         int num = PlayerPrefs.GetInt("FRIENDLIST_SORTTYPE");
         if (0 <= num && num < 3)
         {
             this.mSortType = (FriendList.eSortType)num;
         }
     }
     if (!Object.op_Inequality((Object)this.SortPulldown, (Object)null))
     {
         return;
     }
     this.SortPulldown.OnSelectionChangeDelegate = new Pulldown.SelectItemEvent(this.OnSortChange);
     this.SortPulldown.ClearItems();
     for (int index = 0; index < this.mSortString.Length; ++index)
     {
         this.SortPulldown.AddItem(LocalizedText.Get(this.mSortString[index]), index);
     }
     this.SortPulldown.Selection = (int)this.mSortType;
     this.SortPulldown.set_interactable(true);
     ((Component)this.SortPulldown).get_gameObject().SetActive(true);
 }