- if ( escapeId == m_escapeId )
- return;
-
- if ( m_escapeId != wxID_ANY &&
- m_escapeId != wxID_CANCEL &&
- m_escapeId != wxID_ANY )
- {
- if ( !Disconnect
- (
- m_escapeId,
- wxEVT_COMMAND_BUTTON_CLICKED,
- wxCommandEventHandler(wxDialogBase::OnCancelButton)
- ) )
- {
- wxFAIL_MSG( _T("failed to disconnect old cancel handler") );
- }
- }
- //else: wxID_CANCEL is always handled
-