void SampleCsForm_FormClosed(object sender, FormClosedEventArgs e) { if (null != _form) { _form = null; } }
/// <summary> /// This gets called when when the user runs this command. /// </summary> public override IRhinoCommand.result RunCommand(IRhinoCommandContext context) { if (null != _form) return IRhinoCommand.result.nothing; _form = new SampleCsForm(); _form.FormClosed += new FormClosedEventHandler(SampleCsForm_FormClosed); _form.Show(RhUtil.RhinoApp().MainWnd()); return IRhinoCommand.result.success; }
/// <summary> /// This gets called when when the user runs this command. /// </summary> public override IRhinoCommand.result RunCommand(IRhinoCommandContext context) { if (null != _form) { return(IRhinoCommand.result.nothing); } _form = new SampleCsForm(); _form.FormClosed += new FormClosedEventHandler(SampleCsForm_FormClosed); _form.Show(RhUtil.RhinoApp().MainWnd()); return(IRhinoCommand.result.success); }
void SampleCsForm_FormClosed(object sender, FormClosedEventArgs e) { if (null != _form) _form = null; }