corrected type for text document (non standard save handler)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@18670 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Stefan Csomor 2003-01-10 17:57:05 +00:00
parent 738a6daa71
commit 450a5bdd2d

View File

@ -24,6 +24,9 @@
#include "wx/wx.h"
#endif
#include "wx/txtstrm.h"
#ifdef __WXMAC__
#include "wx/filename.h"
#endif
#if !wxUSE_DOC_VIEW_ARCHITECTURE
#error You must set wxUSE_DOC_VIEW_ARCHITECTURE to 1 in setup.h!
@ -31,7 +34,6 @@
#include "doc.h"
#include "view.h"
IMPLEMENT_DYNAMIC_CLASS(DrawingDocument, wxDocument)
DrawingDocument::DrawingDocument(void)
@ -342,6 +344,10 @@ bool TextEditDocument::OnSaveDocument(const wxString& filename)
if (!view->textsw->SaveFile(filename))
return FALSE;
Modify(FALSE);
#ifdef __WXMAC__
wxFileName fn(filename) ;
fn.MacSetDefaultTypeAndCreator() ;
#endif
return TRUE;
}