home *** CD-ROM | disk | FTP | other *** search
/ Mastering MFC Development / MMD.ISO / samples / c07 / list / listview.h < prev    next >
Encoding:
C/C++ Source or Header  |  1997-02-20  |  1.4 KB  |  54 lines

  1. // ListView.h : interface of the CMyListView class
  2. //
  3. /////////////////////////////////////////////////////////////////////////////
  4.  
  5. class CMyListView : public CListView
  6. {
  7. protected: // create from serialization only
  8.     CMyListView();
  9.     DECLARE_DYNCREATE(CMyListView)
  10.  
  11. // Attributes
  12. public:
  13.     CListDoc* GetDocument();
  14.  
  15. // Operations
  16. public:
  17.  
  18. // Overrides
  19.     // ClassWizard generated virtual function overrides
  20.     //{{AFX_VIRTUAL(CMyListView)
  21.     public:
  22.     virtual void OnDraw(CDC* pDC);  // overridden to draw this view
  23.     virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
  24.     protected:
  25.     virtual void OnInitialUpdate(); // called first time after construct
  26.     virtual void OnUpdate(CView* pSender, LPARAM lHint, CObject* pHint);
  27.     //}}AFX_VIRTUAL
  28.  
  29. // Implementation
  30. public:
  31.     virtual ~CMyListView();
  32. #ifdef _DEBUG
  33.     virtual void AssertValid() const;
  34.     virtual void Dump(CDumpContext& dc) const;
  35. #endif
  36.  
  37. protected:
  38.  
  39. // Generated message map functions
  40. protected:
  41.     //{{AFX_MSG(CMyListView)
  42.         // NOTE - the ClassWizard will add and remove member functions here.
  43.         //    DO NOT EDIT what you see in these blocks of generated code !
  44.     //}}AFX_MSG
  45.     DECLARE_MESSAGE_MAP()
  46. };
  47.  
  48. #ifndef _DEBUG  // debug version in ListView.cpp
  49. inline CListDoc* CMyListView::GetDocument()
  50.    { return (CListDoc*)m_pDocument; }
  51. #endif
  52.  
  53. /////////////////////////////////////////////////////////////////////////////
  54.