ExCtrls: Version checks for CurrencyEditEx.SameValue.

git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@8504 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
wp_xxyyzz
2022-10-01 13:32:26 +00:00
parent c23ad4d5a4
commit 17cb4d1473
3 changed files with 7 additions and 4 deletions

View File

@ -7,6 +7,7 @@ interface
uses
Classes, SysUtils;
procedure Register;
implementation

View File

@ -11,7 +11,9 @@ uses
Classes, SysUtils, LCLVersion, Controls, SpinEx, Math;
// Fix of issues #39490 (FPC >v3.2.2/64bit) and #39793 (Laz >= 2.3.0)
{.$define SAMEVALUE_FIX}
{$IF ((FPC_FullVersion >= 30202) and (LCL_FullVersion >= 2030000)) or DEFINED(Win64)}
{$define SAMEVALUE_FIX}
{$IFEND}
type
{ TCustomCurrEditEx }
@ -61,7 +63,7 @@ type
function SafeInc(AValue: Currency): Currency; override;
function SafeDec(AValue: Currency): Currency; override;
{$IFDEF SAMEVALUE_FIX}
function SameValue(AValue1, AValue2: Currency): Boolean; override;
function SameValue(AValue1, AValue2: Currency): Boolean; {$IF LCL_FullVersion >= 2030000}override;{$IFEND}
{$ENDIF}
function TextIsNumber(const S: String; out ANumber: Currency): Boolean; override;
function TryExtractCurrency(AText: String; out AValue: Currency;
@ -306,7 +308,6 @@ begin
end;
{ TCustomCurrSpinEditEx }
constructor TCustomCurrSpinEditEx.Create(AOwner: TComponent);
begin
inherited;
@ -549,6 +550,7 @@ begin
end;
end;
end;
{$IF LCL_FullVersion < 2010000}
procedure TCustomFloatSISpinEditEx.EditKeyPress(var Key: char);
begin