From ff62abace0d2aa3b198d13f4b7a5dcaedb670f6a Mon Sep 17 00:00:00 2001 From: bart <9132501-flyingsheep@users.noreply.gitlab.com> Date: Sun, 16 Aug 2020 13:47:24 +0000 Subject: [PATCH] SpinEx: allow to read the inernal formatsettings of TCustomFloatSpinEditEx (needed for derived controls). git-svn-id: trunk@63754 - --- components/lazcontrols/spinex.inc | 5 +++++ components/lazcontrols/spinex.pp | 1 + 2 files changed, 6 insertions(+) diff --git a/components/lazcontrols/spinex.inc b/components/lazcontrols/spinex.inc index 6c9b61934f..0aaf8a4a56 100644 --- a/components/lazcontrols/spinex.inc +++ b/components/lazcontrols/spinex.inc @@ -437,6 +437,11 @@ begin UpdateControl; end; +function TCustomFloatSpinEditEx.GetFormatsettings: TFormatSettings; +begin + Result := FFS; +end; + procedure TCustomFloatSpinEditEx.EditKeyPress(var Key: char); begin diff --git a/components/lazcontrols/spinex.pp b/components/lazcontrols/spinex.pp index a5ff80cc2d..0884ef8fcb 100644 --- a/components/lazcontrols/spinex.pp +++ b/components/lazcontrols/spinex.pp @@ -195,6 +195,7 @@ type procedure SetExponentialFormatLimitPos(AValue: Integer); procedure SetPrecision(AValue: Integer); protected + function GetFormatsettings: TFormatSettings; procedure EditKeyPress(var Key: char); override; function TextIsNumber(const S: String; out ANumber: Double): Boolean; override; function SafeInc(AValue: Double): Double; override;