mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-06 05:38:25 +02:00
lcl: avoid reseting value when changing edit state. Issue #21258
git-svn-id: trunk@35307 -
This commit is contained in:
parent
e484fc0ae2
commit
77b7c33e02
@ -137,11 +137,14 @@ end;
|
||||
|
||||
procedure TDBCheckBox.DoOnChange;
|
||||
begin
|
||||
//avoid reseting value when state changes
|
||||
FDataLink.OnDataChange := nil;
|
||||
if FDatalink.Edit then begin
|
||||
FDatalink.Modified;
|
||||
FDataLink.UpdateRecord;
|
||||
end else
|
||||
State:=GetFieldCheckState;
|
||||
FDataLink.OnDataChange := @DataChange;
|
||||
inherited DoOnChange;
|
||||
end;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user