mirror of
https://github.com/dashr9230/SA-MP.git
synced 2024-12-22 22:47:29 +08:00
[exgui] Implementn Rcon procedures
This commit is contained in:
parent
118153f727
commit
23664f3362
BIN
exgui/Rcon.dfm
BIN
exgui/Rcon.dfm
Binary file not shown.
@ -10,13 +10,16 @@ type
|
|||||||
TfmRcon = class(TForm)
|
TfmRcon = class(TForm)
|
||||||
edInput: TEdit;
|
edInput: TEdit;
|
||||||
moOutput: TMemo;
|
moOutput: TMemo;
|
||||||
procedure edInputKeyPress(Sender: TObject; var Key: Char);
|
|
||||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||||
|
procedure edInputKeyPress(Sender: TObject; var Key: Char);
|
||||||
procedure FormShow(Sender: TObject);
|
procedure FormShow(Sender: TObject);
|
||||||
private
|
private
|
||||||
{ Private declarations }
|
{ Private declarations }
|
||||||
public
|
public
|
||||||
{ Public declarations }
|
Host: String;
|
||||||
|
Password: String;
|
||||||
|
protected
|
||||||
|
procedure CreateParams(var Params: TCreateParams); override;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
var
|
var
|
||||||
@ -26,19 +29,37 @@ implementation
|
|||||||
|
|
||||||
{$R *.dfm}
|
{$R *.dfm}
|
||||||
|
|
||||||
procedure TfmRcon.edInputKeyPress(Sender: TObject; var Key: Char);
|
procedure Output(szOutput: PChar); stdcall;
|
||||||
begin
|
begin
|
||||||
// TODO: TfmRcon.edInputKeyPress
|
fmRcon.moOutput.Lines.Add(szOutput);
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfmRcon.CreateParams(var Params: TCreateParams);
|
||||||
|
begin
|
||||||
|
inherited CreateParams(Params);
|
||||||
|
Params.ExStyle:= Params.ExStyle or WS_EX_APPWINDOW;
|
||||||
|
Params.WndParent:= GetDesktopWindow;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TfmRcon.FormClose(Sender: TObject; var Action: TCloseAction);
|
procedure TfmRcon.FormClose(Sender: TObject; var Action: TCloseAction);
|
||||||
begin
|
begin
|
||||||
// TODO: TfmRcon.FormClose
|
Destroy;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfmRcon.edInputKeyPress(Sender: TObject; var Key: Char);
|
||||||
|
begin
|
||||||
|
if Key = #13 then begin
|
||||||
|
if edInput.Text <> '' then begin
|
||||||
|
moOutput.Lines.Add('> ' + edInput.Text);
|
||||||
|
edInput.Text:= '';
|
||||||
|
end;
|
||||||
|
Key:= #0;
|
||||||
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TfmRcon.FormShow(Sender: TObject);
|
procedure TfmRcon.FormShow(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
// TODO: TfmRcon.FormShow
|
Caption:= 'Remote Console - ' + Host;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
end.
|
end.
|
||||||
|
Loading…
Reference in New Issue
Block a user