X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/56d7679d3ef0bf4d761d791df00ce17ecd662014..7742efff20a96c52bf18c38da606e6522e728877:/src/common/docview.cpp diff --git a/src/common/docview.cpp b/src/common/docview.cpp index a6687e39a6..e5dda96883 100644 --- a/src/common/docview.cpp +++ b/src/common/docview.cpp @@ -42,6 +42,7 @@ #include "wx/intl.h" #endif + #ifdef __WXGTK__ #include "wx/mdi.h" #endif @@ -281,10 +282,10 @@ bool wxDocument::OnSaveDocument(const wxString& file) msgTitle = wxString(_("File error")); #if wxUSE_STD_IOSTREAM - ofstream store(file.fn_str()); + ofstream store(FNSTRINGCAST file.fn_str()); if (store.fail() || store.bad()) #else - wxFileOutputStream store(file.fn_str()); + wxFileOutputStream store(FNSTRINGCAST file.fn_str()); if (store.LastError() != 0) #endif { @@ -317,10 +318,10 @@ bool wxDocument::OnOpenDocument(const wxString& file) msgTitle = wxString(_("File error")); #if wxUSE_STD_IOSTREAM - ifstream store(file.fn_str()); + ifstream store(FNSTRINGCAST file.fn_str()); if (store.fail() || store.bad()) #else - wxFileInputStream store(file.fn_str()); + wxFileInputStream store(FNSTRINGCAST file.fn_str()); if (store.LastError() != 0) #endif { @@ -834,7 +835,7 @@ void wxDocManager::OnPrintSetup(wxCommandEvent& WXUNUSED(event)) wxPrintDialogData data; - wxPrintDialog printerDialog(parentWin, & data); + wxPrintDialog printerDialog(parentWin, &data); printerDialog.GetPrintDialogData().SetSetupDialog(TRUE); printerDialog.ShowModal(); #endif // wxUSE_PRINTING_ARCHITECTURE @@ -1297,7 +1298,7 @@ wxDocTemplate *wxDocManager::SelectDocumentType(wxDocTemplate **templates, } wxDocTemplate *theTemplate = (wxDocTemplate *)wxGetSingleChoiceData(_("Select a document template"), _("Templates"), n, - strings, data); + strings, (char **)data); delete[] strings; delete[] data; return theTemplate; @@ -1320,7 +1321,7 @@ wxDocTemplate *wxDocManager::SelectViewType(wxDocTemplate **templates, } } wxDocTemplate *theTemplate = (wxDocTemplate *)wxGetSingleChoiceData(_("Select a document view"), _("Views"), n, - strings, data); + strings, (char **)data); delete[] strings; delete[] data; return theTemplate;