Skip to content

Commit

Permalink
fix min and max properties
Browse files Browse the repository at this point in the history
  • Loading branch information
comintern committed Nov 13, 2018
1 parent 479f27e commit 3ce3791
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions Rubberduck.Core/UI/Controls/NumberPicker.xaml.cs
Expand Up @@ -27,14 +27,13 @@ public int NumValue
}
}


public int MinNumber
{
get => (int)GetValue(MinNumberProperty);
set
{
SetValue(MinNumberProperty, value);
OnPropertyChanged(new DependencyPropertyChangedEventArgs(MinNumberProperty, NumValue - 1, NumValue));
OnPropertyChanged(new DependencyPropertyChangedEventArgs(MinNumberProperty, GetValue(MinNumberProperty), value));
}
}

Expand All @@ -44,7 +43,7 @@ public int MaxNumber
set
{
SetValue(MaxNumberProperty, value);
OnPropertyChanged(new DependencyPropertyChangedEventArgs(MaxNumberProperty, NumValue - 1, NumValue));
OnPropertyChanged(new DependencyPropertyChangedEventArgs(MaxNumberProperty, GetValue(MaxNumberProperty), value));
}
}

Expand Down

0 comments on commit 3ce3791

Please sign in to comment.