void CFrameView::OnLButtonUp(UINT nFlags, CPoint point){
if (!gl3d.bCanMove)
{
AfxMessageBox("请先归位后在拖动");
return;
}
}
void CFrameView::OnRButtonDown(UINT nFlags, CPoint point) {
gl3d.bCanMove = false;
}
void CLineView::OnBTBeginDrag()
{
// TODO: Add your control notification handler code here
CFrameView* pView = (CFrameView*)GetFrameView();
// 停止旋转
if (pView->m_bRotate)
{
KillTimer(1);
pView->m_bRotate = false;
}
// 旋转至某角度
gl3d.m_RotateAngle = 15.0f;
gl3d.bCanMove = true;
// 刷新视图
GetFrameView()->InvalidateRect(NULL,FALSE);
}