|
@@ -2099,8 +2099,8 @@ function EnsureRange(const AValue, AMin, AMax: Integer): Integer;inline;
|
|
begin
|
|
begin
|
|
Result:=AValue;
|
|
Result:=AValue;
|
|
If Result<AMin then
|
|
If Result<AMin then
|
|
- Result:=AMin
|
|
|
|
- else if Result>AMax then
|
|
|
|
|
|
+ Result:=AMin;
|
|
|
|
+ if Result>AMax then
|
|
Result:=AMax;
|
|
Result:=AMax;
|
|
end;
|
|
end;
|
|
|
|
|
|
@@ -2109,8 +2109,8 @@ function EnsureRange(const AValue, AMin, AMax: Int64): Int64;inline;
|
|
begin
|
|
begin
|
|
Result:=AValue;
|
|
Result:=AValue;
|
|
If Result<AMin then
|
|
If Result<AMin then
|
|
- Result:=AMin
|
|
|
|
- else if Result>AMax then
|
|
|
|
|
|
+ Result:=AMin;
|
|
|
|
+ if Result>AMax then
|
|
Result:=AMax;
|
|
Result:=AMax;
|
|
end;
|
|
end;
|
|
|
|
|
|
@@ -2120,8 +2120,8 @@ function EnsureRange(const AValue, AMin, AMax: Double): Double;inline;
|
|
begin
|
|
begin
|
|
Result:=AValue;
|
|
Result:=AValue;
|
|
If Result<AMin then
|
|
If Result<AMin then
|
|
- Result:=AMin
|
|
|
|
- else if Result>AMax then
|
|
|
|
|
|
+ Result:=AMin;
|
|
|
|
+ if Result>AMax then
|
|
Result:=AMax;
|
|
Result:=AMax;
|
|
end;
|
|
end;
|
|
{$endif FPC_HAS_TYPE_DOUBLE}
|
|
{$endif FPC_HAS_TYPE_DOUBLE}
|