Beispiel #1
0
        private void SetupChatList()
        {
            MonoGridScroller component = base.view.transform.Find("Dialog/Content/ChatList/ScrollView").GetComponent <MonoGridScroller>();

            component.Init(new MonoGridScroller.OnChange(this.OnScrollChange), this.GetScrollerCount(), null);
            component.ScrollToEnd();
        }
Beispiel #2
0
        private void SetupFriendList()
        {
            MonoGridScroller component = base.view.transform.Find("Dialog/Content/FriendListPanel/FriendList/ScrollView").GetComponent <MonoGridScroller>();
            RectTransform    transform = base.view.transform.Find("Dialog/Content/FriendListPanel/FriendList").GetComponent <RectTransform>();
            int friendChatCount        = Singleton <ChatModule> .Instance.GetFriendChatCount();

            float size = Mathf.Clamp((float)((friendChatCount * 60f) + 30f), (float)215.3f, (float)351.3f);

            transform.SetSizeWithCurrentAnchors(RectTransform.Axis.Vertical, size);
            this._friendTabManager.Clear();
            component.Init(new MonoGridScroller.OnChange(this.OnFriendScrollChange), friendChatCount, null);
            component.ScrollToEnd();
        }