home *** CD-ROM | disk | FTP | other *** search
/ Media Share 13 / mediashare_13.zip / mediashare_13 / ZIPPED / PROGRAM / WTJ9403.ZIP / CONTAIN / CONTAVW.H < prev    next >
C/C++ Source or Header  |  1994-01-06  |  2KB  |  67 lines

  1. // contavw.h : interface of the CContainView class
  2. //
  3. /////////////////////////////////////////////////////////////////////////////
  4.  
  5. class CContainCntrItem;
  6.  
  7. class CContainView : public CView
  8. {
  9. protected: // create from serialization only
  10.     CContainView();
  11.     DECLARE_DYNCREATE(CContainView)
  12.  
  13. // Attributes
  14. public:
  15.     CContainDoc* GetDocument();
  16.     // m_pSelection holds the selection to the current CContainCntrItem.
  17.     // For many applications, such a member variable isn't adequate to
  18.     //  represent a selection, such as a multiple selection or a selection
  19.     //  of objects that are not CContainCntrItem objects.  This selection
  20.     //  mechanism is provided just to help you get started.
  21.  
  22.     // TODO: replace this selection mechanism with one appropriate to your app.
  23.     CContainCntrItem* m_pSelection;
  24.  
  25. // Operations
  26. public:
  27.  
  28. // Implementation
  29. public:
  30.     virtual ~CContainView();
  31.     virtual void OnDraw(CDC* pDC);  // overridden to draw this view
  32. #ifdef _DEBUG
  33.     virtual void AssertValid() const;
  34.     virtual void Dump(CDumpContext& dc) const;
  35. #endif
  36.  
  37. protected:
  38.     virtual void OnInitialUpdate(); // called first time after construct
  39.  
  40.     // Printing support
  41.     virtual BOOL OnPreparePrinting(CPrintInfo* pInfo);
  42.     virtual void OnBeginPrinting(CDC* pDC, CPrintInfo* pInfo);
  43.     virtual void OnEndPrinting(CDC* pDC, CPrintInfo* pInfo);
  44.  
  45.     // OLE Container support
  46.     virtual BOOL IsSelected(const CObject* pDocItem) const;
  47.  
  48. // Generated message map functions
  49. protected:
  50.     //{{AFX_MSG(CContainView)
  51.         // NOTE - the ClassWizard will add and remove member functions here.
  52.         //    DO NOT EDIT what you see in these blocks of generated code !
  53.     afx_msg void OnSetFocus(CWnd* pOldWnd);
  54.     afx_msg void OnSize(UINT nType, int cx, int cy);
  55.     afx_msg void OnInsertObject();
  56.     afx_msg void OnCancelEdit();
  57.     //}}AFX_MSG
  58.     DECLARE_MESSAGE_MAP()
  59. };
  60.  
  61. #ifndef _DEBUG  // debug version in contavw.cpp
  62. inline CContainDoc* CContainView::GetDocument()
  63.    { return (CContainDoc*)m_pDocument; }
  64. #endif
  65.  
  66. /////////////////////////////////////////////////////////////////////////////
  67.