X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/28ea89b62b322ea36aadb65d35caef1b0cf5de5d..a5f5f678f259e401139235d86fb510894bca2ebb:/src/common/docview.cpp diff --git a/src/common/docview.cpp b/src/common/docview.cpp index 4ca21c436e..152b8102ea 100644 --- a/src/common/docview.cpp +++ b/src/common/docview.cpp @@ -17,10 +17,6 @@ // headers // ---------------------------------------------------------------------------- -#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) - #pragma implementation "docview.h" -#endif - // For compilers that support precompilation, includes "wx.h". #include "wx/wxprec.h" @@ -571,7 +567,7 @@ bool wxDocument::DoSaveDocument(const wxString& file) msgTitle = wxString(_("File error")); #if wxUSE_STD_IOSTREAM - wxSTD ofstream store(file.mb_str()); + wxSTD ofstream store(file.mb_str(), wxSTD ios::binary); if (store.fail() || store.bad()) #else wxFileOutputStream store(file); @@ -597,7 +593,7 @@ bool wxDocument::DoSaveDocument(const wxString& file) bool wxDocument::DoOpenDocument(const wxString& file) { #if wxUSE_STD_IOSTREAM - wxSTD ifstream store(file.mb_str()); + wxSTD ifstream store(file.mb_str(), wxSTD ios::binary); if (!store.fail() && !store.bad()) #else wxFileInputStream store(file); @@ -2219,10 +2215,10 @@ void wxFileHistory::RemoveFileFromHistory(size_t i) // delete the last separator too if no more files are left if ( m_fileHistoryN == 1 ) { - wxMenuItemList::compatibility_iterator node = menu->GetMenuItems().GetLast(); - if ( node ) + wxMenuItemList::compatibility_iterator nodeLast = menu->GetMenuItems().GetLast(); + if ( nodeLast ) { - wxMenuItem *menuItem = node->GetData(); + wxMenuItem *menuItem = nodeLast->GetData(); if ( menuItem->IsSeparator() ) { menu->Delete(menuItem);