| 1 |
unit WdxPlugin; { Content plugins } |
| 2 |
|
| 3 |
interface |
| 4 |
|
| 5 |
uses SysUtils; |
| 6 |
|
| 7 |
const ft_nomorefields=0; |
| 8 |
ft_numeric_32=1; |
| 9 |
ft_numeric_64=2; |
| 10 |
ft_numeric_floating=3; |
| 11 |
ft_date=4; |
| 12 |
ft_time=5; |
| 13 |
ft_boolean=6; |
| 14 |
ft_multiplechoice=7; |
| 15 |
ft_string=8; |
| 16 |
ft_fulltext=9; |
| 17 |
ft_datetime=10; |
| 18 |
ft_stringw=11; |
| 19 |
ft_fulltextw=12; |
| 20 |
|
| 21 |
// for ContentGetValue |
| 22 |
ft_nosuchfield=-1; |
| 23 |
ft_fileerror=-2; |
| 24 |
ft_fieldempty=-3; |
| 25 |
ft_ondemand=-4; |
| 26 |
ft_notsupported=-5; |
| 27 |
ft_setcancel=-6; |
| 28 |
ft_delayed=0; |
| 29 |
|
| 30 |
// for ContentSetValue |
| 31 |
ft_setsuccess=0; // setting of the attribute succeeded |
| 32 |
|
| 33 |
// for ContentGetSupportedFieldFlags |
| 34 |
contflags_edit=1; |
| 35 |
contflags_substsize=2; |
| 36 |
contflags_substdatetime=4; |
| 37 |
contflags_substdate=6; |
| 38 |
contflags_substtime=8; |
| 39 |
contflags_substattributes=10; |
| 40 |
contflags_substattributestr=12; |
| 41 |
contflags_passthrough_size_float=14; |
| 42 |
contflags_substmask=14; |
| 43 |
contflags_fieldedit=16; |
| 44 |
|
| 45 |
// for ContentSendStateInformation |
| 46 |
contst_readnewdir=1; |
| 47 |
contst_refreshpressed=2; |
| 48 |
contst_showhint=4; |
| 49 |
|
| 50 |
setflags_first_attribute=1; // First attribute of this file |
| 51 |
setflags_last_attribute=2; // Last attribute of this file |
| 52 |
setflags_only_date=4; // Only set the date of the datetime value! |
| 53 |
|
| 54 |
|
| 55 |
CONTENT_DELAYIFSLOW=1; // ContentGetValue called in foreground |
| 56 |
CONTENT_PASSTHROUGH=2; // If requested via contflags_passthrough_size_float: The size |
| 57 |
// is passed in as floating value, TC expects correct value |
| 58 |
// from the given units value, and optionally a text string |
| 59 |
|
| 60 |
type tContentDefaultParamStruct=record |
| 61 |
size, |
| 62 |
PluginInterfaceVersionLow, |
| 63 |
PluginInterfaceVersionHi:longint; |
| 64 |
DefaultIniName:array[0..MAX_PATH-1] of char; |
| 65 |
end; |
| 66 |
pContentDefaultParamStruct=^tContentDefaultParamStruct; |
| 67 |
|
| 68 |
type tdateformat=record |
| 69 |
wYear,wMonth,wDay:word; |
| 70 |
end; |
| 71 |
pdateformat=^tdateformat; |
| 72 |
|
| 73 |
type ttimeformat=record |
| 74 |
wHour,wMinute,wSecond:word; |
| 75 |
end; |
| 76 |
ptimeformat=^ttimeformat; |
| 77 |
|
| 78 |
{ Function prototypes: } |
| 79 |
|
| 80 |
(* |
| 81 |
|
| 82 |
procedure ContentGetDetectString(DetectString:pchar;maxlen:integer); {$IFDEF MSWINDOWS}stdcall{$ELSE}cdecl{$ENDIF}; |
| 83 |
function ContentGetSupportedField(FieldIndex:integer;FieldName:pchar; |
| 84 |
Units:pchar;maxlen:integer):integer; {$IFDEF MSWINDOWS}stdcall{$ELSE}cdecl{$ENDIF}; |
| 85 |
function ContentGetValue(FileName:pchar;FieldIndex,UnitIndex:integer; |
| 86 |
FieldValue:pbyte; maxlen,flags:integer):integer; {$IFDEF MSWINDOWS}stdcall{$ELSE}cdecl{$ENDIF}; |
| 87 |
function ContentGetValueW(FileName:pwidechar;FieldIndex,UnitIndex:integer; |
| 88 |
FieldValue:pbyte; maxlen,flags:integer):integer; {$IFDEF MSWINDOWS}stdcall{$ELSE}cdecl{$ENDIF}; |
| 89 |
procedure ContentSetDefaultParams(dps:pContentDefaultParamStruct); {$IFDEF MSWINDOWS}stdcall{$ELSE}cdecl{$ENDIF}; |
| 90 |
procedure ContentPluginUnloading; {$IFDEF MSWINDOWS}stdcall{$ELSE}cdecl{$ENDIF}; |
| 91 |
procedure ContentStopGetValue(FileName:pchar); {$IFDEF MSWINDOWS}stdcall{$ELSE}cdecl{$ENDIF}; |
| 92 |
procedure ContentStopGetValueW(FileName:pwidechar); {$IFDEF MSWINDOWS}stdcall{$ELSE}cdecl{$ENDIF}; |
| 93 |
function ContentGetDefaultSortOrder(FieldIndex:integer):integer; {$IFDEF MSWINDOWS}stdcall{$ELSE}cdecl{$ENDIF}; |
| 94 |
function ContentGetSupportedFieldFlags(FieldIndex:integer):integer; {$IFDEF MSWINDOWS}stdcall{$ELSE}cdecl{$ENDIF}; |
| 95 |
function ContentSetValue(FileName:pchar;FieldIndex,UnitIndex,FieldType:integer; |
| 96 |
FieldValue:pbyte;flags:integer):integer; {$IFDEF MSWINDOWS}stdcall{$ELSE}cdecl{$ENDIF}; |
| 97 |
function ContentSetValueW(FileName:pwidechar;FieldIndex,UnitIndex,FieldType:integer; |
| 98 |
FieldValue:pbyte;flags:integer):integer; {$IFDEF MSWINDOWS}stdcall{$ELSE}cdecl{$ENDIF}; |
| 99 |
procedure ContentSendStateInformation(state:integer;path:pchar); {$IFDEF MSWINDOWS}stdcall{$ELSE}cdecl{$ENDIF}; |
| 100 |
procedure ContentSendStateInformationW(state:integer;path:pwidechar); {$IFDEF MSWINDOWS}stdcall{$ELSE}cdecl{$ENDIF}; |
| 101 |
function ContentEditValue(handle:thandle;FieldIndex,UnitIndex,FieldType:integer; |
| 102 |
FieldValue:pchar;maxlen:integer;flags:integer;langidentifier:pchar):integer; {$IFDEF MSWINDOWS}stdcall{$ELSE}cdecl{$ENDIF}; |
| 103 |
|
| 104 |
*) |
| 105 |
|
| 106 |
implementation |
| 107 |
end. |
| 108 |
|