Esempio n. 1
0
void CotMapCtrl::OnMouseMove(UINT nFlags, CPoint point)
{
	double dx,dy;
	m_pGeomap->GetDisplay()->GetDisplayTransformation().ConvertDisplayToGeo(point.x,point.y,dx,dy);

	long button =0;
	if(nFlags&MK_LBUTTON)
	{
		button =1;
	}
	else if(nFlags & MK_RBUTTON)
	{
		button =2;
	}
	else if(nFlags & MK_MBUTTON)
	{
		button =3;
	}
	else
	{
		button =0;
	}
	
	//触发移动事件
	FireMouseMove(button,0,point.x,point.y,dx,dy);
	
	if(m_pCurAction)
	{
		m_pCurAction->MouseMoveEvent(nFlags,point);
	}

	COleControl::OnMouseMove(nFlags, point);
}
Esempio n. 2
0
void AGScreen::MouseMove (int x, int y)

//	MouseMove
//
//	Handle mouse move

	{
	//	Convert to screen coordinates

	POINT pt;
	pt.x = x - m_rcRect.left;
	pt.y = y - m_rcRect.top;

	FireMouseMove(pt);
	}