mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-18 12:59:14 +02:00
LCL: TPromptDialog: support ChangeScale
git-svn-id: trunk@55533 -
This commit is contained in:
parent
c4c7fec236
commit
382b5e3ee7
@ -20,6 +20,8 @@ type
|
|||||||
protected
|
protected
|
||||||
procedure DoAutoAdjustLayout(const AMode: TLayoutAdjustmentPolicy;
|
procedure DoAutoAdjustLayout(const AMode: TLayoutAdjustmentPolicy;
|
||||||
const AXProportion, AYProportion: Double); override;
|
const AXProportion, AYProportion: Double); override;
|
||||||
|
procedure ChangeScale(Multiplier, Divider: Integer); override;
|
||||||
|
procedure FontChanged(Sender: TObject); override;
|
||||||
public
|
public
|
||||||
IsSmallDevice: Boolean;
|
IsSmallDevice: Boolean;
|
||||||
|
|
||||||
@ -206,6 +208,16 @@ begin
|
|||||||
LayoutDialog;
|
LayoutDialog;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
procedure TPromptDialog.ChangeScale(Multiplier, Divider: Integer);
|
||||||
|
begin
|
||||||
|
inherited ChangeScale(Multiplier, Divider);
|
||||||
|
|
||||||
|
TextBox.Left := MulDiv(TextBox.Left, Multiplier, Divider);
|
||||||
|
TextBox.Top := MulDiv(TextBox.Top, Multiplier, Divider);
|
||||||
|
TextBox.Right := MulDiv(TextBox.Right, Multiplier, Divider);
|
||||||
|
TextBox.Bottom := MulDiv(TextBox.Bottom, Multiplier, Divider);
|
||||||
|
end;
|
||||||
|
|
||||||
destructor TPromptDialog.Destroy;
|
destructor TPromptDialog.Destroy;
|
||||||
begin
|
begin
|
||||||
FBitmap.Free;
|
FBitmap.Free;
|
||||||
@ -227,6 +239,13 @@ begin
|
|||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
procedure TPromptDialog.FontChanged(Sender: TObject);
|
||||||
|
begin
|
||||||
|
inherited FontChanged(Sender);
|
||||||
|
|
||||||
|
TextStyle.SystemFont := False;
|
||||||
|
end;
|
||||||
|
|
||||||
function TPromptDialog.GetMessageText: string;
|
function TPromptDialog.GetMessageText: string;
|
||||||
begin
|
begin
|
||||||
Result := MSG;
|
Result := MSG;
|
||||||
|
Loading…
Reference in New Issue
Block a user