TCustomAbstractGroupedEdit: assign PopupMenu also to FBuddy (if this does not have a separate PopupMenu by itself).

Resolves part of #38098.
This commit is contained in:
Bart 2023-11-06 13:22:24 +01:00
parent 8fa26c3c71
commit 54e9cc9171

View File

@ -905,8 +905,14 @@ begin
end;
procedure TCustomAbstractGroupedEdit.SetPopupMenu(AValue: TPopupMenu);
var
OldPopupMenu: TPopupMenu;
begin
OldPopupMenu := FEdit.PopupMenu;
FEdit.PopupMenu := AValue;
//users can assign a different popupmenu to the buddy if so desired, if that is the case, don't touch it
if (FBuddy.PopupMenu = OldPopupMenu) then
FBuddy.PopupMenu := AValue;
end;
procedure TCustomAbstractGroupedEdit.RealSetText(const AValue: TCaption);