Article 5D7FH Programmatically moving the mouse with the "xdotool"

Programmatically moving the mouse with the "xdotool"

by
PaulExordium
from LinuxQuestions.org on (#5D7FH)
After opening a "Mozilla Firefox" window, executing the following script will move the mouse correctly under Debian 9 but not under Debian 10. Any idea why?

Code:#!/bin/bash

winID=$(xdotool search --name "Mozilla Firefox")
echo $winID
xdotool getwindowname $winID

let x=1
let y=175
let i=1
let j=-1

for (( t=1; t<400; t++ ));
do
if [ $t -eq 100 ]; then let j=-$j; fi
if [ $t -eq 200 ]; then let i=-$i; fi
if [ $t -eq 300 ]; then let j=-$j; fi

let x=x+i
let y=y+j

xdotool mousemove --sync --window $winID $x $y
done

exitlatest?d=yIl2AUoC8zA latest?i=akxF_dYvA8E:Q9KY8nP1bj0:F7zBnMy latest?i=akxF_dYvA8E:Q9KY8nP1bj0:V_sGLiP latest?d=qj6IDK7rITs latest?i=akxF_dYvA8E:Q9KY8nP1bj0:gIN9vFwakxF_dYvA8E
External Content
Source RSS or Atom Feed
Feed Location https://feeds.feedburner.com/linuxquestions/latest
Feed Title LinuxQuestions.org
Feed Link https://www.linuxquestions.org/questions/
Reply 0 comments