ll_libload user, "user32.dll"
ll_getproc mouse_event, "mouse_event", user
#module
#deffunc click int, int
mref no, 0 : mref upflg, 1
prm = 2 << (no >= 1 + (no >= 2) * 2) * (upflg ! 0 + 1), 0, 0, 0, 0
ll_callfunc prm, 5, mouse_event@
return
#global
pos 10, 10 : button "終了", *exit
wait 100
// ボタン上へ移動
ginfo 0 : mp = prmx, prmy
ginfo 3
x = mp.0, prmx - winx + 20
y = mp.1, prmy - winy + 20
repeat 20, 1
wait 10
mouse x - (x.0 - x.1 * cnt / 20), y - (y.0 - y.1 * cnt / 20)
loop
// ボタン押下
wait 50
click 0
wait 50
click 0, 1
stop
*exit
|