Get current cursor position

前端 未结 2 1287
谎友^
谎友^ 2020-11-27 16:19

I want to get the current mouse position of the window, and assign it to 2 variables x and y (co-ordinates relative to the window, not to the scree

2条回答
  •  猫巷女王i
    2020-11-27 16:22

    GetCursorPos() will return to you the x/y if you pass in a pointer to a POINT structure.

    Hiding the cursor can be done with ShowCursor().

提交回复
热议问题