Add the mousedown and mouseup functions to the BASH wrapper.

This commit is contained in:
Bradlee Speice 2012-08-03 11:25:21 -04:00
parent 161eefde7c
commit 63a4783246

View File

@ -63,6 +63,40 @@ err ()
# Begin testing macros
#-------------------------------------------------------------------------------
#--- FUNCTION ----------------------------------------------------------------
# NAME: mousedown
# DESCRIPTION: Push the mouse button down, and leave it there.
# PARAMETERS:
# RETURNS:
#-------------------------------------------------------------------------------
mousedown ()
{
if [ -n "$1" ]; then
eval $CVAINPUT -s 'mousedown $1' >> $OUTFILE >> $OUTFILE
else
eval $CVAINPUT -s 'mousedown 1' >> $OUTFILE >> $OUTFILE
fi
return $?
} # ---------- end of function mousedown ----------
#--- FUNCTION ----------------------------------------------------------------
# NAME: mouseup
# DESCRIPTION: Release a mouse button
# PARAMETERS:
# RETURNS:
#-------------------------------------------------------------------------------
mouseup ()
{
if [ -n "$1" ]; then
eval $CVAINPUT -s 'mouseup $1' >> $OUTFILE >> $OUTFILE
else
eval $CVAINPUT -s 'mouseup 1' >> $OUTFILE >> $OUTFILE
fi
return $?
} # ---------- end of function mouseup ----------
#--- FUNCTION ----------------------------------------------------------------
# NAME: click
# DESCRIPTION: Click the mouse where it is currently located