From cf1f8d377549c6cb5ad9475dcd5ec5f48738a8e8 Mon Sep 17 00:00:00 2001 From: Tomas Bzatek Date: Sun, 4 Oct 2009 15:00:25 +0200 Subject: Consolidate plugin IDs This breaks custom-chosen plugins for saved connections (with automatic fallback to 'auto') --- vfs/UVFSCore.pas | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) (limited to 'vfs/UVFSCore.pas') diff --git a/vfs/UVFSCore.pas b/vfs/UVFSCore.pas index 7c85b02..7c98303 100644 --- a/vfs/UVFSCore.pas +++ b/vfs/UVFSCore.pas @@ -76,10 +76,10 @@ type destructor Destroy; override; function VFSVersion: integer; - function VFSName: PChar; - function VFSDescription: PChar; - function VFSAbout: PChar; - function VFSCopyright: PChar; + function ModuleID: string; + function ModuleName: string; + function ModuleAbout: string; + function ModuleCopyright: string; end; @@ -257,40 +257,40 @@ begin else Result := -1; end; -function TVFSPlugin.VFSName: PChar; +function TVFSPlugin.ModuleID: string; var Info: TVFSInfo; begin if @FVFSGetInfo <> nil then begin Info := FVFSGetInfo; - Result := Info.Name; - end else Result := nil; + Result := String(Info.ID); + end else Result := ''; end; -function TVFSPlugin.VFSDescription: PChar; +function TVFSPlugin.ModuleName: string; var Info: TVFSInfo; begin if @FVFSGetInfo <> nil then begin Info := FVFSGetInfo; - Result := Info.Description; - end else Result := nil; + Result := String(Info.Name); + end else Result := ''; end; -function TVFSPlugin.VFSAbout: PChar; +function TVFSPlugin.ModuleAbout: string; var Info: TVFSInfo; begin if @FVFSGetInfo <> nil then begin Info := FVFSGetInfo; - Result := Info.About; - end else Result := nil; + Result := String(Info.About); + end else Result := ''; end; -function TVFSPlugin.VFSCopyright: PChar; +function TVFSPlugin.ModuleCopyright: string; var Info: TVFSInfo; begin if @FVFSGetInfo <> nil then begin Info := FVFSGetInfo; - Result := Info.Copyright; - end else Result := nil; + Result := String(Info.Copyright); + end else Result := ''; end; (********************************************************************************************************************************) @@ -963,7 +963,7 @@ end; (********************************************************************************************************************************) function TVFSEngine.GetPluginID: string; begin - if FSourcePlugin <> nil then Result := FSourcePlugin.VFSName + if FSourcePlugin <> nil then Result := FSourcePlugin.ModuleID else Result := ''; end; -- cgit v1.2.3