Пример #1
0
 public void Init(CellViewInstantiated cellViewInstantiated,
                  OnDragDelegate scrollerDrag,
                  OnBeginDragDelegate scrollerBeginDrag,
                  OnEndDragDelegate scrollerEndDrag)
 {
     m_Scroller.Delegate             = this;
     m_Scroller.cellViewInstantiated = cellViewInstantiated;
     m_Scroller.scrollerDrag         = scrollerDrag;
     m_Scroller.scrollerBeginDrag    = scrollerBeginDrag;
     m_Scroller.scrollerEndDrag      = scrollerEndDrag;
     LoadData();
 }
Пример #2
0
        public void Init(CellViewInstantiated cellViewInstantiated,
                         ScrollerScrollingChangedDelegate scrollerScrollingChanged,
                         OnBeginDragDelegate scrollerBeginDrag,
                         OnEndDragDelegate scrollerEndDrag)
        {
            m_Scroller.Delegate                 = this;
            m_Scroller.cellViewInstantiated     = cellViewInstantiated;
            m_Scroller.scrollerScrollingChanged = scrollerScrollingChanged;
            m_Scroller.scrollerBeginDrag        = scrollerBeginDrag;
            m_Scroller.scrollerEndDrag          = scrollerEndDrag;

            CellSize = UIController.Instance.m_CanvasScaler.referenceResolution.x;
            LoadData();
            m_Scroller.ReloadData();
        }