开发者

Autohotkey - if left mouse button is not depressed

开发者 https://www.devze.com 2022-12-15 02:59 出处:网络
Looking to do something like this: if leftmou开发者_高级运维sebutton not depressed some other action

Looking to do something like this:

if leftmou开发者_高级运维sebutton not depressed
    some other action

Does anybody know how I would go about coding that?


try this

GetKeyState, state, LButton 

if state = U
    some other action


if !GetKeyState("LButton", "P")
    msgbox the left mouse button is not depressed.

GetKeyState() documentation


I don't know anything about autohotkey, but in the event the left mouse button is pressed down, set leftMouseButtonPressed = true, and when it is released, set leftMouseButtonPressed = false, and then in the if statement, just check if leftMouseButtonPressed.

0

精彩评论

暂无评论...
验证码 换一张
取 消