Browse Source

ISelectionModel implements INotifyPropertyChanged.

This will be needed for monitoring the `AnchorIndex` in order to auto-scroll.
pull/3469/head
Steven Kirk 7 years ago
parent
commit
e4d45fc46d
  1. 3
      src/Avalonia.Controls/ISelectionModel.cs
  2. 2
      src/Avalonia.Controls/SelectionModel.cs

3
src/Avalonia.Controls/ISelectionModel.cs

@ -5,10 +5,11 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
namespace Avalonia.Controls
{
public interface ISelectionModel
public interface ISelectionModel : INotifyPropertyChanged
{
IndexPath AnchorIndex { get; set; }
IndexPath SelectedIndex { get; set; }

2
src/Avalonia.Controls/SelectionModel.cs

@ -12,7 +12,7 @@ using Avalonia.Controls.Utils;
namespace Avalonia.Controls
{
public class SelectionModel : ISelectionModel, INotifyPropertyChanged, IDisposable
public class SelectionModel : ISelectionModel, IDisposable
{
private readonly SelectionNode _rootNode;
private bool _singleSelect;

Loading…
Cancel
Save