예제 #1
0
 private void Button_Click_2(object sender, RoutedEventArgs e)
 {
     if (sndr != null)
     {
         sndr.Dispose();
         sndr = null;
     }
     if (rcvr != null)
     {
         rcvr.Dispose();
         rcvr = null;
     }
     Application.Current.Exit();
 }
예제 #2
0
        private async void Button_Click_3(object sender, RoutedEventArgs e)
        {
            Button butt = (Button)sender;

            if (butt != null)
            {
                string txt = (string)butt.Content;
                if (txt != "Stop Recv")
                {
                    RecvTxt = txt;
                    rcvr    = new OBEX_Receiver();
                    await rcvr.Initialize();

                    BtnRecv.Content = "Stop Recv";
                }
                else
                {
                    rcvr.Dispose();
                    rcvr            = null;
                    BtnRecv.Content = "RecvTxt";
                    PostMessage("", "Stopped Listening");
                }
            }
        }
예제 #3
0
 private void Button_Click_1(object sender, RoutedEventArgs e)
 {
     rcvr.Dispose();
     rcvr            = null;
     BtnRecv.Content = "RecvTxt";
 }