From 3bceafe8afdf681e51b2896fb8e8dfca086b5668 Mon Sep 17 00:00:00 2001 From: Rom Walton Date: Tue, 8 Apr 2014 16:37:39 -0400 Subject: [PATCH] MGR: Re-enable cancel confirmation dialog in the wizard. --- clientgui/WizardAttach.cpp | 7 +++++-- clientgui/WizardAttach.h | 2 +- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/clientgui/WizardAttach.cpp b/clientgui/WizardAttach.cpp index 2be5e03a90..ab59e199c5 100644 --- a/clientgui/WizardAttach.cpp +++ b/clientgui/WizardAttach.cpp @@ -625,12 +625,13 @@ wxWizardPageEx* CWizardAttach::_PushPageTransition( wxWizardPageEx* pCurrentPage return NULL; } -#if 0 void CWizardAttach::_ProcessCancelEvent( wxWizardExEvent& event ) { bool bCancelWithoutNextPage = false; wxWizardPageEx* page = GetCurrentPage(); + m_bCancelInProgress = true; + int iRetVal = wxGetApp().SafeMessageBox( _("Do you really want to cancel?"), _("Question"), @@ -676,9 +677,11 @@ void CWizardAttach::_ProcessCancelEvent( wxWizardExEvent& event ) { } if (wxYES != iRetVal) { event.Veto(); + m_bCancelInProgress = false; + } else { + m_bCancelInProgress = true; } } -#endif /*! * wxEVT_WIZARD_FINISHED event handler for ID_ATTACHPROJECTWIZARD diff --git a/clientgui/WizardAttach.h b/clientgui/WizardAttach.h index 5916ced01a..ba0f07a38d 100644 --- a/clientgui/WizardAttach.h +++ b/clientgui/WizardAttach.h @@ -245,7 +245,7 @@ public: wxWizardPageEx* _PushPageTransition( wxWizardPageEx* pCurrentPage, unsigned long ulPageID ); /// Cancel Event Infrastructure -// void _ProcessCancelEvent( wxWizardExEvent& event ); + void _ProcessCancelEvent( wxWizardExEvent& event ); /// Finish Button Environment bool GetAccountCreatedSuccessfully() const { return account_created_successfully ; }