示例#1
0
        private void ShowNewForm(object sender, EventArgs e)
        {
            UT60EConfigWizard config = new UT60EConfigWizard();
            var result = config.ShowDialog();

            if (result == System.Windows.Forms.DialogResult.OK)
            {
                UT60EDisplayForm    childForm  = new UT60EDisplayForm();
                UT60EMainController controller = new UT60EMainController(childForm, config.port_settings, config.log ? config.log_setting : null);
                childForm.Connect(controller);
                childForm.MdiParent = this;
                childForm.Show();
            }
        }
示例#2
0
 public void Disconnect(UT60EMainController controller)
 {
     controller.LoggingStarted -= this.OnLoggingStarted;
     controller.LoggingStopped -= this.OnLoggingStopped;
     this.controller            = null;
 }
示例#3
0
 public void Connect(UT60EMainController controller)
 {
     this.controller            = controller;
     controller.LoggingStarted += this.OnLoggingStarted;
     controller.LoggingStopped += this.OnLoggingStopped;
 }