Rev 68 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 68 | Rev 69 | ||
---|---|---|---|
Line 28... | Line 28... | ||
28 | SetLength(Result,Len) |
28 | SetLength(Result,Len) |
29 | else |
29 | else |
30 | RaiseLastOSError; |
30 | RaiseLastOSError; |
31 | end; |
31 | end; |
32 | 32 | ||
33 | function IdentificationStringW(lpIdentifier: LPWSTR; cchSize: DWORD): UD2_STATUSCODE; cdecl; |
33 | function IdentificationStringW(lpIdentifier: LPWSTR; cchSize: DWORD): UD2_STATUS; cdecl; |
34 | var |
34 | var |
35 | stIdentifier: WideString; |
35 | stIdentifier: WideString; |
36 | begin |
36 | begin |
37 | stIdentifier := GetComputerName; |
37 | stIdentifier := GetComputerName; |
38 | result := WritePascalStringToPointerW(lpIdentifier, cchSize, stIdentifier); |
38 | result := UD2_WritePascalStringToPointerW(lpIdentifier, cchSize, stIdentifier); |
39 | end; |
39 | end; |
40 | 40 | ||
41 | function PluginNameW(lpPluginName: LPWSTR; cchSize: DWORD; wLangID: LANGID): UD2_STATUSCODE; cdecl; |
41 | function PluginNameW(lpPluginName: LPWSTR; cchSize: DWORD; wLangID: LANGID): UD2_STATUS; cdecl; |
42 | var |
42 | var |
43 | stPluginName: WideString; |
43 | stPluginName: WideString; |
44 | primaryLangID: Byte; |
44 | primaryLangID: Byte; |
45 | begin |
45 | begin |
46 | primaryLangID := wLangID and $00FF; |
46 | primaryLangID := wLangID and $00FF; |
47 | if primaryLangID = LANG_GERMAN then |
47 | if primaryLangID = LANG_GERMAN then |
48 | stPluginName := 'Computer-Name' |
48 | stPluginName := 'Computer-Name' |
49 | else |
49 | else |
50 | stPluginName := 'Computer name'; |
50 | stPluginName := 'Computer name'; |
51 | result := WritePascalStringToPointerW(lpPluginName, cchSize, stPluginName); |
51 | result := UD2_WritePascalStringToPointerW(lpPluginName, cchSize, stPluginName); |
52 | end; |
52 | end; |
53 | 53 | ||
54 | function PluginVendorW(lpPluginVendor: LPWSTR; cchSize: DWORD; wLangID: LANGID): UD2_STATUSCODE; cdecl; |
54 | function PluginVendorW(lpPluginVendor: LPWSTR; cchSize: DWORD; wLangID: LANGID): UD2_STATUS; cdecl; |
55 | begin |
55 | begin |
56 | result := WritePascalStringToPointerW(lpPluginVendor, cchSize, 'ViaThinkSoft'); |
56 | result := UD2_WritePascalStringToPointerW(lpPluginVendor, cchSize, 'ViaThinkSoft'); |
57 | end; |
57 | end; |
58 | 58 | ||
59 | function PluginVersionW(lpPluginVersion: LPWSTR; cchSize: DWORD; wLangID: LANGID): UD2_STATUSCODE; cdecl; |
59 | function PluginVersionW(lpPluginVersion: LPWSTR; cchSize: DWORD; wLangID: LANGID): UD2_STATUS; cdecl; |
60 | begin |
60 | begin |
61 | result := WritePascalStringToPointerW(lpPluginVersion, cchSize, '1.0'); |
61 | result := UD2_WritePascalStringToPointerW(lpPluginVersion, cchSize, '1.0'); |
62 | end; |
62 | end; |
63 | 63 | ||
64 | function IdentificationMethodNameW(lpIdentificationMethodName: LPWSTR; cchSize: DWORD): UD2_STATUSCODE; cdecl; |
64 | function IdentificationMethodNameW(lpIdentificationMethodName: LPWSTR; cchSize: DWORD): UD2_STATUS; cdecl; |
65 | var |
65 | var |
66 | stIdentificationMethodName: WideString; |
66 | stIdentificationMethodName: WideString; |
67 | begin |
67 | begin |
68 | stIdentificationMethodName := 'ComputerName'; |
68 | stIdentificationMethodName := 'ComputerName'; |
69 | result := WritePascalStringToPointerW(lpIdentificationMethodName, cchSize, stIdentificationMethodName); |
69 | result := UD2_WritePascalStringToPointerW(lpIdentificationMethodName, cchSize, stIdentificationMethodName); |
70 | end; |
70 | end; |
71 | 71 | ||
72 | function CheckLicense(lpReserved: LPVOID): UD2_STATUSCODE; cdecl; |
72 | function CheckLicense(lpReserved: LPVOID): UD2_STATUS; cdecl; |
73 | begin |
73 | begin |
74 | result := UD2_STATUS_OK; |
74 | result := UD2_STATUS_OK_LICENSED; |
75 | end; |
75 | end; |
76 | 76 | ||
77 | exports |
77 | exports |
78 | PluginInterfaceID name mnPluginInterfaceID, |
78 | PluginInterfaceID name mnPluginInterfaceID, |
79 | PluginIdentifier name mnPluginIdentifier, |
79 | PluginIdentifier name mnPluginIdentifier, |