Exemple #1
0
        static void Main()
        {
            KMInterface mouseInterface = new KMInterface();

            // Start UDP server
            UdpServer udpServer       = new UdpServer(mouseInterface);
            Thread    udpServerThread = new Thread(new ThreadStart(udpServer.StartUDPServer));

            udpServerThread.IsBackground = true;
            udpServerThread.Start();

            // start TCP server
            AsynchronousSocketListener tcpServer = new AsynchronousSocketListener(mouseInterface);
            Thread tcpServerThread = new Thread(new ThreadStart(tcpServer.StartTCPServer));

            tcpServerThread.IsBackground = true;
            tcpServerThread.Start();

            DisplayNotifyIcon();
            Application.Run();
        }
Exemple #2
0
 public UdpServer(KMInterface mouseInterface)
 {
     this.mouseInterface = mouseInterface;
 }