home *** CD-ROM | disk | FTP | other *** search
/ DP Tool Club 31 / CDASC_31_1996_juillet_aout.iso / vrac / wdj0796.zip / RAJA.ZIP / GENERVW.CPP < prev    next >
C/C++ Source or Header  |  1996-03-08  |  2KB  |  73 lines

  1. // genervw.cpp : implementation of the CGenericView class
  2. //
  3.  
  4. #include "stdafx.h"
  5. #include "generic.h"
  6.  
  7. #include "generdoc.h"
  8. #include "genervw.h"
  9.  
  10. #ifdef _DEBUG
  11. #undef THIS_FILE
  12. static char BASED_CODE THIS_FILE[] = __FILE__;
  13. #endif
  14.  
  15. /////////////////////////////////////////////////////////////////////////////
  16. // CGenericView
  17.  
  18. IMPLEMENT_DYNCREATE(CGenericView, CView)
  19.  
  20. BEGIN_MESSAGE_MAP(CGenericView, CView)
  21.     //{{AFX_MSG_MAP(CGenericView)
  22.         // NOTE - the ClassWizard will add and remove mapping macros here.
  23.         //    DO NOT EDIT what you see in these blocks of generated code!
  24.     //}}AFX_MSG_MAP
  25. END_MESSAGE_MAP()
  26.  
  27. /////////////////////////////////////////////////////////////////////////////
  28. // CGenericView construction/destruction
  29.  
  30. CGenericView::CGenericView()
  31. {
  32.     // TODO: add construction code here
  33. }
  34.  
  35. CGenericView::~CGenericView()
  36. {
  37. }
  38.  
  39. /////////////////////////////////////////////////////////////////////////////
  40. // CGenericView drawing
  41.  
  42. void CGenericView::OnDraw(CDC* pDC)
  43. {
  44.     CGenericDoc* pDoc = GetDocument();
  45.     ASSERT_VALID(pDoc);
  46.  
  47.     // TODO: add draw code for native data here
  48. }
  49.  
  50. /////////////////////////////////////////////////////////////////////////////
  51. // CGenericView diagnostics
  52.  
  53. #ifdef _DEBUG
  54. void CGenericView::AssertValid() const
  55. {
  56.     CView::AssertValid();
  57. }
  58.  
  59. void CGenericView::Dump(CDumpContext& dc) const
  60. {
  61.     CView::Dump(dc);
  62. }
  63.  
  64. CGenericDoc* CGenericView::GetDocument() // non-debug version is inline
  65. {
  66.     ASSERT(m_pDocument->IsKindOf(RUNTIME_CLASS(CGenericDoc)));
  67.     return (CGenericDoc*)m_pDocument;
  68. }
  69. #endif //_DEBUG
  70.  
  71. /////////////////////////////////////////////////////////////////////////////
  72. // CGenericView message handlers
  73.