The Click action simulates a user clicking on a target page element.
The script stores the following information when a click is recorded.
Each click requires a target locator to specify which element the agent is to simulate a click on.
When the agent is to fire a
dblclick event within an element, this value is set to
The Recorder captures the x,y coordinates of the position where the user clicked in relation to the top left corner of the target element.
Because of technical limitations, these coordinates are set to
0,0 when the agent fires the mouse events associated with the action.
clientWidth and clientHeight
When the user interacts with Flash content on a page, the Recorder captures the width and height of the browser window used for recording. The
clientHeight values are used to resize the playback window to match the size used for recording before performing the Click action. This makes for more reliable playback for Flash interactions against applications that scale to fit the window size.
These values are only supported in the Firefox agent. The other agents ignore them and no window resize takes place.
The values are not captured for clicks that take place on non-Flash page components.
Browser Agent implementation of the Click action
For information on mouse events, refer to http://www.quirksmode.org/js/events_mouse.html.
Locate the target element.
Locate the coordinate position within that element.
Perform the click.
- If the script is set to perform a double-click, fire the
- If the script is not set to perform a double-click, execute a
.click()on the target element.
- Fire the