示例#1
0
文件: App.xaml.cs 项目: bdr27/c-
        private void HandlerSetNetwork(object sender, RoutedEventArgs e)
        {
            var dialog = new IPAddressModal();
            dialog.Owner = clientMiniCheckers;
            dialog.ShowDialog();
            sendAddress = dialog.GetNetworkDetails();
            udpHandler.ConnectTo(sendAddress.GetIPAddress(), sendAddress.GetPortNumber());
            SetUserLogin();

            Debug.WriteLine("Sending to: " + sendAddress);
        }
示例#2
0
文件: App.xaml.cs 项目: bdr27/c-
        private void HandleMenuSetMulticast(object sender, RoutedEventArgs e)
        {
            var dialog = new IPAddressModal();
            dialog.Owner = clientMiniCheckers;
            dialog.SetMultiCast();
            dialog.ShowDialog();
            multicastAddress = dialog.GetNetworkDetails();
            multicastHandler.ConnectTo(multicastAddress.GetIPAddress(), multicastAddress.GetPortNumber());
            SetUserLogin();

            Debug.WriteLine("Set multicast to: " + multicastAddress);
        }