ucall.pas

来自「NetPhone little VoIP program written in 」· PAS 代码 · 共 65 行

PAS
65
字号
unit uCall;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, StdCtrls, Buttons, ExtCtrls;

const
  ConfigFile     = 'NetPhone.cfx';
  SocksProxyFile = 'SocksProxy.txt';
  HttpProxyFile  = 'HttpProxy.txt';
  HistoryCall    = 'HistoryCall.txt';
  
type
  TFormCall = class(TForm)
    Label1: TLabel;
    Panel1: TPanel;
    Label3: TLabel;
    Label5: TLabel;
    Label6: TLabel;
    EdSocksUser: TEdit;
    EdSocksPass: TEdit;
    RbSocks4: TRadioButton;
    RbSocks5: TRadioButton;
    CkSocks: TCheckBox;
    CkHttp: TCheckBox;
    Panel2: TPanel;
    Label7: TLabel;
    Label9: TLabel;
    Label10: TLabel;
    EdHttpUser: TEdit;
    EdHttpPass: TEdit;
    BtStart: TBitBtn;
    BtCancel: TBitBtn;
    BtAdd: TBitBtn;
    EdIP: TComboBox;
    EdSocksIP: TComboBox;
    EdHttpIP: TComboBox;
    procedure BtAddClick(Sender: TObject);
    procedure FormCreate(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

implementation

{$R *.dfm}

procedure TFormCall.BtAddClick(Sender: TObject);
begin
  if Trim(EdIP.Text) <> '' then EdIP.Items.Insert(0, EdIP.Text); 
end;

procedure TFormCall.FormCreate(Sender: TObject);
begin
  if FileExists(SocksProxyFile) then EdSocksIP.Items.LoadFromFile(SocksProxyFile);
  if FileExists(HttpProxyFile) then EdHttpIP.Items.LoadFromFile(HttpProxyFile);
  if FileExists(HistoryCall) then EdIP.Items.LoadFromFile(HistoryCall);
end;

end.

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?