anchor.diff:  begin
     Result := UniversalTimeToLocal(d,-GetLocalTimeOffset);
   end;
  -
   {$ELSE}
  -var
  - TZI:TTimeZoneInformation;
  - LocalTime, UniversalTime:TSystemTime;
   begin
  -  GetTimeZoneInformation(tzi);
  -  DateTimeToSystemTime(d,UniversalTime);
  -  SystemTimeToTzSpecificLocalTime(@tzi,UniversalTime,LocalTime);
  -  Result := SystemTimeToDateTime(LocalTime);
  +  Result := TTimeZone.Local.ToLocalTime(d);
   end;
   {$ENDIF}
   
  
positive.code: function UnivDateTimeToUnix(dtDate: TDateTime): Longint;
  function UnixToUnivDateTime(USec: Longint): TDateTime;
  
  function UnixTimeToLocalElapsedTime(USec : Longint) : AnsiString;
  Function DateTimeElapsedTime(dtDate : TDateTime) : AnsiString;
  
  Function UnixTimeToLocalStr(UnixTime : Longint) : AnsiString;
  
  implementation
  
  {$IFDEF FPC}
  Uses DateUtils;
  {$ELSE}
  function TzSpecificLocalTimeToSystemTime; external 'kernel32.dll' name 'TzSpecificLocalTimeToSystemTime';
  function SystemTimeToTzSpecificLocalTime; external kernel32 name 'SystemTimeToTzSpecificLocalTime';
  {$ENDIF}
  
  const
      UnixStartDate: TDateTime = 25569.0; // 01/01/1970
  
  function UnixTimeToLocalElapsedTime(USec : Longint) : AnsiString;
  Var diff, positivediff : Longint;
  Begin
    diff := UnivDateTimeToUnix(DateTime2UnivDateTime(now)) - Usec;
  
negative.code: 
  Uses
  {$IFnDEF FPC}
    System.DateUtils,
  {$ELSE}
    {LCLIntf, LCLType, LMessages,}
  {$ENDIF}
    SysUtils;
  
  Function DateTime2UnivDateTime(d:TDateTime):TDateTime;
  Function UnivDateTime2LocalDateTime(d:TDateTime):TDateTime;
  