mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-21 22:59:27 +02:00
LCL, LazControls: Fix order of calling OnKeyDown in FilterEdit controls. Issue #40601, patch by n7800.
This commit is contained in:
parent
764415b6a0
commit
3692c658ae
@ -714,6 +714,9 @@ procedure TTreeFilterEdit.EditKeyDown(var Key: Word; Shift: TShiftState);
|
|||||||
end;
|
end;
|
||||||
//
|
//
|
||||||
begin
|
begin
|
||||||
|
inherited EditKeyDown(Key, Shift);
|
||||||
|
if Key = 0 then exit;
|
||||||
|
|
||||||
if fFilteredTreeview <> nil then
|
if fFilteredTreeview <> nil then
|
||||||
begin
|
begin
|
||||||
// current node
|
// current node
|
||||||
@ -740,9 +743,6 @@ begin
|
|||||||
Key := 0;
|
Key := 0;
|
||||||
end
|
end
|
||||||
end;
|
end;
|
||||||
|
|
||||||
if Key <> 0 then
|
|
||||||
inherited EditKeyDown(Key, Shift);
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
end.
|
end.
|
||||||
|
@ -1277,6 +1277,9 @@ end;
|
|||||||
|
|
||||||
procedure TCustomControlFilterEdit.EditKeyDown(var Key: Word; Shift: TShiftState);
|
procedure TCustomControlFilterEdit.EditKeyDown(var Key: Word; Shift: TShiftState);
|
||||||
begin
|
begin
|
||||||
|
inherited EditKeyDown(Key, Shift);
|
||||||
|
if Key = 0 then exit;
|
||||||
|
|
||||||
if Shift = [] then
|
if Shift = [] then
|
||||||
case Key of
|
case Key of
|
||||||
VK_RETURN: if ReturnKeyHandled then Key := 0;
|
VK_RETURN: if ReturnKeyHandled then Key := 0;
|
||||||
@ -1293,9 +1296,6 @@ begin
|
|||||||
VK_HOME: begin MoveHome(ssShift in Shift); Key := 0; end;
|
VK_HOME: begin MoveHome(ssShift in Shift); Key := 0; end;
|
||||||
VK_END: begin MoveEnd (ssShift in Shift); Key := 0; end;
|
VK_END: begin MoveEnd (ssShift in Shift); Key := 0; end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
if Key <> 0 then
|
|
||||||
inherited EditKeyDown(Key, Shift);
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TCustomControlFilterEdit.EditChange;
|
procedure TCustomControlFilterEdit.EditChange;
|
||||||
|
Loading…
Reference in New Issue
Block a user