home *** CD-ROM | disk | FTP | other *** search
/ Tricks of the Windows Gam…ming Gurus (2nd Edition) / Disc2.iso / msdn_vcb / samples / vc98 / mfc / ole / oclient / maindoc.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-03-27  |  1.5 KB  |  56 lines

  1. // maindoc.h : interface of the CMainDoc class
  2. //
  3. // This is a part of the Microsoft Foundation Classes C++ library.
  4. // Copyright (C) 1992-1998 Microsoft Corporation
  5. // All rights reserved.
  6. //
  7. // This source code is only intended as a supplement to the
  8. // Microsoft Foundation Classes Reference and related
  9. // electronic documentation provided with the library.
  10. // See these sources for detailed information regarding the
  11. // Microsoft Foundation Classes product.
  12.  
  13.  
  14. class CRectItem;
  15.  
  16. class CMainDoc : public COleLinkingDoc
  17. {
  18. protected: // create from serialization only
  19.     CMainDoc();
  20.     DECLARE_DYNCREATE(CMainDoc)
  21.  
  22. // Attributes
  23. public:
  24.     static CLIPFORMAT m_cfPrivate;
  25.     CSize m_sizeDoc;
  26.     CSize& GetDocumentSize();
  27.     BOOL m_bNeedUpdate;
  28.  
  29. // Operations
  30. public:
  31.     CRectItem* CreateItem();    // this document only stores CRectItems
  32.     void DeleteItem(CRectItem* pItem);
  33.     void AdjustItemPosition(CRectItem* pItem);
  34.  
  35. // Implementation
  36. public:
  37.     virtual ~CMainDoc();
  38.     virtual void Serialize(CArchive& ar);   // overridden for document i/o
  39.     virtual void OnShowViews(BOOL bVisible);
  40.  
  41. #ifdef _DEBUG
  42.     virtual void AssertValid() const;
  43.     virtual void Dump(CDumpContext& dc) const;
  44. #endif
  45.  
  46. // Generated message map functions
  47. protected:
  48.     //{{AFX_MSG(CMainDoc)
  49.     afx_msg void OnEditClearAll();
  50.     afx_msg void OnUpdateEditClearAll(CCmdUI* pCmdUI);
  51.     //}}AFX_MSG
  52.     DECLARE_MESSAGE_MAP()
  53. };
  54.  
  55. /////////////////////////////////////////////////////////////////////////////
  56.