void CGeometryView::OnLButtonDown(UINT nFlags, CPoint point)
{
// TODO: 在此添加消息处理程序代码和/或调用默认值
if( start == NULL )
start = new MPoint(point.x, point.y);
else{ // 生成起点对象
points.AddTail( new MPoint(point.x, point.y) ); int n = points.GetCount(); // 已输入点的个数 CString strMsg;
strMsg.Format(_T("%d"),n);
AfxMessageBox(_T("shaungji3 ")+strMsg); }
// 添加到点缓存区
Invalidate( ); CView::OnLButtonDown(nFlags, point);
}CObList points在class CGeometryView : public CView中声明
{
// TODO: 在此添加消息处理程序代码和/或调用默认值
if( start == NULL )
start = new MPoint(point.x, point.y);
else{ // 生成起点对象
points.AddTail( new MPoint(point.x, point.y) ); int n = points.GetCount(); // 已输入点的个数 CString strMsg;
strMsg.Format(_T("%d"),n);
AfxMessageBox(_T("shaungji3 ")+strMsg); }
// 添加到点缓存区
Invalidate( ); CView::OnLButtonDown(nFlags, point);
}CObList points在class CGeometryView : public CView中声明
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货