mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-16 02:19:16 +02:00
LCL: improved debugging changebounds, removed TCustomLabel AdjustSize in loaded
git-svn-id: trunk@24075 -
This commit is contained in:
parent
3f79d12265
commit
62fc1305ad
@ -56,8 +56,9 @@ begin
|
||||
if (Parent=nil) and (not (cfAutoSizeNeeded in FControlFlags))
|
||||
and (Self is TCustomForm) then begin
|
||||
DebugLn(['TControl.Adjustsize ',DbgSName(Self)]);
|
||||
if Name='SearchResultsView' then begin
|
||||
debugln(GetStackTrace(true));
|
||||
if Name='SearchResults' then begin
|
||||
//debugln(GetStackTrace(true));
|
||||
DebugLn(['TControl.Adjustsize AAA1']);
|
||||
end;
|
||||
end;
|
||||
{$ENDIF}
|
||||
@ -365,7 +366,7 @@ begin
|
||||
PosChanged := (FLeft <> ALeft) or (FTop <> ATop);
|
||||
if (not SizeChanged) and (not PosChanged) then Exit;
|
||||
|
||||
//DebugLn('TControl.ChangeBounds A ',Name,':',ClassName);
|
||||
//DebugLn('TControl.ChangeBounds A ',DbgSName(Self),' Old=',dbgs(BoundsRect),' New=',dbgs(NewBounds));
|
||||
if (not (csLoading in ComponentState))
|
||||
and (not (Self is TWinControl)) then
|
||||
InvalidateControl(IsControlVisible, False, true);
|
||||
@ -2392,7 +2393,9 @@ end;
|
||||
procedure TControl.DoAutoSize;
|
||||
begin
|
||||
//Handled by TWinControl, or other descendants
|
||||
{$IFNDEF OldAutoSize}
|
||||
Exclude(FControlFlags,cfAutoSizeNeeded);
|
||||
{$ENDIF}
|
||||
end;
|
||||
|
||||
{------------------------------------------------------------------------------
|
||||
|
@ -84,6 +84,7 @@ var
|
||||
NewWidth, NewHeight: integer;
|
||||
CurAnchors: TAnchors;
|
||||
begin
|
||||
inherited DoAutoSize;
|
||||
//debugln('TCustomLabel.DoAutoSize ',DbgSName(Self),' AutoSizing=',dbgs(AutoSizing),' AutoSize=',dbgs(AutoSize),' Parent=',DbgSName(Parent),' csLoading=',dbgs(csLoading in ComponentState),' Parnet.HandleAllocated=',dbgs((Parent<>nil) and (Parent.HandleAllocated)));
|
||||
if OptimalFill and (not AutoSize) then
|
||||
begin
|
||||
@ -298,7 +299,9 @@ end;
|
||||
procedure TCustomLabel.Loaded;
|
||||
begin
|
||||
inherited Loaded;
|
||||
{$IFNDEF OldAutoSize}
|
||||
AdjustSize;
|
||||
{$ENDIF}
|
||||
end;
|
||||
|
||||
procedure TCustomLabel.UpdateSize;
|
||||
|
Loading…
Reference in New Issue
Block a user