summaryrefslogtreecommitdiff
path: root/vfs
diff options
context:
space:
mode:
authorTomas Bzatek <tbzatek@users.sourceforge.net>2009-10-04 15:00:25 +0200
committerTomas Bzatek <tbzatek@users.sourceforge.net>2009-10-04 15:00:25 +0200
commitcf1f8d377549c6cb5ad9475dcd5ec5f48738a8e8 (patch)
tree8fb096c1760e22f4d9d73c532727455966822636 /vfs
parent3ecc07595f41f436430291fb2299dd540c01f292 (diff)
downloadtuxcmd-cf1f8d377549c6cb5ad9475dcd5ec5f48738a8e8.tar.xz
Consolidate plugin IDs
This breaks custom-chosen plugins for saved connections (with automatic fallback to 'auto')
Diffstat (limited to 'vfs')
-rw-r--r--vfs/UVFSCore.pas34
-rw-r--r--vfs/uVFSprototypes.pas10
2 files changed, 22 insertions, 22 deletions
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;
diff --git a/vfs/uVFSprototypes.pas b/vfs/uVFSprototypes.pas
index 5f0106c..b454769 100644
--- a/vfs/uVFSprototypes.pas
+++ b/vfs/uVFSprototypes.pas
@@ -144,12 +144,12 @@ type
{$ENDIF}
end;
- // This structure contains basic informations about the plugin (Name is used to identify the module in the application)
+ // This structure contains basic informations about the plugin
TVFSInfo = record
- Name: PChar;
- Description: PChar;
- About: PChar;
- Copyright: PChar;
+ ID: PChar; // unique identifier, not shown in GUI
+ Name: PChar; // plugin name, GUI string (UTF-8)
+ About: PChar; // GUI string (UTF-8)
+ Copyright: PChar; // GUI string (UTF-8)
end;
type