Rev 98 | Rev 100 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 98 | Rev 99 | ||
---|---|---|---|
Line 1... | Line 1... | ||
1 | unit RecBinUnitLowLvl; |
1 | unit RecBinUnitLowLvl; |
2 | 2 | ||
3 | // TODO: Gain more information about drive '@' / Homedrive / Netdrive? Win2000 source |
3 | // TODO: Gain more information about drive '@' / Homedrive / Netdrive? |
4 | // + überall verwenden |
- | |
5 | 4 | ||
6 | interface |
5 | interface |
7 | 6 | ||
8 | uses |
7 | uses |
9 | Windows; |
8 | Windows; |
10 | 9 | ||
11 | type |
10 | type |
12 | PRbInfoHeader = ^TRbInfoHeader; |
11 | PRbInfoHeader = ^TRbInfoHeader; |
13 | TRbInfoHeader = record |
12 | TRbInfoHeader = packed record |
14 | format: DWORD; // Unsure if this is just a version field or some unknown flags...! |
13 | format: DWORD; // Version of the info file |
15 | // Win95 (without IE4): 00 00 00 00 |
14 | // Win95 (without IE4): 00 00 00 00 |
16 | // Win95 (with IE4): 04 00 00 00 |
15 | // Win NT4: 02 00 00 00 (Win96/Cairo?) |
17 | // Win NT4: 02 00 00 00 |
16 | // Win95 (with IE4), 98: 04 00 00 00 |
18 | // Win Me, 2000, XP: 05 00 00 00 |
17 | // Win Me, 2000, XP: 05 00 00 00 (NT4+IE4, NT5?) |
19 | totalEntries: DWORD; // Only Win95 (without IE4) and Win NT4, unknown purpose for other OS versions |
18 | totalEntries: DWORD; // Only Win95 (without IE4) and Win NT4, other OS versions might use the registry instead |
20 | nextPossibleID: DWORD; // Only Win95 (without IE4) and Win NT4, unknown purpose for other OS versions |
19 | nextPossibleID: DWORD; // Only Win95 (without IE4) and Win NT4, other OS versions might use the registry instead |
21 | recordLength: DWORD; // 0x181 = INFO structure (without Unicode) |
20 | recordLength: DWORD; // 0x181 = ANSI records |
22 | // 0x320 = INFO2 structure (with Unicode) |
21 | // 0x320 = Unicode records |
23 | totalSize: DWORD; // sum of all "originalSize" values; |
22 | totalSize: DWORD; // sum of all "originalSize" values; |
24 | // Only Win95 (without IE4) and Win NT4, unknown purpose for other OS versions |
23 | // Only Win95 (without IE4) and Win NT4, other OS versions might use the registry instead |
25 | end; |
24 | end; |
26 | 25 | ||
27 | type |
26 | type |
28 | // Windows 95: INFO file with TRbInfoRecordA; Folder deletion NOT possible |
27 | // Windows 95: INFO file with TRbInfoRecordA; Folder deletion NOT possible |
29 | // Windows 95 +IE4: INFO2 file with TRbInfoRecordA; Folder deletion possible |
28 | // Windows 95 +IE4: INFO2 file with TRbInfoRecordA; Folder deletion possible |
30 | PRbInfoRecordA = ^TRbInfoRecordA; |
29 | PRbInfoRecordA = ^TRbInfoRecordA; |
31 | TRbInfoRecordA = record |
30 | TRbInfoRecordA = packed record |
32 | sourceAnsi: array[0..MAX_PATH-3] of AnsiChar; // 258 elements |
31 | sourceAnsi: array[0..MAX_PATH-1] of AnsiChar; // 260 characters (including NUL terminator) |
33 | recordNumber: DWORD; |
32 | recordNumber: DWORD; |
34 | sourceDrive: DWORD; |
33 | sourceDrive: DWORD; // 0=A, 1=B, 2=C, ... |
35 | deletionTime: FILETIME; |
34 | deletionTime: FILETIME; |
36 | originalSize: DWORD; // Size occupied on disk. Not the actual file size. |
35 | originalSize: DWORD; // Size occupied on disk. Not the actual file size. |
37 | // INFO2, for folders: The whole folder size with contents |
36 | // INFO2, for folders: The whole folder size with contents |
38 | end; |
37 | end; |
39 | 38 | ||
40 | type |
39 | type |
41 | // Windows NT4: INFO file with TRbInfoRecordW; Folder deletion possible |
40 | // Windows NT4: INFO file with TRbInfoRecordW; Folder deletion possible |
42 | // Windows 2000+: INFO2 file with TRbInfoRecordW; Folder deletion possible |
41 | // Windows 2000+: INFO2 file with TRbInfoRecordW; Folder deletion possible |
43 | PRbInfoRecordW = ^TRbInfoRecordW; |
42 | PRbInfoRecordW = ^TRbInfoRecordW; |
44 | TRbInfoRecordW = record |
43 | TRbInfoRecordW = packed record |
45 | sourceAnsi: array[0..MAX_PATH-3] of AnsiChar; // 258 elements |
44 | sourceAnsi: array[0..MAX_PATH-1] of AnsiChar; // 260 characters (including NUL terminator) |
46 | recordNumber: DWORD; |
45 | recordNumber: DWORD; |
47 | sourceDrive: DWORD; |
46 | sourceDrive: DWORD; // 0=A, 1=B, 2=C, ... |
48 | deletionTime: FILETIME; |
47 | deletionTime: FILETIME; |
49 | originalSize: DWORD; |
48 | originalSize: DWORD; |
50 | sourceUnicode: array[0..MAX_PATH-3] of WideChar; // 258 elements |
49 | sourceUnicode: array[0..MAX_PATH-1] of WideChar; // 260 characters (including NUL terminator) |
51 | unknown1: DWORD; // Dummy? |
- | |
52 | end; |
50 | end; |
53 | 51 | ||
54 | type |
52 | type |
55 | // Introduced in Windows Vista |
53 | // Introduced in Windows Vista |
56 | PRbVistaRecord1 = ^TRbVistaRecord1; |
54 | PRbVistaRecord1 = ^TRbVistaRecord1; |
57 | TRbVistaRecord1 = record |
55 | TRbVistaRecord1 = packed record |
58 | version: int64; // Always 01 00 00 00 00 00 00 00 |
56 | version: int64; // Always 01 00 00 00 00 00 00 00 |
59 | originalSize: int64; |
57 | originalSize: int64; |
60 | deletionTime: FILETIME; |
58 | deletionTime: FILETIME; |
61 | sourceUnicode: array[0..MAX_PATH-1] of WideChar; |
59 | sourceUnicode: array[0..MAX_PATH-1] of WideChar; |
62 | end; |
60 | end; |
63 | 61 | ||
64 | type |
62 | type |
65 | // Introduced somewhere in a Win10 release |
63 | // Introduced somewhere in a Win10 release |
66 | PRbVistaRecord2Head = ^TRbVistaRecord2Head; |
64 | PRbVistaRecord2Head = ^TRbVistaRecord2Head; |
67 | TRbVistaRecord2Head = record |
65 | TRbVistaRecord2Head = packed record |
68 | version: int64; // Always 02 00 00 00 00 00 00 00 |
66 | version: int64; // Always 02 00 00 00 00 00 00 00 |
69 | originalSize: int64; |
67 | originalSize: int64; |
70 | deletionTime: FILETIME; |
68 | deletionTime: FILETIME; |
71 | (* sourceUnicode: BSTR; *) |
69 | (* sourceUnicode: BSTR; *) |
72 | sourceCountChars: DWORD; // including NUL |
70 | sourceCountChars: DWORD; // including NUL |
Line 75... | Line 73... | ||
75 | 73 | ||
76 | type |
74 | type |
77 | // Windows 95 + Windows NT 4 |
75 | // Windows 95 + Windows NT 4 |
78 | // HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\explorer\BitBucket: PurgeInfo (Binary) |
76 | // HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\explorer\BitBucket: PurgeInfo (Binary) |
79 | PRbWin95PurgeInfo = ^TRbWin95PurgeInfo; |
77 | PRbWin95PurgeInfo = ^TRbWin95PurgeInfo; |
80 | TRbWin95PurgeInfo = record |
78 | TRbWin95PurgeInfo = packed record |
81 | cbSize: DWORD; |
79 | cbSize: DWORD; |
82 | bGlobalSettings: BOOL; |
80 | bGlobalSettings: BOOL; |
83 | percentDrive: array['A'..'Z'] of WORD; // 0x00..0x64 = 0%..100% |
81 | percentDrive: array['A'..'Z'] of WORD; // 0x00..0x64 = 0%..100% |
84 | percentHomedrive: WORD; |
82 | percentHomedrive: WORD; |
85 | percentGlobal: WORD; |
83 | percentGlobal: WORD; |