#include "wx/statbmp.h"
#include "wx/stattext.h"
#include "wx/sizer.h"
+ #include "wx/settings.h"
#endif // WX_PRECOMP
#include "wx/statline.h"
#include "wx/artprov.h"
-#include "wx/settings.h"
#include "wx/tipdlg.h"
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,
wxTipProvider *tipProvider,
bool showAtStartup)
- : wxDialog(parent, wxID_ANY, _("Tip of the Day"),
+ : wxDialog(GetParentForModalDialog(parent), wxID_ANY, _("Tip of the Day"),
wxDefaultPosition, wxDefaultSize,
wxDEFAULT_DIALOG_STYLE | wxRESIZE_BORDER
)
// smart phones does not support or do not waste space for wxButtons
#ifndef __SMARTPHONE__
wxButton *btnClose = new wxButton(this, wxID_CLOSE);
+ SetAffirmativeId(wxID_CLOSE);
#endif
m_checkbox = new wxCheckBox(this, wxID_ANY, _("&Show tips at startup"));