|
// cntritem.h : interface of the CDrawItem class
//
// This is a part of the Microsoft Foundation Classes C++ library.
// Copyright (C) 1992-1998 Microsoft Corporation
// All rights reserved.
//
// This source code is only intended as a supplement to the
// Microsoft Foundation Classes Reference and related
// electronic documentation provided with the library.
// See these sources for detailed information regarding the
// Microsoft Foundation Classes product.
class CDrawDoc;
class CDrawView;
class CDrawItem : public COleClientItem
{
DECLARE_SERIAL(CDrawItem)
// Constructors
public:
CDrawItem(CDrawDoc* pContainer = NULL, CDrawOleObj* pDrawObj = NULL);
// Note: pContainer is allowed to be NULL to enable IMPLEMENT_SERIALIZE
// IMPLEMENT_SERIALIZE requires the class have a constructor with
// zero arguments. Normally, OLE items are constructed with a
// non-NULL document pointer.
// Attributes
public:
CDrawDoc* GetDocument()
{ return (CDrawDoc*)COleClientItem::GetDocument(); }
CDrawView* GetActiveView()
{ return (CDrawView*)COleClientItem::GetActiveView(); }
CDrawOleObj* m_pDrawObj; // back pointer to OLE draw object
// Operations
BOOL UpdateExtent();
// Implementation
public:
~CDrawItem();
#ifdef _DEBUG
virtual void AssertValid() const;
virtual void Dump(CDumpContext& dc) const;
#endif
virtual void Serialize(CArchive& ar);
virtual void OnGetItemPosition(CRect& rPosition);
protected:
virtual void OnChange(OLE_NOTIFICATION wNotification, DWORD dwParam);
virtual BOOL OnChangeItemPosition(const CRect& rectPos);
virtual void OnDeactivateUI(BOOL bUndoable);
virtual void OnActivate();
};
/////////////////////////////////////////////////////////////////////////////
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.
This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.
A list of licenses authors might use can be found here
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.