コード例 #1
0
 public PrivateChatScreen(CommandClient cClient, IPAddress ip, string name, string initMsg)
 {
     InitializeComponent();
     targetClient           = cClient;
     targetIP               = ip;
     targetName             = name;
     Text                  += " With " + name;
     txtBox_PrivateMsg.Text = targetName + ": " + initMsg + Environment.NewLine;
     targetClient.received += new CommandReceivedEventHandler(privateCommandReceived);
 }
コード例 #2
0
 public LoginScreen(IPAddress ip, int port)
 {
     InitializeComponent();
     canExit = false;
     CheckForIllegalCrossThreadCalls = false;
     client            = new CommandClient(ip, port, "none");
     client.received  += new CommandReceivedEventHandler(CommandReceived);
     client.successed += new ConnectingSuccessedEventHandler(client_ConnectingSuccess);
     client.c_failed  += new ConnectingFailedEventHandler(client_ConnectingFailed);
 }
コード例 #3
0
 public FormMain()
 {
     InitializeComponent();
     chatList = new List <PrivateChatScreen>();
     client   = new CommandClient(IPAddress.Parse("0.0.0.0"), 8000, "None");
 }