mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-12 00:46:02 +02:00
* Fixed TimeToStr and DateTimeToStr so they are delphi compatible
git-svn-id: trunk@6986 -
This commit is contained in:
parent
dc4cb7170c
commit
74cbe82e3f
@ -300,14 +300,14 @@ begin
|
|||||||
result := FormatDateTime('ddddd', Date);
|
result := FormatDateTime('ddddd', Date);
|
||||||
end ;
|
end ;
|
||||||
|
|
||||||
{ TimeToStr returns a string representation of Time using ShortTimeFormat }
|
{ TimeToStr returns a string representation of Time using LongTimeFormat }
|
||||||
|
|
||||||
function TimeToStr(Time: TDateTime): string;
|
function TimeToStr(Time: TDateTime): string;
|
||||||
begin
|
begin
|
||||||
result := FormatDateTime('t', Time);
|
result := FormatDateTime('tt', Time);
|
||||||
end ;
|
end ;
|
||||||
|
|
||||||
{ DateTimeToStr returns a string representation of DateTime using ShortDateTimeFormat }
|
{ DateTimeToStr returns a string representation of DateTime using LongDateTimeFormat }
|
||||||
|
|
||||||
function DateTimeToStr(DateTime: TDateTime): string;
|
function DateTimeToStr(DateTime: TDateTime): string;
|
||||||
begin
|
begin
|
||||||
@ -695,7 +695,7 @@ var
|
|||||||
if (Hour<>0) or (Minute<>0) or (Second<>0) then
|
if (Hour<>0) or (Minute<>0) or (Second<>0) then
|
||||||
begin
|
begin
|
||||||
StoreString(' ');
|
StoreString(' ');
|
||||||
StoreFormat(TimeReformat(ShortTimeFormat));
|
StoreFormat(TimeReformat(LongTimeFormat));
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
Loading…
Reference in New Issue
Block a user