佚名通过本文主要向大家介绍了atl34砂轮,atl方形动力电池,atl80.dll官方下载,atl71.dll一键修复,atl71.dll修复等相关知识,希望对您有所帮助,也希望大家支持linkedu.com www.linkedu.com
问题: 初学ATL,问一下鼠标问题
描述:
解决方案1:
描述:
我的程序中加入了鼠标事件,如:LRESULT OnMouseMove(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled),请问如何从参数中得到鼠标的位置POINT呢?谢谢
解决方案1:
WM_MOUSEMOVE
The WM_MOUSEMOVE message is posted to a window when the cursor moves. If the mouse is not captured, the message is posted to the window that contains the cursor. Otherwise, the message is posted to the window that has captured the mouse.
WM_MOUSEMOVE
fwKeys = wParam; // key flags
xPos = LOWORD(lParam); // horizontal position of cursor
yPos = HIWORD(lParam); // vertical position of cursor