Exemplo n.º 1
0
 public static void ItemIndexDecrement <T>(this NotifiableCollection <T> collection, T item, int count = 1)
 {
     if (collection != null)
     {
         collection.Move(collection.IndexOf(item), count);
     }
 }
Exemplo n.º 2
0
        public ColumnManager(IAccount account, NotifiableCollection <ColumnBase> allColumns)
        {
            this._account    = account;
            this._allColumns = allColumns;
            this._columns    = new List <ColumnBase>(10);
            this.ResetColumns(this._columns);

            this._allColumns.CollectionChanged += this.OnCollectionChanged;
        }
Exemplo n.º 3
0
 public ColumnRemoveCommand() : base(true)
 {
     this._columns = App.Columns;
 }
Exemplo n.º 4
0
 public static bool CanItemIndexIncrement <T>(this NotifiableCollection <T> collection, T item, int downCount = 1)
 {
     return(collection.CanItemIndexIncrement(collection.IndexOf(item), downCount));
 }
Exemplo n.º 5
0
 public static bool CanItemIndexIncrement <T>(this NotifiableCollection <T> collection, int currentIndex, int downCount = 1)
 {
     return(MathEx.IsWithin(currentIndex, 0, collection.Count - (1 + downCount)));
 }
Exemplo n.º 6
0
 public static void ItemIndexIncrement <T>(this NotifiableCollection <T> collection, T item, int count = 1)
 {
     collection.ItemIndexIncrement(collection.IndexOf(item), count);
 }
Exemplo n.º 7
0
 public static void ItemIndexIncrement <T>(this NotifiableCollection <T> collection, int oldIndex, int count = 1)
 {
     collection.Move(oldIndex, oldIndex + count);
 }
Exemplo n.º 8
0
 public static bool CanItemIndexDecrement <T>(this NotifiableCollection <T> collection, int currentIndex, int count)
 {
     return(MathEx.IsWithin(currentIndex, count, collection.Count - 1));
 }
Exemplo n.º 9
0
 public ColumnMoveLeftCommand() : base(true)
 {
     this._columns = App.Columns;
     this._columns.CollectionChanged += this.ColumnsChanged;
 }