Cocoa/ScrollView: fix the issue of missing child control callback clear in lclClearCallback()

This commit is contained in:
rich2014 2024-12-19 00:34:45 +08:00
parent 950d962e1d
commit d9ba51bbe9

View File

@ -661,6 +661,8 @@ end;
procedure TCocoaManualScrollView.lclClearCallback;
begin
callback := nil;
if Assigned(self.documentView) then
self.documentView.lclClearCallback;
end;
function TCocoaManualScrollView.lclContentView: NSView;
@ -1121,6 +1123,8 @@ end;
procedure TCocoaScrollView.lclClearCallback;
begin
callback := nil;
if Assigned(self.documentView) then
self.documentView.lclClearCallback;
end;
{ TCocoaScrollBar }