mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-06 03:37:54 +02:00
IDE: fixed searching Pascal files case insensitive
git-svn-id: branches/fixes_1_6@53409 -
This commit is contained in:
parent
f5e60a47fd
commit
230898b8ec
@ -330,7 +330,7 @@ end;
|
||||
function FindFilesCaseInsensitive(const Directory,
|
||||
CaseInsensitiveFilename: string; IgnoreExact: boolean): TStringLists;
|
||||
|
||||
Search case insensitive in Directory for all files
|
||||
Search Pascal case insensitive in Directory for all files
|
||||
named CaseInsensitiveFilename
|
||||
-------------------------------------------------------------------------------}
|
||||
function FindFilesCaseInsensitive(const Directory,
|
||||
@ -346,7 +346,7 @@ begin
|
||||
// check if special file
|
||||
if (FileInfo.Name='.') or (FileInfo.Name='..') or (FileInfo.Name='') then
|
||||
continue;
|
||||
if (CompareFilenamesIgnoreCase(CaseInsensitiveFilename,FileInfo.Name)=0)
|
||||
if (CompareText(CaseInsensitiveFilename,FileInfo.Name)=0) // Pascal insensitibity, not UTF-8, thing about Turkish I
|
||||
and ((not IgnoreExact)
|
||||
or (CompareFilenames(CaseInsensitiveFilename,FileInfo.Name)<>0))
|
||||
then begin
|
||||
|
@ -5454,8 +5454,8 @@ var
|
||||
AFileName:=ExtractFilename(AFileName);
|
||||
if siffCaseSensitive in SearchFlags then
|
||||
Result:=SearchedFilename=AFilename
|
||||
else
|
||||
Result:=CompareFilenamesIgnoreCase(SearchedFilename,AFilename)=0;
|
||||
else // check Pascal case insensitivity (CompareText, do not use CompareFilenamesIgnoreCase, because of Turkish I)
|
||||
Result:=CompareText(SearchedFilename,AFilename)=0;
|
||||
end;
|
||||
|
||||
begin
|
||||
|
Loading…
Reference in New Issue
Block a user