* string -> shortstring

This commit is contained in:
Michael VAN CANNEYT 2023-01-06 11:02:29 +01:00 committed by Michaël Van Canneyt
parent 9d6a495c02
commit 216c55871a
2 changed files with 8 additions and 8 deletions

View File

@ -144,9 +144,9 @@ end;
{All kinds of paths are attempted to be translated, except the unusal } {All kinds of paths are attempted to be translated, except the unusal }
{dos construct: a relative path on a certain drive like : C:xxx\yyy} {dos construct: a relative path on a certain drive like : C:xxx\yyy}
function TranslatePathToMac (const path: string; mpw: Boolean): string; function TranslatePathToMac (const path: shortstring; mpw: Boolean): Shortstring;
function GetVolumeIdentifier: string; function GetVolumeIdentifier: Shortstring;
var var
s: Str255; s: Str255;
@ -269,7 +269,7 @@ end;
end; end;
{Concats the relative or full path path1 and the relative path path2.} {Concats the relative or full path path1 and the relative path path2.}
function ConcatMacPath (path1, path2: string): string; function ConcatMacPath (path1, path2: Shortstring): Shortstring;
begin begin
if Pos(':', path1) = 0 then {its partial} if Pos(':', path1) = 0 then {its partial}
@ -295,7 +295,7 @@ end;
end; end;
end; end;
function IsMacFullPath (const path: string): Boolean; function IsMacFullPath (const path: Shortstring): Boolean;
begin begin
if Pos(':', path) = 0 then {its partial} if Pos(':', path) = 0 then {its partial}
@ -391,7 +391,7 @@ begin
FSpGetFullPath := res; FSpGetFullPath := res;
end; end;
function PathArgToFSSpec(s: string; var spec: FSSpec): Integer; function PathArgToFSSpec(s: Shortstring; var spec: FSSpec): Integer;
var var
err: OSErr; err: OSErr;
begin begin
@ -406,7 +406,7 @@ begin
PathArgToFSSpec := 3; {Empty paths are invalid paths} PathArgToFSSpec := 3; {Empty paths are invalid paths}
end; end;
function PathArgToFullPath(s: string; var fullpath: RawByteString): Integer; function PathArgToFullPath(s: Shortstring; var fullpath: RawByteString): Integer;
var var
err: OSErr; err: OSErr;
@ -424,7 +424,7 @@ begin
PathArgToFullPath:=res; PathArgToFullPath:=res;
end; end;
function GetVolumeName(vRefNum: Integer; var volName: String): OSErr; function GetVolumeName(vRefNum: Integer; var volName: ShortString): OSErr;
var var
pb: HParamBlockRec; pb: HParamBlockRec;

View File

@ -230,7 +230,7 @@ begin
end; end;
{ argument number l } { argument number l }
function paramstr(l : longint) : string; function paramstr(l : longint) : shortstring;
begin begin
if (l>=0) and (l+1<=argc) then if (l>=0) and (l+1<=argc) then
paramstr:=strpas(argv[l]) paramstr:=strpas(argv[l])