bool wxDialog::Create(wxWindow *parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style, const wxString& name) { SetExtraStyle(GetExtraStyle() | wxTOPLEVEL_EX_DIALOG); // All dialogs should really have this style style |= wxTAB_TRAVERSAL; if ( !wxTopLevelWindow::Create(parent, id, title, pos, size, style, name) ) return false; if ( !m_hasFont ) SetFont(wxSystemSettings::GetFont(wxSYS_DEFAULT_GUI_FONT)); if ( HasFlag(wxRESIZE_BORDER) ) { CreateGripper(); Connect(wxEVT_CREATE, wxWindowCreateEventHandler(wxDialog::OnWindowCreate)); } return true; }
void wxDialog::SetWindowStyleFlag(long style) { wxDialogBase::SetWindowStyleFlag(style); if ( HasFlag(wxRESIZE_BORDER) ) CreateGripper(); else DestroyGripper(); }
bool wxDialog::Create(wxWindow *parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style, const wxString& name) { SetExtraStyle(GetExtraStyle() | wxTOPLEVEL_EX_DIALOG); // All dialogs should really have this style style |= wxTAB_TRAVERSAL; if ( !wxTopLevelWindow::Create(parent, id, title, pos, size, style, name) ) return false; if ( !m_hasFont ) SetFont(wxSystemSettings::GetFont(wxSYS_DEFAULT_GUI_FONT)); #if defined(__SMARTPHONE__) && defined(__WXWINCE__) SetLeftMenu(wxID_OK, _("OK")); #endif #if wxUSE_TOOLBAR && defined(__POCKETPC__) CreateToolBar(); #endif #if wxUSE_DIALOG_SIZEGRIP if ( HasFlag(wxRESIZE_BORDER) ) { CreateGripper(); Connect(wxEVT_CREATE, wxWindowCreateEventHandler(wxDialog::OnWindowCreate)); } #endif // wxUSE_DIALOG_SIZEGRIP return true; }