fix gtk autosize loop

git-svn-id: trunk@18574 -
This commit is contained in:
paul 2009-02-05 02:55:49 +00:00
parent 702dc11c4c
commit 80e3207944
3 changed files with 5 additions and 4 deletions

View File

@ -1795,7 +1795,7 @@ type
AllowDisabled, AllowWinControls: Boolean): TControl;
function ControlAtPos(const Pos: TPoint; Flags: TControlAtPosFlags): TControl;
function ContainsControl(Control: TControl): Boolean;
procedure DoAdjustClientRectChange;
procedure DoAdjustClientRectChange(const InvalidateRect: Boolean = True);
procedure InvalidateClientRectCache(WithChildControls: boolean);
function ClientRectNeedsInterfaceUpdate: boolean;
procedure SetBounds(aLeft, aTop, aWidth, aHeight: integer); override;

View File

@ -3311,11 +3311,12 @@ end;
Asks the interface if clientrect has changed since last AlignControl
and calls AlignControl(nil) on change.
-------------------------------------------------------------------------------}
procedure TWinControl.DoAdjustClientRectChange;
procedure TWinControl.DoAdjustClientRectChange(const InvalidateRect: Boolean = True);
var
R: TRect;
begin
InvalidateClientRectCache(True);
if InvalidateRect then
InvalidateClientRectCache(True);
R := GetClientRect;
AdjustClientRect(R);
//DebugLn(['TWinControl.DoAdjustClientRectChange ',DbgSName(Self),' ',r.Right,',',r.Bottom,' ',CompareRect(@r,@FAdjustClientRectRealized)]);

View File

@ -6759,7 +6759,7 @@ begin
FFixWidgetsResized.Remove(FixWidget);
MainWidget:=GetMainWidget(FixWidget);
LCLControl:=TWinControl(GetLCLObject(MainWidget));
LCLControl.DoAdjustClientRectChange;
LCLControl.DoAdjustClientRectChange(False);
end else begin
break;
end;