mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-19 10:49:44 +02:00
IDE: fixed SearchInStringListI
git-svn-id: branches/fixes_1_6@53406 -
This commit is contained in:
parent
95641a8723
commit
0adf62bd62
@ -256,7 +256,7 @@ procedure CheckList(List: TList; TestListNil, TestDoubles, TestNils: boolean);
|
||||
procedure CheckList(List: TFPList; TestListNil, TestDoubles, TestNils: boolean);
|
||||
procedure CheckEmptyListCut(List1, List2: TList);
|
||||
procedure RemoveDoubles(List: TStrings);
|
||||
function UTF8SearchInStringList(List: TStrings; const s: string): integer;
|
||||
function SearchInStringListI(List: TStrings; const s: string): integer; // search ASCII case insensitive, not UTF-8
|
||||
procedure ReverseList(List: TList);
|
||||
procedure ReverseList(List: TFPList);
|
||||
procedure FreeListObjects(List: TList; FreeList: boolean);
|
||||
@ -1280,14 +1280,11 @@ begin
|
||||
end;
|
||||
end;
|
||||
|
||||
{-------------------------------------------------------------------------------
|
||||
function UTF8SearchInStringList(List: TStrings; const s: string): integer;
|
||||
-------------------------------------------------------------------------------}
|
||||
function UTF8SearchInStringList(List: TStrings; const s: string): integer;
|
||||
function SearchInStringListI(List: TStrings; const s: string): integer;
|
||||
begin
|
||||
if List=nil then exit(-1);
|
||||
Result:=List.Count-1;
|
||||
while (Result>=0) and (UTF8CompareText(List[Result],s)<>0) do dec(Result);
|
||||
while (Result>=0) and (CompareText(List[Result],s)<>0) do dec(Result);
|
||||
end;
|
||||
|
||||
{-------------------------------------------------------------------------------
|
||||
|
BIN
ide/lazarus.res
BIN
ide/lazarus.res
Binary file not shown.
Loading…
Reference in New Issue
Block a user