mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-25 13:39:11 +02:00
LazControls: Revert the earlier change in TCustomCheckBoxThemed, issue #39425.
This commit is contained in:
parent
232ed8531c
commit
51cdd4d4c4
@ -467,12 +467,14 @@ begin
|
|||||||
if [csLoading, csDestroying, csDesigning]*ComponentState = [] then begin
|
if [csLoading, csDestroying, csDesigning]*ComponentState = [] then begin
|
||||||
if Assigned(OnEditingDone) then OnEditingDone(self);
|
if Assigned(OnEditingDone) then OnEditingDone(self);
|
||||||
if Assigned(OnChange) then OnChange(self);
|
if Assigned(OnChange) then OnChange(self);
|
||||||
{ Execute only when Action.Checked is changed }
|
// Execute only when Action.Checked is changed
|
||||||
if not CheckFromAction then begin
|
if not CheckFromAction then begin
|
||||||
if Assigned(OnClick) and not Assigned(Action) then
|
// Call OnClick only if its handler differs from the Action's handler.
|
||||||
OnClick(self);
|
if Assigned(OnClick) and
|
||||||
if (Action is TCustomAction) and
|
not (Assigned(Action) and SameMethod(TMethod(Action.OnExecute),TMethod(OnClick)))
|
||||||
(TCustomAction(Action).Checked <> (AValue = cbChecked))
|
then OnClick(self);
|
||||||
|
// Then the action
|
||||||
|
if (Action is TCustomAction) and (TCustomAction(Action).Checked<>(AValue=cbChecked))
|
||||||
then ActionLink.Execute(self);
|
then ActionLink.Execute(self);
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
Loading…
Reference in New Issue
Block a user