]> git.saurik.com Git - wxWidgets.git/commitdiff
don't use the hack with handling wxID_CLOSE button events in wxDialog::OnCancel(...
authorVadim Zeitlin <vadim@wxwidgets.org>
Sat, 19 Aug 2006 23:19:07 +0000 (23:19 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Sat, 19 Aug 2006 23:19:07 +0000 (23:19 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@40690 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/generic/tipdlg.cpp

index 599d310fe967fd55b3d20176cf8d4fa3122082a9..839f75fb2cee1664317db794cbec90de2c39b215 100644 (file)
@@ -210,7 +210,6 @@ wxString wxFileTipProvider::GetTip()
 
 BEGIN_EVENT_TABLE(wxTipDialog, wxDialog)
     EVT_BUTTON(wxID_NEXT_TIP, wxTipDialog::OnNextTip)
-    EVT_BUTTON(wxID_CLOSE, wxTipDialog::OnCancel)
 END_EVENT_TABLE()
 
 wxTipDialog::wxTipDialog(wxWindow *parent,
@@ -229,6 +228,7 @@ wxTipDialog::wxTipDialog(wxWindow *parent,
     // smart phones does not support or do not waste space for wxButtons
 #ifndef __SMARTPHONE__
     wxButton *btnClose = new wxButton(this, wxID_CLOSE);
+    SetEscapeId(wxID_CLOSE);
 #endif
 
     m_checkbox = new wxCheckBox(this, wxID_ANY, _("&Show tips at startup"));