X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/f80ea77b4a8bac4ab005bfc592f9cd3262ffa397..b388e8cdec4f45124f31525e651a5e335965e4be:/contrib/utils/wxrcedit/editor.cpp?ds=sidebyside diff --git a/contrib/utils/wxrcedit/editor.cpp b/contrib/utils/wxrcedit/editor.cpp index c41c44d9a6..f24ce5f0f1 100644 --- a/contrib/utils/wxrcedit/editor.cpp +++ b/contrib/utils/wxrcedit/editor.cpp @@ -192,7 +192,7 @@ EditorFrame::EditorFrame(wxFrame *parent, const wxString& filename) wxConfigBase *cfg = wxConfigBase::Get(); - SetSize(wxRect(wxPoint(cfg->Read(_T("editor_x"), wxDefaultPosition.x), cfg->Read(_T("editor_y"), wxDefaultPosition.y)), + SetSize(wxRect(wxPoint(cfg->Read(_T("editor_x"), wxDefaultCoord), cfg->Read(_T("editor_y"), wxDefaultCoord)), wxSize(cfg->Read(_T("editor_w"), 400), cfg->Read(_T("editor_h"), 400)))); m_SelectedNode = NULL; @@ -228,16 +228,16 @@ EditorFrame::EditorFrame(wxFrame *parent, const wxString& filename) toolBar->SetMargins(2, 2); toolBar->SetToolBitmapSize(wxSize(24, 24)); toolBar -> AddTool(ID_EXIT, wxBITMAP(close), wxNullBitmap, - false, wxDefaultPosition.x, wxDefaultPosition.y, (wxObject *) NULL, + false, wxDefaultCoord, wxDefaultCoord, (wxObject *) NULL, _("Quit the editor")); toolBar -> AddTool(ID_OPEN, wxBITMAP(open), wxNullBitmap, - false, wxDefaultPosition.x, wxDefaultPosition.y, (wxObject *) NULL, + false, wxDefaultCoord, wxDefaultCoord, (wxObject *) NULL, _("Open XML resource file")); toolBar -> AddTool(ID_SAVE, wxBITMAP(save), wxNullBitmap, - false, wxDefaultPosition.x, wxDefaultPosition.y, (wxObject *) NULL, + false, wxDefaultCoord, wxDefaultCoord, (wxObject *) NULL, _("Save XML file")); toolBar -> AddTool(ID_PREVIEW, wxBITMAP(preview), wxNullBitmap, - false, wxDefaultPosition.x, wxDefaultPosition.y, (wxObject *) NULL, + false, wxDefaultCoord, wxDefaultCoord, (wxObject *) NULL, _("Preview")); toolBar -> Realize(); @@ -255,7 +255,6 @@ EditorFrame::EditorFrame(wxFrame *parent, const wxString& filename) m_TreeCtrl->AssignImageList(imgList); sizer->Add(m_TreeCtrl, 1, wxEXPAND); - SetAutoLayout(true); SetSizer(sizer); // Load file: @@ -533,7 +532,7 @@ void EditorFrame::OnToolbar(wxCommandEvent& event) case ID_OPEN : { wxString cwd = wxGetCwd(); // workaround for 2.2 - wxString name = wxFileSelector(_("Open XML resource"), _T(""), _T(""), _T(""), _("XML resources (*.xrc)|*.xrc"), wxOPEN | wxFILE_MUST_EXIST); + wxString name = wxFileSelector(_("Open XML resource"), wxEmptyString, wxEmptyString, wxEmptyString, _("XML resources (*.xrc)|*.xrc"), wxOPEN | wxFILE_MUST_EXIST); wxSetWorkingDirectory(cwd); if (!name.IsEmpty()) LoadFile(name); @@ -547,7 +546,7 @@ void EditorFrame::OnToolbar(wxCommandEvent& event) case ID_SAVEAS : { wxString cwd = wxGetCwd(); // workaround for 2.2 - wxString name = wxFileSelector(_("Save as"), _T(""), m_FileName, _T(""), _("XML resources (*.xrc)|*.xrc"), wxSAVE | wxOVERWRITE_PROMPT); + wxString name = wxFileSelector(_("Save as"), wxEmptyString, m_FileName, wxEmptyString, _("XML resources (*.xrc)|*.xrc"), wxSAVE | wxOVERWRITE_PROMPT); wxSetWorkingDirectory(cwd); if (!name.IsEmpty()) SaveFile((m_FileName = name));