X-Git-Url: http://www.lcore.org/git/lcore.git/blobdiff_plain/5c04c841812bdb200cc3c73169b1542aef6c2fc3..8bffcf295dad495a39dabb9c6915c1692738b3fa:/btime.pas?ds=inline diff --git a/btime.pas b/btime.pas index ea199c6..9bb9550 100644 --- a/btime.pas +++ b/btime.pas @@ -20,7 +20,7 @@ const var timezone:integer; - timezonestr:ansistring; + timezonestr:string; irctime,unixtime:integer; tickcount:integer; settimebias:integer; @@ -39,8 +39,8 @@ procedure gettimezone; procedure timehandler; procedure init; -function timestring(i:integer):ansistring; -function timestrshort(i:integer):ansistring; +function timestring(i:integer):string; +function timestrshort(i:integer):string; {$ifdef win32} function unixtimefloat_systemtime:float; @@ -543,13 +543,13 @@ begin if timezone >= 0 then timezonestr := '+' else timezonestr := '-'; l := abs(timezone) div 60; - timezonestr := timezonestr + ansichar(l div 600 mod 10+48)+ansichar(l div 60 mod 10+48)+':'+ansichar(l div 10 mod 6+48)+ansichar(l mod 10+48); + timezonestr := timezonestr + char(l div 600 mod 10+48)+char(l div 60 mod 10+48)+':'+char(l div 10 mod 6+48)+char(l mod 10+48); end; -function timestrshort(i:integer):ansistring; +function timestrshort(i:integer):string; const - weekday:array[0..6] of ansistring =('Thu','Fri','Sat','Sun','Mon','Tue','Wed'); - month:array[0..11] of ansistring =('Jan','Feb','Mar','Apr','May','Jun','Jul','Aug','Sep','Oct','Nov','Dec'); + weekday:array[0..6] of string[4]=('Thu','Fri','Sat','Sun','Mon','Tue','Wed'); + month:array[0..11] of string[4]=('Jan','Feb','Mar','Apr','May','Jun','Jul','Aug','Sep','Oct','Nov','Dec'); var y,m,d,h,min,sec,ms:word; t:tdatetime; @@ -562,10 +562,10 @@ begin inttostr(y); end; -function timestring(i:integer):ansistring; +function timestring(i:integer):string; const - weekday:array[0..6] of ansistring =('Thursday','Friday','Saturday','Sunday','Monday','Tuesday','Wednesday'); - month:array[0..11] of ansistring =('January','February','March','April','May','June','July','August','September','October','November','December'); + weekday:array[0..6] of string[10]=('Thursday','Friday','Saturday','Sunday','Monday','Tuesday','Wednesday'); + month:array[0..11] of string[10]=('January','February','March','April','May','June','July','August','September','October','November','December'); var y,m,d,h,min,sec,ms:word; t:tdatetime;