unit Main;
interface
uses Windows, Classes, Graphics, Forms, Controls, Menus,
Dialogs, StdCtrls, Buttons, ExtCtrls, ComCtrls, ImgList, StdActns,
ActnList, ToolWin, uo, uoa, Messages, IdBaseComponent, IdComponent,
IdTCPConnection, IdTCPClient, IdCmdTCPClient, IdIRC, IdIPWatch, ScktComp;
type
TFUOIRC =
class(TForm)
BtNachricht: TButton;
BtIP: TButton;
Memo1: TMemo;
EdNachricht: TEdit;
EdIP: TEdit;
EdNick: TEdit;
BtNick: TButton;
Label1: TLabel;
Label2: TLabel;
Nachricht: TLabel;
Label4: TLabel;
Label5: TLabel;
Label6: TLabel;
IdIPWatch1: TIdIPWatch;
IdIRC1: TIdIRC;
procedure IdIRC1Disconnect(Sender: TObject);
procedure IdIRC1Connect(Sender: TObject);
procedure BtIPClick(Sender: TObject);
procedure BtNickClick(Sender: TObject);
procedure FormCreate(Sender: TObject);
procedure Delay(time: word);
private
{ Private-Deklarationen }
public
{ Public-Deklarationen }
end;
var
FUOIRC: TFUOIRC;
UOA : TUOAssist;
Nickname :
string;
implementation
uses about;
{$R *.dfm}
procedure TFUOIRC.delay(time: word);
var start : integer;
begin
Start:=GetTickCount;
while (GetTickCount)-(Start) <= time
do
Application.ProcessMessages;
end;
procedure TFUOIRC.FormCreate(Sender: TObject);
begin
left := Screen.Width - Fuoirc.Width;
top := Screen.Height - FUOirc.Height;
Label6.Caption:=IdIPWatch1.LocalIP;
BtIP.Enabled:=false;
BtNachricht.Enabled:=false;
end;
procedure TFUOIRC.BtNickClick(Sender: TObject);
begin
idirc1.Nickname := edNick.Text;
idirc1.Username := edNick.Text;
idirc1.RealName := edNick.Text;
EdNick.Enabled:=false;
BtNick.Enabled:=false;
BtIP.Enabled:=true;
end;
procedure TFUOIRC.BtIPClick(Sender: TObject);
begin
IdIRC1.host := '
irc.framecom.net';
IdIRC1.Port := 6667;
idIRC1.Password := '
';
IdIRC1.Connect;
//hier ist die Zugriffsverletzung
end;
procedure TFUOIRC.IdIRC1Connect(Sender: TObject);
begin
FUOIRC.Color := clGreeN;
end;
procedure TFUOIRC.IdIRC1Disconnect(Sender: TObject);
begin
FUOIRC.Color := clRed;
end;
end.