I'm trying to push the "Step Frame" button on DVD Player's
little remote controller window via AppleScript.
I do have "System Prefs | Universal Access | Enable access for assistive
devices"
enabled, and have tried the following while DVD Player was running and in
"Pause":
* The "UI Element Inspector" shows the controller's window
to be "AXunknown", the same as the player's other windows,
so without a name, not sure how to get AS to focus on that window.
* "Automator" shows that only play/stop available, not "step".
* DVD Player has no hotkeys or menu options for 'step frame',
so I don't think I can attack the problem from that angle.
* I tried carefully positioning the remote controller window at
a fixed location on the screen, hoping I could send the "Step Frame"
button a mouse click event given an absolute X/Y location, eg:
tell application "System Events"
tell process "DVD Player"
click at {50,1010}
end tell
end tell
Result was no effect and no error. Not sure the syntax is right.
I then reverted to just trying to send a simple spacebar event
which should toggle play/pause, but this didn't work either:
tell application "System Events"
tell process "DVD Player"
keystroke space
end tell
end tell
I was unable to find good docs on the System Events stuff like
'click at' and 'keystroke'.. is there a good 'complete' ref manual
for all this?
* * *
I'm probably missing a lot, since I've never worked with AppleScript.
If there were just a way I could move the mouse to an X/Y position and
click the mouse button, regardless of the app, that would really solve
my problem. But even this seems hard or maybe not possible in AS.
Any help on either how to send a simple x/y mouse click event,
or how to specifically click the 'Step Frame' button in DVD Player
would be great.


|