Ejemplo n.º 1
0
 private void HandleQueryItemVisibility(object sender, QueryItemVisibilityEventArgs e)
 {
     if (_loadedRows.Count > 0)
     {
         e.SetVisibleRange(_loadedRows.Min(), _loadedRows.Max());
     }
 }
        private void HandleQueryItemVisibility(object sender, QueryItemVisibilityEventArgs e)
        {
            var wrapPanel = AssociatedObject.GetItemsHost() as VirtualizingWrapPanel;

            if (wrapPanel != null)
            {
                var range = wrapPanel.GetVisibleItemsRange();
                e.SetVisibleRange(range.FirstRealizedItemIndex, range.LastRealizedItemIndex);
            }
        }