Allow MaxValue and MinValue of TUI.Slider to be equal
This commit is contained in:
parent
a70f4f4393
commit
70fa52a59a
|
@ -53,7 +53,7 @@ namespace CC_Functions.Commandline.TUI
|
||||||
get => _maxValue;
|
get => _maxValue;
|
||||||
set
|
set
|
||||||
{
|
{
|
||||||
if (value > MinValue && value >= Value)
|
if (value >= MinValue && value >= Value)
|
||||||
_maxValue = value;
|
_maxValue = value;
|
||||||
else
|
else
|
||||||
throw new ArgumentOutOfRangeException(
|
throw new ArgumentOutOfRangeException(
|
||||||
|
@ -70,7 +70,7 @@ namespace CC_Functions.Commandline.TUI
|
||||||
get => _minValue;
|
get => _minValue;
|
||||||
set
|
set
|
||||||
{
|
{
|
||||||
if (value < MaxValue && value <= Value)
|
if (value <= MaxValue && value <= Value)
|
||||||
_minValue = value;
|
_minValue = value;
|
||||||
else
|
else
|
||||||
throw new ArgumentOutOfRangeException(
|
throw new ArgumentOutOfRangeException(
|
||||||
|
|
Reference in New Issue