mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-07 21:18:01 +02:00
SynEdit, FpDebug, LazUtils, IdeIntf: Remove UTF8CompareLatinTextFast calls.
This commit is contained in:
parent
bc201de1ed
commit
08c0f4865d
@ -43,8 +43,10 @@ unit FpDbgDwarfDataClasses;
|
||||
interface
|
||||
|
||||
uses
|
||||
Classes, Types, SysUtils, contnrs, Math, Maps, LazClasses, LazFileUtils,
|
||||
{$ifdef FORCE_LAZLOGGER_DUMMY} LazLoggerDummy {$else} LazLoggerBase {$endif}, LazUTF8, lazCollections,
|
||||
Classes, Types, SysUtils, Contnrs, Math,
|
||||
// LazUtils
|
||||
Maps, LazClasses, LazFileUtils, LazUTF8, LazCollections,
|
||||
{$ifdef FORCE_LAZLOGGER_DUMMY} LazLoggerDummy {$else} LazLoggerBase {$endif},
|
||||
// FpDebug
|
||||
FpDbgUtil, FpDbgInfo, FpDbgDwarfConst, FpDbgCommon, FpDbgDwarfCFI,
|
||||
FpDbgLoader, FpImgReaderBase, FpdMemoryTools, FpErrorMessages, DbgIntfBaseTypes;
|
||||
@ -5194,7 +5196,7 @@ function TDwarfCompilationUnit.GetLineAddressMap(const AFileName: String): PDWar
|
||||
if Result <> -1 then Exit;
|
||||
|
||||
for Result := 0 to FLineNumberMap.Count - 1 do
|
||||
if UTF8CompareLatinTextFast(Name, ExtractFileName(FLineNumberMap[Result])) = 0 then
|
||||
if AnsiCompareText(Name, ExtractFileName(FLineNumberMap[Result])) = 0 then
|
||||
Exit;
|
||||
Result := -1;
|
||||
end;
|
||||
|
@ -18,7 +18,7 @@ uses
|
||||
// LCL
|
||||
StdCtrls, ImgList, Graphics,
|
||||
// LazUtils
|
||||
LazUTF8, LazFileUtils;
|
||||
LazFileUtils;
|
||||
|
||||
type
|
||||
TCmpStrType = (
|
||||
@ -54,7 +54,7 @@ begin
|
||||
for i:=0 to List.Count-1 do begin
|
||||
case Cmp of
|
||||
cstCaseSensitive: if List[i]=s then exit(i);
|
||||
cstCaseInsensitive: if UTF8CompareLatinTextFast(List[i],s)=0 then exit(i);
|
||||
cstCaseInsensitive: if AnsiCompareText(List[i],s)=0 then exit(i);
|
||||
cstFilename: if CompareFilenames(List[i],s)=0 then exit(i);
|
||||
end;
|
||||
end;
|
||||
|
@ -6,7 +6,7 @@
|
||||
for details about the license.
|
||||
*****************************************************************************
|
||||
}
|
||||
unit lazCollections;
|
||||
unit LazCollections;
|
||||
|
||||
{$mode objfpc}{$H+}
|
||||
{$ModeSwitch advancedrecords}
|
||||
|
@ -384,7 +384,7 @@ begin
|
||||
if CaseSensitive then
|
||||
Result := CompareStr(FnExt, Ext)
|
||||
else
|
||||
Result := UTF8CompareLatinTextFast(FnExt, Ext);
|
||||
Result := CompareText(FnExt, Ext);
|
||||
if Result < 0 then
|
||||
Result := -1
|
||||
else if Result > 0 then
|
||||
|
@ -24,9 +24,9 @@ unit pocheckermain;
|
||||
interface
|
||||
|
||||
uses
|
||||
Classes, SysUtils, FileUtil, LazFileUtils, Forms, Controls, Graphics, Dialogs,
|
||||
StdCtrls, CheckLst, Buttons, ExtCtrls, ComCtrls, Types,
|
||||
LCLType, LazUTF8,
|
||||
Classes, SysUtils, Types,
|
||||
FileUtil, LazFileUtils,
|
||||
Forms, Controls, Graphics, Dialogs, StdCtrls, CheckLst, Buttons, ExtCtrls, ComCtrls, LCLType,
|
||||
{$IFDEF POCHECKERSTANDALONE}
|
||||
LCLTranslator,
|
||||
{$ELSE}
|
||||
@ -566,7 +566,7 @@ end;
|
||||
|
||||
function ListSortFunc(List: TStringList; Index1, Index2: Integer): Integer;
|
||||
begin
|
||||
Result := UTF8CompareLatinTextFast(List.Strings[Index1], List.Strings[Index2]);
|
||||
Result := CompareText(List.Strings[Index1], List.Strings[Index2]);
|
||||
end;
|
||||
|
||||
function TPoCheckerForm.LangFilterIndexToLangID(Index: Integer): TLangID;
|
||||
|
@ -1158,16 +1158,15 @@ begin
|
||||
end else begin
|
||||
if FCaseSensitive then begin
|
||||
for i := 0 to Pred(ItemList.Count) do
|
||||
if 0 = CompareStr(fCurrentString,
|
||||
Copy(ItemList[i], 1, Length(fCurrentString)))
|
||||
if 0 = CompareStr(fCurrentString, Copy(ItemList[i], 1, Length(fCurrentString)))
|
||||
then begin
|
||||
Position := i;
|
||||
break;
|
||||
end;
|
||||
end else begin
|
||||
for i := 0 to Pred(ItemList.Count) do
|
||||
if 0 = UTF8CompareLatinTextFast(fCurrentString,
|
||||
Copy(ItemList[i], 1, Length(fCurrentString)))
|
||||
if 0 = AnsiCompareText(fCurrentString,
|
||||
Copy(ItemList[i], 1, Length(fCurrentString)))
|
||||
then begin
|
||||
Position := i;
|
||||
break;
|
||||
|
@ -275,9 +275,9 @@ begin
|
||||
end else begin
|
||||
while i > -1 do begin
|
||||
s := fCompletions[i];
|
||||
if UTF8CompareLatinTextFast(s, AToken) = 0 then
|
||||
if AnsiCompareText(s, AToken) = 0 then
|
||||
break
|
||||
else if UTF8CompareLatinTextFast(Copy(s, 1, Len), AToken) = 0 then begin
|
||||
else if AnsiCompareText(Copy(s, 1, Len), AToken) = 0 then begin
|
||||
Inc(NumMaybe);
|
||||
IdxMaybe := i;
|
||||
end;
|
||||
|
Loading…
Reference in New Issue
Block a user