X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/36ca94a260b93ca35c5d5a09edfb8e104be0d694..88517d90087856e01002f1e3dea1a0ce659f28ea:/contrib/samples/ogl/studio/doc.cpp?ds=sidebyside diff --git a/contrib/samples/ogl/studio/doc.cpp b/contrib/samples/ogl/studio/doc.cpp index 8a76e6b40a..ed0a3a88d8 100644 --- a/contrib/samples/ogl/studio/doc.cpp +++ b/contrib/samples/ogl/studio/doc.cpp @@ -1,5 +1,5 @@ ///////////////////////////////////////////////////////////////////////////// -// Name: doc.cpp +// Name: contrib/samples/ogl/studio/doc.cpp // Purpose: Implements document functionality // Author: Julian Smart // Modified by: @@ -9,10 +9,6 @@ // Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// -#ifdef __GNUG__ -// #pragma implementation -#endif - // For compilers that support precompilation, includes "wx.h". #include "wx/wxprec.h" @@ -21,13 +17,13 @@ #endif #ifndef WX_PRECOMP -#include +#include "wx/wx.h" #endif #include "studio.h" #include "doc.h" #include "view.h" -#include +#include "wx/ogl/basicp.h" IMPLEMENT_DYNAMIC_CLASS(csDiagramDocument, wxDocument) @@ -53,6 +49,7 @@ bool csDiagramDocument::OnCloseDocument() return true; } +#if wxUSE_PROLOGIO bool csDiagramDocument::OnSaveDocument(const wxString& file) { if (file == wxEmptyString) @@ -97,9 +94,10 @@ bool csDiagramDocument::OnOpenDocument(const wxString& file) SetFilename(file, true); Modify(false); UpdateAllViews(); - + return true; } +#endif // wxUSE_PROLOGIO /* @@ -268,7 +266,7 @@ bool csCommandState::Do() ((csDiagramView*) m_doc->GetFirstView())->SelectShape(m_shapeOnCanvas, false); m_shapeOnCanvas->Unlink(); - + m_doc->GetDiagram()->RemoveShape(m_shapeOnCanvas); m_savedState = m_shapeOnCanvas; @@ -347,7 +345,7 @@ bool csCommandState::Do() lineShape->GetFrom()->AddLine(lineShape, lineShape->GetTo(), lineShape->GetAttachmentFrom(), lineShape->GetAttachmentTo()); - + lineShape->Show(true); wxClientDC dc(lineShape->GetCanvas()); @@ -475,7 +473,7 @@ bool csCommandState::Do() if (isSelected) m_shapeOnCanvas->Select(true, & dc); - + m_doc->Modify(true); m_doc->UpdateAllViews(); @@ -593,4 +591,3 @@ bool csCommandState::Undo() return true; } -