DragEditDoc.cpp
Upload User: jackiejxj
Upload Date: 2007-01-02
Package Size: 35k
Code Size: 2k
Category:

TreeView

Development Platform:

Visual C++

  1. // DragEditDoc.cpp : implementation of the CDragEditDoc class
  2. //
  3. #include "stdafx.h"
  4. #include "DragEdit.h"
  5. #include "DragEditDoc.h"
  6. #include "TestDragEditDlg.h"
  7. #ifdef _DEBUG
  8. #define new DEBUG_NEW
  9. #undef THIS_FILE
  10. static char THIS_FILE[] = __FILE__;
  11. #endif
  12. /////////////////////////////////////////////////////////////////////////////
  13. // CDragEditDoc
  14. IMPLEMENT_DYNCREATE(CDragEditDoc, CDocument)
  15. BEGIN_MESSAGE_MAP(CDragEditDoc, CDocument)
  16. //{{AFX_MSG_MAP(CDragEditDoc)
  17. ON_COMMAND(ID_FILE_TEST, OnFileTest)
  18. //}}AFX_MSG_MAP
  19. END_MESSAGE_MAP()
  20. /////////////////////////////////////////////////////////////////////////////
  21. // CDragEditDoc construction/destruction
  22. CDragEditDoc::CDragEditDoc()
  23. {
  24. // TODO: add one-time construction code here
  25. }
  26. CDragEditDoc::~CDragEditDoc()
  27. {
  28. }
  29. BOOL CDragEditDoc::OnNewDocument()
  30. {
  31. if (!CDocument::OnNewDocument())
  32. return FALSE;
  33. // TODO: add reinitialization code here
  34. // (SDI documents will reuse this document)
  35. return TRUE;
  36. }
  37. /////////////////////////////////////////////////////////////////////////////
  38. // CDragEditDoc serialization
  39. void CDragEditDoc::Serialize(CArchive& ar)
  40. {
  41. if (ar.IsStoring())
  42. {
  43. // TODO: add storing code here
  44. }
  45. else
  46. {
  47. // TODO: add loading code here
  48. }
  49. }
  50. /////////////////////////////////////////////////////////////////////////////
  51. // CDragEditDoc diagnostics
  52. #ifdef _DEBUG
  53. void CDragEditDoc::AssertValid() const
  54. {
  55. CDocument::AssertValid();
  56. }
  57. void CDragEditDoc::Dump(CDumpContext& dc) const
  58. {
  59. CDocument::Dump(dc);
  60. }
  61. #endif //_DEBUG
  62. /////////////////////////////////////////////////////////////////////////////
  63. // CDragEditDoc commands
  64. void CDragEditDoc::OnFileTest() 
  65. {
  66.     CTestDragEditDlg    dlg;
  67.     dlg.DoModal();
  68. }