mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-17 16:39:15 +02:00
LCL: Fix TBitBTn behavior with Kind=bkClose and ModalResult=mrClose. Issue #21844, patch from Bart Broersma
git-svn-id: trunk@37064 -
This commit is contained in:
parent
6d94b077c7
commit
24cd5e93cd
@ -48,7 +48,9 @@ procedure TCustomBitBtn.Click;
|
||||
var
|
||||
Form : TCustomForm;
|
||||
begin
|
||||
if FKind = bkClose then begin
|
||||
//Contrary to other buttons with ModalResult = mrNone
|
||||
//a TBitBtn must close ParentForm if Kind = bkClose
|
||||
if (FKind = bkClose) and (ModalResult = mrNone) then begin
|
||||
Form := GetParentForm(Self);
|
||||
if Form <> nil then begin
|
||||
Form.Close;
|
||||
|
Loading…
Reference in New Issue
Block a user