home *** CD-ROM | disk | FTP | other *** search
/ Using VRML (Special Edition) / Special_Edition_Using_VRML_CDROM_Que_1996.iso / webpages / software / win95 / browsers / ambersw / tutorial / lesson1 / lessodoc.cpp next >
C/C++ Source or Header  |  1995-09-17  |  2KB  |  92 lines

  1. // lessodoc.cpp : implementation of the CLesson1Doc class
  2. //
  3.  
  4. #include "stdafx.h"
  5. #include "lesson1.h"
  6.  
  7. #include "lessodoc.h"
  8.  
  9. #ifdef _DEBUG
  10. #undef THIS_FILE
  11. static char BASED_CODE THIS_FILE[] = __FILE__;
  12. #endif
  13.  
  14. /////////////////////////////////////////////////////////////////////////////
  15. // CLesson1Doc
  16.  
  17. IMPLEMENT_DYNCREATE(CLesson1Doc, CDocument)
  18.  
  19. BEGIN_MESSAGE_MAP(CLesson1Doc, CDocument)
  20.     //{{AFX_MSG_MAP(CLesson1Doc)
  21.         // NOTE - the ClassWizard will add and remove mapping macros here.
  22.         //    DO NOT EDIT what you see in these blocks of generated code!
  23.     //}}AFX_MSG_MAP
  24. END_MESSAGE_MAP()
  25.  
  26. /////////////////////////////////////////////////////////////////////////////
  27. // CLesson1Doc construction/destruction
  28.  
  29. CLesson1Doc::CLesson1Doc()
  30. {
  31.     // TODO: add one-time construction code here
  32.  
  33. }
  34.  
  35. CLesson1Doc::~CLesson1Doc()
  36. {
  37. }
  38.  
  39. BOOL CLesson1Doc::OnNewDocument()
  40. {
  41.     if (!CDocument::OnNewDocument())
  42.         return FALSE;
  43.  
  44.     // TODO: add reinitialization code here
  45.     // (SDI documents will reuse this document)
  46.  
  47.     return TRUE;
  48. }
  49.  
  50. /////////////////////////////////////////////////////////////////////////////
  51. // CLesson1Doc serialization
  52.  
  53. void CLesson1Doc::Serialize(CArchive& ar)
  54. {
  55.     if (ar.IsStoring())
  56.     {
  57.         // TODO: add storing code here
  58.     }
  59.     else
  60.     {
  61.         // TODO: add loading code here
  62.     }
  63. }
  64.  
  65. /////////////////////////////////////////////////////////////////////////////
  66. // CLesson1Doc diagnostics
  67.  
  68. #ifdef _DEBUG
  69. void CLesson1Doc::AssertValid() const
  70. {
  71.     CDocument::AssertValid();
  72. }
  73.  
  74. void CLesson1Doc::Dump(CDumpContext& dc) const
  75. {
  76.     CDocument::Dump(dc);
  77. }
  78. #endif //_DEBUG
  79.  
  80. /////////////////////////////////////////////////////////////////////////////
  81. // CLesson1Doc commands
  82.  
  83. BOOL CLesson1Doc::OnOpenDocument(LPCTSTR lpszPathName) 
  84. {
  85.     if (!CDocument::OnOpenDocument(lpszPathName))
  86.         return FALSE;
  87.     
  88.     // TODO: Add your specialized creation code here
  89.     
  90.     return TRUE;
  91. }
  92.