public VacationCancelPopupWindow openVacationCancelPopupWindow(int secondsLeft, int secondsLeftToCancel, bool canCancel) { this.openGreyOutWindowLogin(true); this.closePopupWindow(this.m_VacationCancelPopupWindow); this.m_VacationCancelPopupWindow = new VacationCancelPopupWindow(); this.positionWindow(this.m_VacationCancelPopupWindow, true, false); this.m_VacationCancelPopupWindow.init(secondsLeft, secondsLeftToCancel, canCancel); this.m_VacationCancelPopupWindow.Show(this.getGreyOutWindow()); GameEngine.Instance.DisableMouseClicks(); this.m_VacationCancelPopupWindow.Location = new Point(Program.profileLogin.Location.X + ((Program.profileLogin.Width - this.m_VacationCancelPopupWindow.Width) / 2), Program.profileLogin.Location.Y + ((Program.profileLogin.Height - this.m_VacationCancelPopupWindow.Height) / 2)); Program.profileLogin.TopMost = false; this.m_greyOutWindow.BringToFront(); this.m_VacationCancelPopupWindow.BringToFront(); this.m_VacationCancelPopupWindow.TopMost = true; this.m_VacationCancelPopupWindow.Focus(); this.m_VacationCancelPopupWindow.TopMost = false; return this.m_VacationCancelPopupWindow; }
public void closeVacationCancelPopupWindow() { if (!this.VacationCancelPopupWindowClosing) { this.VacationCancelPopupWindowClosing = true; if (this.isPopupWindowOpenAndClose(this.m_VacationCancelPopupWindow)) { GameEngine.Instance.EnableMouseClicks(); this.closeGreyOut(); this.showDXCardBar(9); Instance.closeParishPanel(); } this.m_VacationCancelPopupWindow = null; this.VacationCancelPopupWindowClosing = false; Program.profileLogin.TopMost = true; Program.profileLogin.BringToFront(); Program.profileLogin.TopMost = false; } }