public Form1() { InitializeComponent(); mServer = new LahoreSocketServer(); mServer.RaiseClientConnectedEvent += HandleClientConnected; mServer.RaiseTextReceivedEvent += HandleTextReceived; }
public Form1() { InitializeComponent(); mServer = new LahoreSocketServer(); mServer.RaiseClientConnectedEvent += HandleClientConnected; mServer.RaiseTextReceivedEvent += HandleTextReceived; mServer.RaiseClientDisconnectedEvent += HandleClientDisconnected; //INICJALIZACJA KAMERY // get list of video devices videoDevicesList = new FilterInfoCollection(FilterCategory.VideoInputDevice); foreach (FilterInfo videoDevice in videoDevicesList) { cmbVideoSource.Items.Add(videoDevice.Name); } if (cmbVideoSource.Items.Count > 0) { cmbVideoSource.SelectedIndex = 0; } else { MessageBox.Show("No video sources found", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error); } this.Closing += Form1_Closing; InicjalizujSerial(); serial1.DataReceived += new SerialDataReceivedEventHandler(port_OnReceiveDatazz); }
//List<string> connected_users; public MainWindow() { InitializeComponent(); mServer = new LahoreSocketServer(); mServer.RaiseClientConnectedEvent += HandleClientConnected; mServer.SocketDataTransferEvent += HandleSocketTransferDataReceived; mServer.ClientDisconnectedEvent += HandleClientDisconnected; //mServer.RaiseTextReceivedEvent += HandleTextReceived; //connected_users = new List<string>(); Application.Current.MainWindow.Closing += new CancelEventHandler(MainWindow_Closing); }
public Form1() { InitializeComponent(); mServer = new LahoreSocketServer(); mServer.RaiseClientConnectedEvent += HandleClientConnected; mServer.RaiseTextReceivedEvent += HandleTextReceived; /* Adds the event and the event handler for the method that will * process the timer event to the timer. */ myTimer.Tick += new EventHandler(TimerEventProcessor); // Sets the timer interval to 5 seconds. myTimer.Interval = 300; myTimer.Start(); }
public Form1() { InitializeComponent(); mServer = new LahoreSocketServer(); }