How to draw attention to the current location of the mouse?

We have an application that hides desktop icons when the keyboard / mouse is idle for more than 15 seconds. When the user starts using any of these devices again, we would like to pay attention to the location of their mouse, which is very similar to how the CTRL key can be turned on to surround the mouse in Windows.

Are there any similar features or suggestions that I could use to accomplish such a task? I find working with the mouse in global mode (Anywhere on the desktop, not just on our application) is very difficult.

Thanks so much for the suggestions!

0
source share
1 answer

1) use the timer with an interval of 15 seconds;

2) save the current location of the mouse on the screen: Getting the mouse position in C #

3) when the timer has reached 15 seconds, check the location of the mouse again. if it is changed, update the current location of the mouse. if it hasn’t changed, draw something on the screen at the location of the mouse (and you also need to clear it): How to draw graphics in C # without a form

This is not the best choice, but if the mouse moves within 15 seconds, it is unlikely that it will return to its original location in 15 seconds.

+1
source

Source: https://habr.com/ru/post/952205/


All Articles