Exemplo n.º 1
0
        /// <summary>
        /// Adds the range item data.
        /// </summary>
        /// <param name="data">Data.</param>
        public void AddRangeItemData(IEnumerable <object> data)
        {
            var item = data.ToArray();

            InnerInfiniteScrollItemRepository.AddRange(item);
            _itemSizeList.AddRange(Enumerable.Repeat(defaultItemSize, item.Length));
            UpdateContents();
            _isUpdateCanvasRequest = true;
        }
Exemplo n.º 2
0
 /// <summary>
 /// Sets the item data.
 /// </summary>
 /// <param name="data">Data.</param>
 public void SetItemData(IEnumerable <object> data)
 {
     InnerInfiniteScrollItemRepository.Clear();
     InnerInfiniteScrollItemRepository.AddRange(data ?? new object[0]);
     _itemSizeList = Enumerable.Repeat(defaultItemSize, InnerInfiniteScrollItemRepository.Count).ToList();
     MovePositionAt(0);
     UpdateContents();
     _isUpdateCanvasRequest = true;
 }