Skip to content

Instantly share code, notes, and snippets.

@jasondown
Created August 3, 2021 07:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jasondown/237c9c4239a5723c9cc6b19453d6e8dc to your computer and use it in GitHub Desktop.
Save jasondown/237c9c4239a5723c9cc6b19453d6e8dc to your computer and use it in GitHub Desktop.
private SmartObservableCollection<ImageViewModel> _pageableImages;
public SmartObservableCollection<ImageViewModel> PageableImages
{
get
{
if (_pageableImages == null)
{
_pageableImages = new SmartObservableCollection<ImageViewModel>();
_images.CollectionChanged += (s, e) => OnPropertyChanged();
}
return _pageableImages;
}
}
private int _pageSize;
/// <summary>
/// Gets or sets the number of images for a single page.
/// </summary>
/// <value>
/// The number of images for a single page.
/// </value>
public int PageSize
{
get { return _pageSize; }
set
{
if (_pageSize != value)
{
_pageSize = value;
OnPropertyChanged();
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment