CopyCircle.cpp
资源名称:CAD.zip [点击查看]
上传用户:hehe2haha
上传日期:2013-08-16
资源大小:161k
文件大小:1k
源码类别:
CAD
开发平台:
Visual C++
- // CopyCircle.cpp: implementation of the CCopyCircle class.
- //
- //////////////////////////////////////////////////////////////////////
- #include "stdafx.h"
- #include "CopyCircle.h"
- #include "Circle.h"
- #include "WinApp.h"
- extern CWinApp g_theApp;
- //////////////////////////////////////////////////////////////////////
- // Construction/Destruction
- //////////////////////////////////////////////////////////////////////
- CCopyCircle::CCopyCircle()
- {
- }
- CCopyCircle::~CCopyCircle()
- {
- }
- CCopyCircle::CCopyCircle(CShape *Shape)
- {
- pShape = Shape;
- }
- CShape * CCopyCircle::Copy()
- {
- CArray<CShape*> *pArrayShape = &(g_theApp.m_DataBase.m_ArrayShape);
- CCircle *pCircle = new CCircle;
- memcpy(pCircle,pShape,sizeof(CCircle));
- pShape->isPick = FALSE;
- pCircle->isPick = TRUE;
- return pCircle;
- }