Example #1
0
 private void brushesToolStripMenuItem_Click(object sender, EventArgs e)
 {
     if (brushForm.Visible)
     {
         brushForm.Hide();
     }
     else
     {
         brushForm.Show();
     }
     brushesToolStripMenuItem.Checked = brushForm.Visible;
 }
Example #2
0
 void CreateBrushForm()
 {
     brushForm = new BrushForm();
     brushForm.BrushChanged += brushForm_BrushChanged;
     brushForm.Shown        += (s, e) => brushesToolStripMenuItem.Checked = true;
     brushForm.FormClosing  += (s, e) =>
     {
         e.Cancel = true;
         brushForm.Hide();
         brushesToolStripMenuItem.Checked = false;
     };
 }
Example #3
0
 void CreateBrushForm()
 {
     brushForm = new BrushForm();
     brushForm.BrushChanged += brushForm_BrushChanged;
     brushForm.Shown += (s, e) => brushesToolStripMenuItem.Checked = true;
     brushForm.FormClosing += (s, e) =>
     {
         e.Cancel = true;
         brushForm.Hide();
         brushesToolStripMenuItem.Checked = false;
     };
 }