mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-26 20:43:46 +02:00
lcl: support for DebugDisableAutoSizing compiler define
git-svn-id: trunk@54813 -
This commit is contained in:
parent
e3f7770451
commit
ede8a86d9d
@ -3008,7 +3008,7 @@ begin
|
||||
// Apply the changes
|
||||
if AMode in [lapAutoAdjustWithoutHorizontalScrolling, lapAutoAdjustForDPI] then
|
||||
begin
|
||||
DisableAutoSizing;
|
||||
DisableAutoSizing{$IFDEF DebugDisableAutoSizing}('TControl.DoAutoAdjustLayout'){$ENDIF};
|
||||
try
|
||||
if not ParentFont or (Parent=nil) then
|
||||
ScaleFontsPPI(AYProportion);
|
||||
@ -3082,7 +3082,7 @@ begin
|
||||
|
||||
SetBounds(NewLeft, NewTop, NewWidth, NewHeight);
|
||||
finally
|
||||
EnableAutoSizing;
|
||||
EnableAutoSizing{$IFDEF DebugDisableAutoSizing}('TControl.DoAutoAdjustLayout'){$ENDIF};
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
@ -1574,7 +1574,7 @@ begin
|
||||
// Apply the changes
|
||||
if AMode in [lapAutoAdjustWithoutHorizontalScrolling, lapAutoAdjustForDPI] then
|
||||
begin
|
||||
DisableAutoSizing;
|
||||
DisableAutoSizing{$IFDEF DebugDisableAutoSizing}('TCustomForm.DoAutoAdjustLayout'){$ENDIF};
|
||||
try
|
||||
if not ParentFont or (Parent=nil) then
|
||||
ScaleFontsPPI(AYProportion);
|
||||
@ -1587,7 +1587,7 @@ begin
|
||||
|
||||
SetBounds(Left, Top, NewWidth, NewHeight);
|
||||
finally
|
||||
EnableAutoSizing;
|
||||
EnableAutoSizing{$IFDEF DebugDisableAutoSizing}('TCustomForm.DoAutoAdjustLayout'){$ENDIF};
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
@ -3327,14 +3327,14 @@ begin
|
||||
|
||||
if AMode in [lapAutoAdjustWithoutHorizontalScrolling, lapAutoAdjustForDPI] then
|
||||
begin
|
||||
DisableAutoSizing;
|
||||
DisableAutoSizing{$IFDEF DebugDisableAutoSizing}('TCustomTreeView.DoAutoAdjustLayout'){$ENDIF};
|
||||
try
|
||||
if not (tvoAutoItemHeight in Options) then
|
||||
DefaultItemHeight := Round(DefaultItemHeight*AYProportion);
|
||||
FIndent := Round(FIndent*AXProportion);
|
||||
FExpandSignSize := Round(FExpandSignSize*AXProportion);
|
||||
finally
|
||||
EnableAutoSizing;
|
||||
EnableAutoSizing{$IFDEF DebugDisableAutoSizing}('TCustomTreeView.DoAutoAdjustLayout'){$ENDIF};
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
@ -3844,14 +3844,14 @@ procedure TWinControl.AutoAdjustLayout(AMode: TLayoutAdjustmentPolicy;
|
||||
var
|
||||
i: Integer;
|
||||
begin
|
||||
DisableAutoSizing;
|
||||
DisableAutoSizing{$IFDEF DebugDisableAutoSizing}('TWinControl.AutoAdjustLayout'){$ENDIF};
|
||||
try
|
||||
for i:=0 to ControlCount-1 do
|
||||
Controls[i].AutoAdjustLayout(AMode, AFromPPI, AToPPI, AOldFormWidth, ANewFormWidth);
|
||||
|
||||
inherited;
|
||||
finally
|
||||
EnableAutoSizing;
|
||||
EnableAutoSizing{$IFDEF DebugDisableAutoSizing}('TWinControl.AutoAdjustLayout'){$ENDIF};
|
||||
end;
|
||||
end;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user