LCL: invalidatepreferredsize for self in CreateWnd

git-svn-id: trunk@26869 -
This commit is contained in:
mattias 2010-07-28 10:45:19 +00:00
parent 3d89257182
commit f62c482f58

View File

@ -6820,11 +6820,11 @@ begin
and (not (wcfClientRectNeedsUpdate in FWinControlFlags)) then and (not (wcfClientRectNeedsUpdate in FWinControlFlags)) then
exit; exit;
{ $IFDEF VerboseAllAutoSize} {$IFDEF VerboseAllAutoSize}
DebugLn(['TWinControl.WMWindowPosChanged CHANGED BY INTF ',dbgsname(Self),' Message=',NewLeft,',',NewTop,',',NewWidth,'x',NewHeight, DebugLn(['TWinControl.WMWindowPosChanged CHANGED BY INTF ',dbgsname(Self),' Message=',NewLeft,',',NewTop,',',NewWidth,'x',NewHeight,
' BoundsRealized=',dbgs(FBoundsRealized), ' BoundsRealized=',dbgs(FBoundsRealized),
' wcfClientRectNeedsUpdate=',wcfClientRectNeedsUpdate in FWinControlFlags]); ' wcfClientRectNeedsUpdate=',wcfClientRectNeedsUpdate in FWinControlFlags]);
{ $ENDIF} {$ENDIF}
TopParent:=GetTopParent; TopParent:=GetTopParent;
if (TopParent is TWinControl) if (TopParent is TWinControl)
@ -7256,6 +7256,7 @@ begin
Exclude(FWinControlFlags, wcfCreatingChildHandles); Exclude(FWinControlFlags, wcfCreatingChildHandles);
end; end;
InvalidatePreferredSize;
if FControls<>nil then if FControls<>nil then
for i:=0 to FControls.Count-1 do for i:=0 to FControls.Count-1 do
TControl(FControls[i]).InvalidatePreferredSize; TControl(FControls[i]).InvalidatePreferredSize;