Пример #1
0
 void _patronSummaryForm_FormClosed(object sender, FormClosedEventArgs e)
 {
     if (_patronSummaryForm != null
         && this.MainForm != null && this.MainForm.AppInfo != null)
     {
         this.MainForm.AppInfo.UnlinkFormState(_patronSummaryForm);
         this._patronSummaryForm = null;
     }
 }
Пример #2
0
        private void toolStripButton_openPatronSummaryWindow_Click(object sender, EventArgs e)
        {
            List<PatronSummary> summaries = BuildPatronSummary(null);

            _patronSummaryForm = new PatronSummaryForm();
            _patronSummaryForm.PatronSummaries = summaries;
            _patronSummaryForm.Font = this.Font;
            _patronSummaryForm.Show(this);
        }
Пример #3
0
        internal void DisplayReaderSummary(ChargingTask exclude_task,
            string strText)
        {
            if (this.IsDisposed)
                return;

            if (this.InvokeRequired)
            {
                Delegate_DisplayReaderSummary d = new Delegate_DisplayReaderSummary(DisplayReaderSummary);
                this.BeginInvoke(d,
                    new object[] { exclude_task, strText }
                    );
                return;
            }

            List<PatronSummary> summaries = BuildPatronSummary(exclude_task);

            if (_patronSummaryForm == null)
            {
                _patronSummaryForm = new PatronSummaryForm();
                _patronSummaryForm.FormClosed -= new FormClosedEventHandler(_patronSummaryForm_FormClosed);
                _patronSummaryForm.FormClosed += new FormClosedEventHandler(_patronSummaryForm_FormClosed);
                // _patronSummaryForm.Show(this);
            }

            _patronSummaryForm.PatronSummaries = summaries;
            _patronSummaryForm.Font = this.Font;


            if (_patronSummaryForm.Visible == false)
            {
                this.MainForm.AppInfo.LinkFormState(this._patronSummaryForm, "_patronSummaryForm_state");
                if (_patronSummaryForm.IsDisposed)
                    return;
                _patronSummaryForm.Show(this);
            }
            else
                _patronSummaryForm.FillList();

            _patronSummaryForm.Comment = strText;
            _patronSummaryForm.ShowComment();
        }