Этот фильтр находит директории. Причём директории, в которых отсутствуют атрибуты "Compressed" и "Encrypted". Почему?
Для чистоты эксперимента сделал тестовый скрипт. Но фаровский Find File ведёт себя аналогично.
local item = {
LastWriteTime=0; LastAccessTime=0; CreationTime=0; ChangeTime=0;
FileSize=0; AllocationSize=0;
FileName="abc";
FileAttributes="d"; Flags=0;
}
local filter = far.CreateFileFilter(1, "FFT_FINDFILE")
--local filter = assert(far.CreateFileFilter(1, "FFT_CUSTOM"))
if filter:OpenFiltersMenu() then
local attr = far.InputBox(nil,"Attributes","Attributes:")
if attr then
item.FileAttributes = attr
far.Message(filter:IsFileInFilter(item))
end
else
far.Message("filter cancelled")
end
1. **`FileAttributes`** is a string of concatenated attribute
letters (see below). If a letter representing some attribute
is present in the string, that means the corresponding attribute
is set, otherwise it is not.
a - archive
c - compressed
d - directory
e - reparse point
h - hidden
o - offline
p - sparse file
r - read only
s - system file
t - temporary