mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-15 01:39:25 +02:00
lcl: TButtonPanel: fixed computing preferredsize
git-svn-id: branches/fixes_1_4@48632 -
This commit is contained in:
parent
464c53b4eb
commit
964cbf8e21
@ -23,7 +23,7 @@
|
|||||||
<UseVersionInfo Value="True"/>
|
<UseVersionInfo Value="True"/>
|
||||||
<MajorVersionNr Value="1"/>
|
<MajorVersionNr Value="1"/>
|
||||||
<MinorVersionNr Value="4"/>
|
<MinorVersionNr Value="4"/>
|
||||||
<BuildNr Value="3"/>
|
<BuildNr Value="4"/>
|
||||||
<CharSet Value="04B0"/>
|
<CharSet Value="04B0"/>
|
||||||
<StringTable ProductName="Lazarus IDE" ProductVersion=""/>
|
<StringTable ProductName="Lazarus IDE" ProductVersion=""/>
|
||||||
</VersionInfo>
|
</VersionInfo>
|
||||||
@ -70,6 +70,7 @@
|
|||||||
<Unit0>
|
<Unit0>
|
||||||
<Filename Value="lazarus.pp"/>
|
<Filename Value="lazarus.pp"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
|
<UnitName Value="Lazarus"/>
|
||||||
</Unit0>
|
</Unit0>
|
||||||
<Unit1>
|
<Unit1>
|
||||||
<Filename Value="frames/oi_options.pas"/>
|
<Filename Value="frames/oi_options.pas"/>
|
||||||
@ -302,7 +303,6 @@
|
|||||||
<Unit38>
|
<Unit38>
|
||||||
<Filename Value="main.pp"/>
|
<Filename Value="main.pp"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<UnitName Value="Main"/>
|
|
||||||
</Unit38>
|
</Unit38>
|
||||||
<Unit39>
|
<Unit39>
|
||||||
<Filename Value="../designer/designer.pp"/>
|
<Filename Value="../designer/designer.pp"/>
|
||||||
|
BIN
ide/lazarus.res
BIN
ide/lazarus.res
Binary file not shown.
@ -620,6 +620,7 @@ begin
|
|||||||
CtrlPrefWidth:=0;
|
CtrlPrefWidth:=0;
|
||||||
CtrlPrefHeight:=0;
|
CtrlPrefHeight:=0;
|
||||||
AControl.GetPreferredSize(CtrlPrefWidth,CtrlPrefHeight);
|
AControl.GetPreferredSize(CtrlPrefWidth,CtrlPrefHeight);
|
||||||
|
//debugln(['TCustomButtonPanel.CalculatePreferredSize ',DbgSName(AControl),' ',CtrlPrefHeight]);
|
||||||
if Align in [alLeft,alRight] then
|
if Align in [alLeft,alRight] then
|
||||||
begin
|
begin
|
||||||
inc(MinHeight,CtrlPrefHeight);
|
inc(MinHeight,CtrlPrefHeight);
|
||||||
@ -642,8 +643,8 @@ begin
|
|||||||
else
|
else
|
||||||
inc(MinHeight,FBevel.Height+Spacing);
|
inc(MinHeight,FBevel.Height+Spacing);
|
||||||
end;
|
end;
|
||||||
PreferredWidth:=Max(PreferredWidth,MinWidth);
|
PreferredWidth:=MinWidth;
|
||||||
PreferredHeight:=Max(PreferredHeight,MinHeight);
|
PreferredHeight:=MinHeight;
|
||||||
//debugln(['TCustomButtonPanel.CalculatePreferredSize ',DbgSName(Self),' ',PreferredWidth,'x',PreferredHeight]);
|
//debugln(['TCustomButtonPanel.CalculatePreferredSize ',DbgSName(Self),' ',PreferredWidth,'x',PreferredHeight]);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user