X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/dd107c50be43e8d4dbdba20df162faf119a3781c..ff7047fde523c91a0065a6f1028ee87a7cba5a88:/contrib/samples/ogl/ogledit/doc.cpp diff --git a/contrib/samples/ogl/ogledit/doc.cpp b/contrib/samples/ogl/ogledit/doc.cpp index 25dae364c8..90545046d5 100644 --- a/contrib/samples/ogl/ogledit/doc.cpp +++ b/contrib/samples/ogl/ogledit/doc.cpp @@ -14,7 +14,7 @@ #endif // For compilers that support precompilation, includes "wx.h". -#include +#include "wx/wxprec.h" #ifdef __BORLANDC__ #pragma hdrstop @@ -28,7 +28,6 @@ #error You must set wxUSE_DOC_VIEW_ARCHITECTURE to 1 in wx_setup.h! #endif -#include #include "ogledit.h" #include "doc.h" #include "view.h" @@ -88,6 +87,8 @@ wxSTD istream& DiagramDocument::LoadObject(wxSTD istream& stream) wxOutputStream& DiagramDocument::SaveObject(wxOutputStream& stream) { +#if wxUSE_PROLOGIO + wxDocument::SaveObject(stream); char buf[400]; (void) wxGetTempFileName("diag", buf); @@ -97,16 +98,17 @@ wxOutputStream& DiagramDocument::SaveObject(wxOutputStream& stream) wxTransferFileToStream(buf, stream); wxRemoveFile(buf); - + +#endif return stream; } wxInputStream& DiagramDocument::LoadObject(wxInputStream& stream) { +#if wxUSE_PROLOGIO wxDocument::LoadObject(stream); - char buf[400]; (void) wxGetTempFileName("diag", buf); @@ -115,6 +117,7 @@ wxInputStream& DiagramDocument::LoadObject(wxInputStream& stream) diagram.DeleteAllShapes(); diagram.LoadFile(buf); wxRemoveFile(buf); +#endif return stream; } @@ -547,6 +550,8 @@ void MyEvtHandler::OnEndSize(double x, double y) /* * Diagram */ + +#if wxUSE_PROLOGIO bool MyDiagram::OnShapeSave(wxExprDatabase& db, wxShape& shape, wxExpr& expr) { @@ -569,6 +574,8 @@ bool MyDiagram::OnShapeLoad(wxExprDatabase& db, wxShape& shape, wxExpr& expr) return TRUE; } +#endif + /* * New shapes */