From 625cb2445942e024bec7f21a70dcbaf5cd95397d Mon Sep 17 00:00:00 2001 From: jujibo Date: Wed, 27 Nov 2013 11:27:42 +0000 Subject: [PATCH] Fix bugs and code refactoring git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@2853 8e941d3f-bd1b-0410-a28a-d453659cc2b4 --- components/jujiboutils/src/jlabeledintegeredit.pas | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/components/jujiboutils/src/jlabeledintegeredit.pas b/components/jujiboutils/src/jlabeledintegeredit.pas index 5de8c92ab..3ef5fe4cf 100644 --- a/components/jujiboutils/src/jlabeledintegeredit.pas +++ b/components/jujiboutils/src/jlabeledintegeredit.pas @@ -157,7 +157,7 @@ end; procedure TJLabeledIntegerEdit.FormatInput; begin - if fNull and (theValue = Low(integer)) then + if isNull then Text := '' else Text := FormatFloat(fFormat, theValue); @@ -168,7 +168,7 @@ begin inherited DoEnter; if ReadOnly then exit; - if not fNull then + if not isNull then Text := IntToStr(theValue); SelectAll; end; @@ -214,7 +214,7 @@ end; function TJLabeledIntegerEdit.isNull: boolean; begin - Result := theValue = Low(integer); + Result := fNull and (theValue = Low(integer)); end; end.