Reputation:
Hi i have a problem with my mouse, when i want to drag stuff or highlight text, i hold my left click down but my mouse sometimes releases the click briefly and then reclick so that i lose the stuff i was dragging. So i would like to make an autohotkey script that would stop it.
the way i see it, it would do something like: when the clic is pressed the script forces the clic down for like 100 ms and then releases it, but if i hold the clic down it would refresh the timer indefinitely so that if my mouse release the clic for less than 100 ms it would still holding it down.
I don't know if this is possible so any help would be great. thanks for your time.
Upvotes: 1
Views: 1047
Reputation: 1353
Perhaps this will help.
~LButton:: Loop { Sleep, 100 if (!GetKeyState("LButton", "P")) { SendInput, {LButton Up} return } } $Lbutton Up:: return
Upvotes: 1