mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-09-03 10:22:38 +02:00
LCL: overrided TControl.Update in TGraphicControl, so it calls Update() only for TGraphicControl client rect, not whole parent handle.
git-svn-id: trunk@31132 -
This commit is contained in:
parent
58dbddba3e
commit
23249c0b48
@ -2021,7 +2021,7 @@ type
|
||||
procedure Paint; virtual;
|
||||
procedure DoOnChangeBounds; override;
|
||||
procedure DoOnParentHandleDestruction; override;
|
||||
|
||||
procedure Update; override;
|
||||
property OnPaint: TNotifyEvent read FOnPaint write FOnPaint;
|
||||
public
|
||||
constructor Create(AOwner: TComponent); override;
|
||||
|
@ -111,5 +111,17 @@ begin
|
||||
TControlCanvas(Canvas).FreeHandle;
|
||||
end;
|
||||
|
||||
procedure TGraphicControl.Update;
|
||||
var
|
||||
R: TRect;
|
||||
begin
|
||||
if Assigned(Parent) and Parent.HandleAllocated and Parent.Visible then
|
||||
begin
|
||||
R := ClientRect;
|
||||
OffsetRect(R, Left, Top);
|
||||
LCLIntf.InvalidateRect(Parent.Handle, @R, True);
|
||||
end;
|
||||
end;
|
||||
|
||||
// included by controls.pp
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user