Пример #1
0
 private void ClosePopUpForm()
 {
     SetFlag(Show_Popup, false);
     SetFlag(Popup_Shown, true);
     if (!_popupForm.IsDisposed)
     {
         _popupForm.FormClosed  -= PopupWindowFormClosed;
         _popupForm.FormClosing -= PopupWindowFormClosing;
         _popupForm.Dispose();
         OnPopupWindowClosed(new EventArgs());
     }
     _popupForm = null;
 }
Пример #2
0
        /// <summary>
        /// Opens the pop-up form
        /// </summary>
        protected void OpenPopupWindow()
        {
            if (_popupForm == null)
            {
                SetFlag(Show_Popup, true);

                _popupForm                = new PopupForm(this, _hostControl);
                _popupForm.Bounds         = GetDropdownBounds();
                _popupForm.ShowDropShadow = ShowDropShadow;
                _popupForm.FormClosing   += PopupWindowFormClosing;
                _popupForm.FormClosed    += PopupWindowFormClosed;
                _popupForm.Show(this);
            }
        }