From a65acdc41977a245d95c1b5c02eb03ec60017f43 Mon Sep 17 00:00:00 2001 From: bart <9132501-flyingsheep@users.noreply.gitlab.com> Date: Sun, 15 Feb 2015 11:05:19 +0000 Subject: [PATCH] TDateEdit: Remove method DateFormatChanged: it exposes a private field that is only meant for internal use, and should not be changed by user. git-svn-id: trunk@47794 - --- lcl/editbtn.pas | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/lcl/editbtn.pas b/lcl/editbtn.pas index 4d810f42c2..b1aa942c02 100644 --- a/lcl/editbtn.pas +++ b/lcl/editbtn.pas @@ -754,7 +754,6 @@ type procedure SetDateMask; virtual; public constructor Create(AOwner: TComponent); override; - procedure DateFormatChanged; virtual; function GetDateFormat: string; property AutoSelected; property Date: TDateTime read GetDate write SetDate; @@ -2308,13 +2307,8 @@ begin FDisplaySettings := [dsShowHeadings, dsShowDayNames]; OKCaption := 'OK'; CancelCaption := 'Cancel'; - DateFormatChanged; end; -procedure TDateEdit.DateFormatChanged; -begin - FDateFormat := DefaultFormatSettings.ShortDateFormat; -end; function TDateEdit.GetDateFormat: string; begin @@ -2654,7 +2648,7 @@ begin Text := '' else begin - if (FDateFormat = '') then + if (FDateOrder = doNone) or (FDateFormat = '') then Text := DateToStr(Value) else Text := FormatDateTime(FDateFormat, Value)