mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-08 22:58:50 +02:00
lcl: updown: add flat property.
git-svn-id: trunk@51966 -
This commit is contained in:
parent
4111ab4964
commit
bc17ed1345
@ -1851,6 +1851,7 @@ type
|
||||
FWrap: Boolean;
|
||||
function GetPosition: SmallInt;
|
||||
procedure BTimerExec(Sender : TObject);
|
||||
function GetFlat: Boolean;
|
||||
procedure SetAlignButton(Value: TUDAlignButton);
|
||||
procedure SetArrowKeys(Value: Boolean);
|
||||
procedure SetAssociate(Value: TWinControl);
|
||||
@ -1861,6 +1862,7 @@ type
|
||||
procedure SetOrientation(Value: TUDOrientation);
|
||||
procedure SetPosition(Value: SmallInt);
|
||||
procedure SetThousands(Value: Boolean);
|
||||
procedure SetFlat(Value: Boolean);
|
||||
procedure SetWrap(Value: Boolean);
|
||||
procedure UpdateAlignButtonPos;
|
||||
procedure UpdateOrientation;
|
||||
@ -1893,6 +1895,7 @@ type
|
||||
property Orientation: TUDOrientation read FOrientation write SetOrientation default udVertical;
|
||||
property Position: SmallInt read GetPosition write SetPosition;
|
||||
property Thousands: Boolean read FThousands write SetThousands default True;
|
||||
property Flat: Boolean read GetFlat write SetFlat default False;
|
||||
property Wrap: Boolean read FWrap write SetWrap;
|
||||
public
|
||||
constructor Create(AOwner: TComponent); override;
|
||||
@ -1938,6 +1941,7 @@ type
|
||||
property TabOrder;
|
||||
property TabStop;
|
||||
property Thousands;
|
||||
property Flat;
|
||||
property Visible;
|
||||
property Wrap;
|
||||
end;
|
||||
|
@ -483,6 +483,14 @@ begin
|
||||
Result := FPosition;
|
||||
end;
|
||||
|
||||
function TCustomUpDown.GetFlat: Boolean;
|
||||
begin
|
||||
if FMinBtn<>nil then
|
||||
Result := (FMinBtn as TSpeedButton).Flat
|
||||
else
|
||||
Result := False;
|
||||
end;
|
||||
|
||||
procedure TCustomUpDown.SetMin(Value: SmallInt);
|
||||
begin
|
||||
if Value <> FMin then
|
||||
@ -549,6 +557,14 @@ begin
|
||||
FThousands := Value;
|
||||
end;
|
||||
|
||||
procedure TCustomUpDown.SetFlat(Value: Boolean);
|
||||
begin
|
||||
if Flat = Value then Exit;
|
||||
|
||||
(FMinBtn as TSpeedButton).Flat := Value;
|
||||
(FMaxBtn as TSpeedButton).Flat := Value;
|
||||
end;
|
||||
|
||||
procedure TCustomUpDown.SetWrap(Value: Boolean);
|
||||
begin
|
||||
if Value <> FWrap then
|
||||
|
Loading…
Reference in New Issue
Block a user