mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-11 20:36:09 +02:00
LCL: TTreeView: mousedown: fixed select on click on state icon
git-svn-id: branches/fixes_1_4@47896 -
This commit is contained in:
parent
e915cb95c0
commit
a235aa0eb1
@ -19,7 +19,7 @@ unit LazUTF8;
|
||||
{$mode objfpc}{$H+}{$inline on}
|
||||
|
||||
{$IF defined(EnableUTF8RTL) and (FPC_FULLVERSION<20701)}
|
||||
{$error UTF8 RTl requires fpc 2.7.1+}
|
||||
{$error UTF8 in RTL requires fpc 2.7.1+}
|
||||
{$ENDIF}
|
||||
|
||||
interface
|
||||
|
@ -354,8 +354,36 @@ begin
|
||||
if (GetLocaleInfoA(aLocaleID, aLCType, Buf, sizeof(buf)) > 0)
|
||||
and (ord(Buf[0])<128) then
|
||||
Result := Buf[0]
|
||||
else
|
||||
else begin
|
||||
Result := Def;
|
||||
case Buf[0] of
|
||||
#$C2:
|
||||
case Buf[1] of
|
||||
#$A0: Result:=' '; // non breakable space
|
||||
#$B7: Result:='.'; // middle stop
|
||||
end;
|
||||
#$CB:
|
||||
if Buf[1]=#$99 then Result:=''''; // dot above, italian handwriting
|
||||
#$D9:
|
||||
case Buf[1] of
|
||||
#$AB: Result:=','; // arabic decimal separator, persian thousand separator
|
||||
#$AC: Result:=''''; // arabic thousand separator
|
||||
end;
|
||||
#$E2:
|
||||
case Buf[1] of
|
||||
#$80:
|
||||
case Buf[2] of
|
||||
#$82, // long space
|
||||
#$83, // long space
|
||||
#$89, // thin space
|
||||
#$AF: // narrow non breakable space
|
||||
Result := ' ';
|
||||
#$94: Result := '-'; // persian decimal mark
|
||||
end;
|
||||
#$8E: if Buf[2]=#$96 then Result := ''''; // codepoint 9110 decimal separator
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure GetFormatSettingsUTF8(LCID: Integer; var aFormatSettings: TFormatSettings);
|
||||
|
@ -5194,7 +5194,7 @@ begin
|
||||
// mousedown occured on expand sign -> expand/collapse
|
||||
CursorNode.Expanded:=not CursorNode.Expanded;
|
||||
end
|
||||
else if LogicalX >= CursorNode.DisplayIconLeft then
|
||||
else if LogicalX >= CursorNode.DisplayStateIconLeft then
|
||||
begin
|
||||
// mousedown occured in text or icon
|
||||
// -> select node and begin drag operation
|
||||
|
Loading…
Reference in New Issue
Block a user