EditBtn: allow to clear TDateEdit.Text at designtime when DefaultToday=True and DirectInput=False. Issue #0030425.

git-svn-id: trunk@52777 -
This commit is contained in:
bart 2016-08-02 16:32:04 +00:00
parent 04209d1c09
commit 02c808e51f

View File

@ -1666,7 +1666,11 @@ begin
FDate := TextToDate(AValue, SysUtils.Date)
else
FDate := TextToDate(AValue, NullDate);
inherited RealSetText(DateToText(FDate));
//Allow to clear Text in Designer (Issue #0030425)
if (csDesigning in ComponentState) and (AValue = '') then
inherited RealSetText('')
else
inherited RealSetText(DateToText(FDate));
end else
inherited RealSetText(AValue);
end;