Exemplo n.º 1
0
        void SetMasterState(bool newMasterState)
        {
            if (Properties.Settings.Default.Master != newMasterState)
            {
                if (Properties.Settings.Default.Master)
                {
                    Properties.Settings.Default.Master = newMasterState;
                    NetControl.Start();
                }
                else
                {
                    Properties.Settings.Default.Master = newMasterState;
                    NetControl.Abort();
                }
            }


            ShowMasterState(newMasterState);
        }
Exemplo n.º 2
0
 private void MainForm_FormClosed(object sender, FormClosedEventArgs e)
 {
     NetControl.Abort();
     Properties.Settings.Default.Save();
 }