示例#1
0
 private void toggleLog_Click(object sender, EventArgs e)
 {
     if (toggleLog.Tag != null)
     {
         if (toggleLog.Tag.ToString() == "true")
         {
             parent.SetLogVisibility(false);
             toggleLog.Tag  = "false";
             toggleLog.Text = "Show Log";
             RegOps.WriteSetting("ShowLog", 0, RegistryValueKind.DWord, ref settings);
         }
         else
         {
             parent.SetLogVisibility(true);
             toggleLog.Tag  = "true";
             toggleLog.Text = "Hide Log";
             RegOps.WriteSetting("ShowLog", 1, RegistryValueKind.DWord, ref settings);
         }
     }
     else
     {
         parent.SetLogVisibility(true);
         toggleLog.Tag  = "true";
         toggleLog.Text = "Hide Log";
         RegOps.WriteSetting("ShowLog", 1, RegistryValueKind.DWord, ref settings);
     }
 }
示例#2
0
        private void setPathToolStripMenuItem_Click(object sender, EventArgs e)
        {
            using (OpenFileDialog dialog = new OpenFileDialog())
            {
                dialog.InitialDirectory = Directory.GetParent(Assembly.GetExecutingAssembly().Location).FullName;
                DialogResult dialogResult = dialog.ShowDialog();

                if (dialogResult == DialogResult.OK)
                {
                    ServerPath = dialog.FileName;
                    RegOps.WriteSetting("ServerPath", dialog.FileName, RegistryValueKind.String, ref settings);
                }
            }
        }
示例#3
0
 private void radioButton3_CheckedChanged(object sender, EventArgs e)
 {
     RegOps.WriteSetting("NotificationStyle", "Disabled", RegistryValueKind.String, ref settings);
 }