private void ShowItemPreview(object sender, System.EventArgs e) { if (null == this.formSummary) { this.formSummary = new FormSummary(); this.formSummary.Closed += new EventHandler(FormSummaryClosed); this.formSummary.Show(this.dockPanel); } else { this.formSummary.Close(); } this.menuItemItemPreview.Checked = (null != this.formSummary); }
private void FormSummaryClosed(object sender, EventArgs e) { this.formSummary.Dispose(); this.formSummary = null; this.menuItemItemPreview.Checked = false; }