mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-09-10 22:19:19 +02:00
lcl: make questiondlg position on screencenter and have dialog borderstyle
git-svn-id: trunk@14643 -
This commit is contained in:
parent
a647d94b50
commit
a0f4af6597
@ -58,7 +58,7 @@ type
|
||||
function GetDialogCaption(idDiag: Integer): String;
|
||||
begin
|
||||
Result:='?';
|
||||
Case idDiag of
|
||||
case idDiag of
|
||||
idDialogWarning : Result:=rsMtWarning;
|
||||
idDialogError : Result:=rsMtError;
|
||||
idDialogInfo : Result:=rsMtInformation;
|
||||
@ -608,10 +608,12 @@ var
|
||||
ok: Boolean;
|
||||
begin
|
||||
inherited Create(nil);
|
||||
MessageTxt:=aMsg;
|
||||
HelpContext:=HelpCtx;
|
||||
OnKeyDown:=@ButtonKeyDown;
|
||||
ok:=false;
|
||||
BorderStyle := bsDialog;
|
||||
Position := poScreenCenter;
|
||||
MessageTxt := aMsg;
|
||||
HelpContext := HelpCtx;
|
||||
OnKeyDown := @ButtonKeyDown;
|
||||
ok := false;
|
||||
try
|
||||
i:=Low(Buttons);
|
||||
while i<=High(Buttons) do begin
|
||||
@ -644,7 +646,7 @@ begin
|
||||
//DebugLn('TQuestionDlg.CreateQuestionDlg CurBtnCaption=',CurBtnCaption);
|
||||
if CurBtnCaption='' then begin
|
||||
// find default caption
|
||||
Case CurBtnValue of
|
||||
case CurBtnValue of
|
||||
mrOk : CurBtnCaption:=rsmbOk;
|
||||
mrCancel : CurBtnCaption:=rsmbCancel;
|
||||
mrYes : CurBtnCaption:=rsmbYes;
|
||||
|
Loading…
Reference in New Issue
Block a user