<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!--NewPage-->
<HTML>
<HEAD>
<!-- Generated by javadoc (build 1.6.0_26) on Sun Jun 03 02:18:08 CEST 2012 -->
<TITLE>
Input (libgdx API)
</TITLE>
<META NAME="date" CONTENT="2012-06-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
<SCRIPT type="text/javascript">
function windowTitle()
{
if (location.href.indexOf('is-external=true') == -1) {
parent.document.title="Input (libgdx API)";
}
}
</SCRIPT>
<NOSCRIPT>
</NOSCRIPT>
</HEAD>
<BODY BGCOLOR="white" onload="windowTitle();">
<HR>
<!-- ========= START OF TOP NAVBAR ======= -->
<A NAME="navbar_top"><!-- --></A>
<A HREF="#skip-navbar_top" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_top_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
<TR ALIGN="center" VALIGN="top">
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview
</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package
</B></FONT></A> </TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class
</B></FONT> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/Input.html"><FONT CLASS="NavBarFont1"><B>Use
</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree
</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated
</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index
</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help
</B></FONT></A> </TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
libgdx API
<style>
body, td, th { font-family:Helvetica, Tahoma, Arial, sans-serif; font-size:10pt }
pre, code, tt { font-size:9pt; font-family:Lucida Console, Courier New, sans-serif }
h1, h2, h3, .FrameTitleFont, .FrameHeadingFont, .TableHeadingColor font { font-size:105%; font-weight:bold }
.TableHeadingColor { background:#EEEEFF; }
a { text-decoration:none }
a:hover { text-decoration:underline }
a:link, a:visited { color:blue }
table { border:0px }
.TableRowColor td:first-child { border-left:1px solid black }
.TableRowColor td { border:0px; border-bottom:1px solid black; border-right:1px solid black }
hr { border:0px; border-bottom:1px solid #333366; }
</style>
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../com/badlogic/gdx/Graphics.GraphicsType.html" title="enum in com.badlogic.gdx"><B>PREV CLASS
</B></A>
<A HREF="../../../com/badlogic/gdx/Input.Buttons.html" title="class in com.badlogic.gdx"><B>NEXT CLASS
</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../index.html?com/badlogic/gdx/Input.html" target="_top"><B>FRAMES
</B></A>
<A HREF="Input.html" target="_top"><B>NO FRAMES
</B></A>
<SCRIPT type="text/javascript">
<!--
if(window==top) {
document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
}
//-->
</SCRIPT>
<NOSCRIPT>
<A HREF="../../../allclasses-noframe.html"><B>All Classes
</B></A>
</NOSCRIPT>
</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
SUMMARY:
<A HREF="#nested_class_summary">NESTED
</A> |
FIELD
|
CONSTR
|
<A HREF="#method_summary">METHOD
</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL:
FIELD
|
CONSTR
|
<A HREF="#method_detail">METHOD
</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_top"></A>
<!-- ========= END OF TOP NAVBAR ========= -->
<HR>
<!-- ======== START OF CLASS DATA ======== -->
<H2>
<FONT SIZE="-1">
com.badlogic.gdx
</FONT>
<BR>
Interface Input
</H2>
<DL>
<DT><B>All Known Implementing Classes:
</B> <DD><A HREF="../../../com/badlogic/gdx/input/RemoteInput.html" title="class in com.badlogic.gdx.input">RemoteInput
</A></DD>
</DL>
<HR>
<DL>
<DT><PRE>public interface
<B>Input
</B></DL>
</PRE>
<P>
<p>
Interface to the input facilities. This allows to poll the state of the keyboard, touch screen and accelerometer. On the
desktop the touch screen is replaced by mouse input, the accelerometer is of course not available.
</p>
<p>
Additionally one can process events with an
<A HREF="../../../com/badlogic/gdx/InputProcessor.html" title="interface in com.badlogic.gdx"><CODE>InputProcessor
</CODE></A> with this module. You can set the InputProcessor via the
<A HREF="../../../com/badlogic/gdx/Input.html#setInputProcessor(com.badlogic.gdx.InputProcessor)"><CODE>setInputProcessor(InputProcessor)
</CODE></A> method. It will be called before the
<A HREF="../../../com/badlogic/gdx/ApplicationListener.html#render()"><CODE>ApplicationListener.render()
</CODE></A> method in
each frame.
</p>
<p>
Keyboard keys are translated to the constants in
<A HREF="../../../com/badlogic/gdx/Input.Keys.html" title="class in com.badlogic.gdx"><CODE>Input.Keys
</CODE></A> transparantely on all systems. Do not use system specific key
constants.
</p>
<p>
The class also offers methods to let the phone vibrate as well as getting compass readings.
</p>
<P>
<P>
<DL>
<DT><B>Author:
</B></DT>
<DD>mzechner
</DD>
</DL>
<HR>
<P>
<!-- ======== NESTED CLASS SUMMARY ======== -->
<A NAME="nested_class_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Nested Class Summary
</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static
class
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.Buttons.html" title="class in com.badlogic.gdx">Input.Buttons
</A></B></CODE>
<BR>
Mouse buttons.
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static
class
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.Keys.html" title="class in com.badlogic.gdx">Input.Keys
</A></B></CODE>
<BR>
Keys.
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static
class
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.Orientation.html" title="enum in com.badlogic.gdx">Input.Orientation
</A></B></CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static
class
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.Peripheral.html" title="enum in com.badlogic.gdx">Input.Peripheral
</A></B></CODE>
<BR>
Enumeration of potentially available peripherals.
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static
interface
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.TextInputListener.html" title="interface in com.badlogic.gdx">Input.TextInputListener
</A></B></CODE>
<BR>
Callback interface for
<A HREF="../../../com/badlogic/gdx/Input.html#getTextInput(com.badlogic.gdx.Input.TextInputListener, java.lang.String, java.lang.String)"><CODE>getTextInput(TextInputListener, String, String)
</CODE></A></TD>
</TR>
</TABLE>
<!-- ========== METHOD SUMMARY =========== -->
<A NAME="method_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Method Summary
</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#cancelVibrate()">cancelVibrate
</A></B>()
</CODE>
<BR>
Stops the vibrator
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> float
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#getAccelerometerX()">getAccelerometerX
</A></B>()
</CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> float
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#getAccelerometerY()">getAccelerometerY
</A></B>()
</CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> float
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#getAccelerometerZ()">getAccelerometerZ
</A></B>()
</CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> float
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#getAzimuth()">getAzimuth
</A></B>()
</CODE>
<BR>
The azimuth is the angle of the device's orientation around the z-axis.
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> long
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#getCurrentEventTime()">getCurrentEventTime
</A></B>()
</CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> int
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#getDeltaX()">getDeltaX
</A></B>()
</CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> int
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#getDeltaX(int)">getDeltaX
</A></B>(int
pointer)
</CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> int
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#getDeltaY()">getDeltaY
</A></B>()
</CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> int
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#getDeltaY(int)">getDeltaY
</A></B>(int
pointer)
</CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> <A HREF="../../../com/badlogic/gdx/InputProcessor.html" title="interface in com.badlogic.gdx">InputProcessor
</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#getInputProcessor()">getInputProcessor
</A></B>()
</CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> <A HREF="../../../com/badlogic/gdx/Input.Orientation.html" title="enum in com.badlogic.gdx">Input.Orientation
</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#getNativeOrientation()">getNativeOrientation
</A></B>()
</CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> float
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#getPitch()">getPitch
</A></B>()
</CODE>
<BR>
The pitch is the angle of the device's orientation around the x-axis.
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#getPlaceholderTextInput(com.badlogic.gdx.Input.TextInputListener, java.lang.String, java.lang.String)">getPlaceholderTextInput
</A></B>(
<A HREF="../../../com/badlogic/gdx/Input.TextInputListener.html" title="interface in com.badlogic.gdx">Input.TextInputListener
</A> listener,
java.lang.String
title,
java.lang.String
placeholder)
</CODE>
<BR>
System dependent method to input a string of text.
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> float
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#getRoll()">getRoll
</A></B>()
</CODE>
<BR>
The roll is the angle of the device's orientation around the y-axis.
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> int
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#getRotation()">getRotation
</A></B>()
</CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#getRotationMatrix(float[])">getRotationMatrix
</A></B>(float[]
matrix)
</CODE>
<BR>
Returns the rotation matrix describing the devices rotation as per
<a href="http://developer.android.com/reference/android/hardware/SensorManager.html#getRotationMatrix(float[], float[], float[], float[])">SensorManager#getRotationMatrix(float[], float[], float[], float[])
</a>.
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#getTextInput(com.badlogic.gdx.Input.TextInputListener, java.lang.String, java.lang.String)">getTextInput
</A></B>(
<A HREF="../../../com/badlogic/gdx/Input.TextInputListener.html" title="interface in com.badlogic.gdx">Input.TextInputListener
</A> listener,
java.lang.String
title,
java.lang.String
text)
</CODE>
<BR>
System dependent method to input a string of text.
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> int
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#getX()">getX
</A></B>()
</CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> int
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#getX(int)">getX
</A></B>(int
pointer)
</CODE>
<BR>
Returns the x coordinate in screen coordinates of the given pointer.
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> int
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#getY()">getY
</A></B>()
</CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> int
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#getY(int)">getY
</A></B>(int
pointer)
</CODE>
<BR>
Returns the y coordinate in screen coordinates of the given pointer.
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> boolean
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#isButtonPressed(int)">isButtonPressed
</A></B>(int
button)
</CODE>
<BR>
Whether a given button is pressed or not.
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> boolean
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#isCursorCatched()">isCursorCatched
</A></B>()
</CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> boolean
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#isKeyPressed(int)">isKeyPressed
</A></B>(int
key)
</CODE>
<BR>
Returns whether the key is pressed.
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> boolean
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#isPeripheralAvailable(com.badlogic.gdx.Input.Peripheral)">isPeripheralAvailable
</A></B>(
<A HREF="../../../com/badlogic/gdx/Input.Peripheral.html" title="enum in com.badlogic.gdx">Input.Peripheral
</A> peripheral)
</CODE>
<BR>
Queries whether a
<A HREF="../../../com/badlogic/gdx/Input.Peripheral.html" title="enum in com.badlogic.gdx"><CODE>Input.Peripheral
</CODE></A> is currently available.
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> boolean
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#isTouched()">isTouched
</A></B>()
</CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> boolean
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#isTouched(int)">isTouched
</A></B>(int
pointer)
</CODE>
<BR>
Whether the screen is currently touched by the pointer with the given index.
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> boolean
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#justTouched()">justTouched
</A></B>()
</CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#setCatchBackKey(boolean)">setCatchBackKey
</A></B>(boolean
catchBack)
</CODE>
<BR>
Sets whether the BACK button on Android should be caught.
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#setCatchMenuKey(boolean)">setCatchMenuKey
</A></B>(boolean
catchMenu)
</CODE>
<BR>
Sets whether the MENU button on Android should be caught.
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#setCursorCatched(boolean)">setCursorCatched
</A></B>(boolean
catched)
</CODE>
<BR>
Only viable on the desktop.
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#setCursorPosition(int, int)">setCursorPosition
</A></B>(int
x,
int
y)
</CODE>
<BR>
Only viable on the desktop.
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#setInputProcessor(com.badlogic.gdx.InputProcessor)">setInputProcessor
</A></B>(
<A HREF="../../../com/badlogic/gdx/InputProcessor.html" title="interface in com.badlogic.gdx">InputProcessor
</A> processor)
</CODE>
<BR>
Sets the
<A HREF="../../../com/badlogic/gdx/InputProcessor.html" title="interface in com.badlogic.gdx"><CODE>InputProcessor
</CODE></A> that will receive all touch and key input events.
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#setOnscreenKeyboardVisible(boolean)">setOnscreenKeyboardVisible
</A></B>(boolean
visible)
</CODE>
<BR>
Sets the on-screen keyboard visible if available.
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#vibrate(int)">vibrate
</A></B>(int
milliseconds)
</CODE>
<BR>
Vibrates for the given amount of time.
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void
</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/badlogic/gdx/Input.html#vibrate(long[], int)">vibrate
</A></B>(long[]
pattern,
int
repeat)
</CODE>
<BR>
Vibrate with a given pattern.
</TD>
</TR>
</TABLE>
<P>
<!-- ============ METHOD DETAIL ========== -->
<A NAME="method_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Method Detail
</B></FONT></TH>
</TR>
</TABLE>
<A NAME="getAccelerometerX()"><!-- --></A><H3>
getAccelerometerX
</H3>
<PRE>
float
<B>getAccelerometerX
</B>()
</PRE>
<DL>
<DD><DL>
<DT><B>Returns:
</B><DD>The value of the accelerometer on its x-axis. ranges between [-10,10].
</DL>
</DD>
</DL>
<HR>
<A NAME="getAccelerometerY()"><!-- --></A><H3>
getAccelerometerY
</H3>
<PRE>
float
<B>getAccelerometerY
</B>()
</PRE>
<DL>
<DD><DL>
<DT><B>Returns:
</B><DD>The value of the accelerometer on its y-axis. ranges between [-10,10].
</DL>
</DD>
</DL>
<HR>
<A NAME="getAccelerometerZ()"><!-- --></A><H3>
getAccelerometerZ
</H3>
<PRE>
float
<B>getAccelerometerZ
</B>()
</PRE>
<DL>
<DD><DL>
<DT><B>Returns:
</B><DD>The value of the accelerometer on its y-axis. ranges between [-10,10].
</DL>
</DD>
</DL>
<HR>
<A NAME="getX()"><!-- --></A><H3>
getX
</H3>
<PRE>
int
<B>getX
</B>()
</PRE>
<DL>
<DD><DL>
<DT><B>Returns:
</B><DD>the last touch x coordinate in screen coordinates. The screen origin is the top left corner.
</DL>
</DD>
</DL>
<HR>
<A NAME="getX(int)"><!-- --></A><H3>
getX
</H3>
<PRE>
int
<B>getX
</B>(int
pointer)
</PRE>
<DL>
<DD>Returns the x coordinate in screen coordinates of the given pointer. Pointers are indexed from 0 to n. The pointer id
identifies the order in which the fingers went down on the screen, e.g. 0 is the first finger, 1 is the second and so on.
When two fingers are touched down and the first one is lifted the second one keeps its index. If another finger is placed on
the touch screen the first free index will be used.
<P>
<DD><DL>
<DT><B>Parameters:
</B><DD><CODE>pointer
</CODE> - the pointer id.
<DT><B>Returns:
</B><DD>the x coordinate
</DL>
</DD>
</DL>
<HR>
<A NAME="getDeltaX()"><!-- --></A><H3>
getDeltaX
</H3>
<PRE>
int
<B>getDeltaX
</B>()
</PRE>
<DL>
<DD><DL>
<DT><B>Returns:
</B><DD>the different between the current pointer location and the last pointer location on the x-axis.
</DL>
</DD>
</DL>
<HR>
<A NAME="getDeltaX(int)"><!-- --></A><H3>
getDeltaX
</H3>
<PRE>
int
<B>getDeltaX
</B>(int
pointer)
</PRE>
<DL>
<DD><DL>
<DT><B>Returns:
</B><DD>the different between the current pointer location and the last pointer location on the x-axis.
</DL>
</DD>
</DL>
<HR>
<A NAME="getY()"><!-- --></A><H3>
getY
</H3>
<PRE>
int
<B>getY
</B>()
</PRE>
<DL>
<DD><DL>
<DT><B>Returns:
</B><DD>the last touch y coordinate in screen coordinates. The screen origin is the top left corner.
</DL>
</DD>
</DL>
<HR>
<A NAME="getY(int)"><!-- --></A><H3>
getY
</H3>
<PRE>
int
<B>getY
</B>(int
pointer)
</PRE>
<DL>
<DD>Returns the y coordinate in screen coordinates of the given pointer. Pointers are indexed from 0 to n. The pointer id
identifies the order in which the fingers went down on the screen, e.g. 0 is the first finger, 1 is the second and so on.
When two fingers are touched down and the first one is lifted the second one keeps its index. If another finger is placed on
the touch screen the first free index will be used.
<P>
<DD><DL>
<DT><B>Parameters:
</B><DD><CODE>pointer
</CODE> - the pointer id.
<DT><B>Returns:
</B><DD>the y coordinate
</DL>
</DD>
</DL>
<HR>
<A NAME="getDeltaY()"><!-- --></A><H3>
getDeltaY
</H3>
<PRE>
int
<B>getDeltaY
</B>()
</PRE>
<DL>
<DD><DL>
<DT><B>Returns:
</B><DD>the different between the current pointer location and the last pointer location on the y-axis.
</DL>
</DD>
</DL>
<HR>
<A NAME="getDeltaY(int)"><!-- --></A><H3>
getDeltaY
</H3>
<PRE>
int
<B>getDeltaY
</B>(int
pointer)
</PRE>
<DL>
<DD><DL>
<DT><B>Returns:
</B><DD>the different between the current pointer location and the last pointer location on the y-axis.
</DL>
</DD>
</DL>
<HR>
<A NAME="isTouched()"><!-- --></A><H3>
isTouched
</H3>
<PRE>
boolean
<B>isTouched
</B>()
</PRE>
<DL>
<DD><DL>
<DT><B>Returns:
</B><DD>whether the screen is currently touched.
</DL>
</DD>
</DL>
<HR>
<A NAME="justTouched()"><!-- --></A><H3>
justTouched
</H3>
<PRE>
boolean
<B>justTouched
</B>()
</PRE>
<DL>
<DD><DL>
<DT><B>Returns:
</B><DD>whether a new touch down event just occured.
</DL>
</DD>
</DL>
<HR>
<A NAME="isTouched(int)"><!-- --></A><H3>
isTouched
</H3>
<PRE>
boolean
<B>isTouched
</B>(int
pointer)
</PRE>
<DL>
<DD>Whether the screen is currently touched by the pointer with the given index. Pointers are indexed from 0 to n. The pointer
id identifies the order in which the fingers went down on the screen, e.g. 0 is the first finger, 1 is the second and so on.
When two fingers are touched down and the first one is lifted the second one keeps its index. If another finger is placed on
the touch screen the first free index will be used.
<P>
<DD><DL>
<DT><B>Parameters:
</B><DD><CODE>pointer
</CODE> - the pointer
<DT><B>Returns:
</B><DD>whether the screen is touched by the pointer
</DL>
</DD>
</DL>
<HR>
<A NAME="isButtonPressed(int)"><!-- --></A><H3>
isButtonPressed
</H3>
<PRE>
boolean
<B>isButtonPressed
</B>(int
button)
</PRE>
<DL>
<DD>Whether a given button is pressed or not. Button constants can be found in
<A HREF="../../../com/badlogic/gdx/Input.Buttons.html" title="class in com.badlogic.gdx"><CODE>Input.Buttons
</CODE></A>. On Android only the Button#LEFT
constant is meaningful.
<P>
<DD><DL>
<DT><B>Parameters:
</B><DD><CODE>button
</CODE> - the button to check.
<DT><B>Returns:
</B><DD>whether the button is down or not.
</DL>
</DD>
</DL>
<HR>
<A NAME="isKeyPressed(int)"><!-- --></A><H3>
isKeyPressed
</H3>
<PRE>
boolean
<B>isKeyPressed
</B>(int
key)
</PRE>
<DL>
<DD>Returns whether the key is pressed.
<P>
<DD><DL>
<DT><B>Parameters:
</B><DD><CODE>key
</CODE> - The key code as found in
<A HREF="../../../com/badlogic/gdx/Input.Keys.html" title="class in com.badlogic.gdx"><CODE>Input.Keys
</CODE></A>.
<DT><B>Returns:
</B><DD>true or false.
</DL>
</DD>
</DL>
<HR>
<A NAME="getTextInput(com.badlogic.gdx.Input.TextInputListener, java.lang.String, java.lang.String)"><!-- --></A><H3>
getTextInput
</H3>
<PRE>
void
<B>getTextInput
</B>(
<A HREF="../../../com/badlogic/gdx/Input.TextInputListener.html" title="interface in com.badlogic.gdx">Input.TextInputListener
</A> listener,
java.lang.String
title,
java.lang.String
text)
</PRE>
<DL>
<DD>System dependent method to input a string of text. A dialog box will be created with the given title and the given text as a
message for the user. Once the dialog has been closed the provided
<A HREF="../../../com/badlogic/gdx/Input.TextInputListener.html" title="interface in com.badlogic.gdx"><CODE>Input.TextInputListener
</CODE></A> will be called on the rendering thread.
<P>
<DD><DL>
<DT><B>Parameters:
</B><DD><CODE>listener
</CODE> - The TextInputListener.
<DD><CODE>title
</CODE> - The title of the text input dialog.
<DD><CODE>text
</CODE> - The message presented to the user.
</DL>
</DD>
</DL>
<HR>
<A NAME="getPlaceholderTextInput(com.badlogic.gdx.Input.TextInputListener, java.lang.String, java.lang.String)"><!-- --></A><H3>
getPlaceholderTextInput
</H3>
<PRE>
void
<B>getPlaceholderTextInput
</B>(
<A HREF="../../../com/badlogic/gdx/Input.TextInputListener.html" title="interface in com.badlogic.gdx">Input.TextInputListener
</A> listener,
java.lang.String
title,
java.lang.String
placeholder)
</PRE>
<DL>
<DD>System dependent method to input a string of text. A dialog box will be created with the given title and the given text as a
hint message for the user. Once the dialog has been closed the provided
<A HREF="../../../com/badlogic/gdx/Input.TextInputListener.html" title="interface in com.badlogic.gdx"><CODE>Input.TextInputListener
</CODE></A> will be called on the
rendering thread.
<P>
<DD><DL>
<DT><B>Parameters:
</B><DD><CODE>listener
</CODE> - The TextInputListener.
<DD><CODE>title
</CODE> - The title of the text input dialog.
<DD><CODE>text
</CODE> - The placeholder text presented to the user.
</DL>
</DD>
</DL>
<HR>
<A NAME="setOnscreenKeyboardVisible(boolean)"><!-- --></A><H3>
setOnscreenKeyboardVisible
</H3>
<PRE>
void
<B>setOnscreenKeyboardVisible
</B>(boolean
visible)
</PRE>
<DL>
<DD>Sets the on-screen keyboard visible if available.
<P>
<DD><DL>
<DT><B>Parameters:
</B><DD><CODE>visible
</CODE> - visible or not
</DL>
</DD>
</DL>
<HR>
<A NAME="vibrate(int)"><!-- --></A><H3>
vibrate
</H3>
<PRE>
void
<B>vibrate
</B>(int
milliseconds)
</PRE>
<DL>
<DD>Vibrates for the given amount of time. Note that you'll need the permission
<code> <uses-permission android:name="android.permission.VIBRATE" /></code> in your manifest file in order for this to work.
<P>
<DD><DL>
<DT><B>Parameters:
</B><DD><CODE>milliseconds
</CODE> - the number of milliseconds to vibrate.
</DL>
</DD>
</DL>
<HR>
<A NAME="vibrate(long[], int)"><!-- --></A><H3>
vibrate
</H3>
<PRE>
void
<B>vibrate
</B>(long[]
pattern,
int
repeat)
</PRE>
<DL>
<DD>Vibrate with a given pattern. Pass in an array of ints that are the times at which to turn on or off the vibrator. The first
one is how long to wait before turning it on, and then after that it alternates. If you want to repeat, pass the index into
the pattern at which to start the repeat.
<P>
<DD><DL>
<DT><B>Parameters:
</B><DD><CODE>pattern
</CODE> - an array of longs of times to turn the vibrator on or off.
<DD><CODE>repeat
</CODE> - the index into pattern at which to repeat, or -1 if you don't want to repeat.
</DL>
</DD>
</DL>
<HR>
<A NAME="cancelVibrate()"><!-- --></A><H3>
cancelVibrate
</H3>
<PRE>
void
<B>cancelVibrate
</B>()
</PRE>
<DL>
<DD>Stops the vibrator
<P>
<DD><DL>
</DL>
</DD>
</DL>
<HR>
<A NAME="getAzimuth()"><!-- --></A><H3>
getAzimuth
</H3>
<PRE>
float
<B>getAzimuth
</B>()
</PRE>
<DL>
<DD>The azimuth is the angle of the device's orientation around the z-axis. The positive z-axis points towards the earths
center.
<P>
<DD><DL>
<DT><B>Returns:
</B><DD>the azimuth in degrees
<DT><B>See Also:
</B><DD><a
href="http://developer.android.com/reference/android/hardware/SensorManager.html#getRotationMatrix(float[], float[], float[], float[])">http://developer.android.com/reference/android/hardware/SensorManager.html#getRotationMatrix(float[], float[], float[], float[])
</a></DL>
</DD>
</DL>
<HR>
<A NAME="getPitch()"><!-- --></A><H3>
getPitch
</H3>
<PRE>
float
<B>getPitch
</B>()
</PRE>
<DL>
<DD>The pitch is the angle of the device's orientation around the x-axis. The positive x-axis roughly points to the west and is
orthogonal to the z- and y-axis.
<P>
<DD><DL>
<DT><B>Returns:
</B><DD>the pitch in degrees
<DT><B>See Also:
</B><DD><a
href="http://developer.android.com/reference/android/hardware/SensorManager.html#getRotationMatrix(float[], float[], float[], float[])">http://developer.android.com/reference/android/hardware/SensorManager.html#getRotationMatrix(float[], float[], float[], float[])
</a></DL>
</DD>
</DL>
<HR>
<A NAME="getRoll()"><!-- --></A><H3>
getRoll
</H3>
<PRE>
float
<B>getRoll
</B>()
</PRE>
<DL>
<DD>The roll is the angle of the device's orientation around the y-axis. The positive y-axis points to the magnetic north pole
of the earth.
<P>
<DD><DL>
<DT><B>Returns:
</B><DD>the roll in degrees
<DT><B>See Also:
</B><DD><a
href="http://developer.android.com/reference/android/hardware/SensorManager.html#getRotationMatrix(float[], float[], float[], float[])">http://developer.android.com/reference/android/hardware/SensorManager.html#getRotationMatrix(float[], float[], float[], float[])
</a></DL>
</DD>
</DL>
<HR>
<A NAME="getRotationMatrix(float[])"><!-- --></A><H3>
getRotationMatrix
</H3>
<PRE>
void
<B>getRotationMatrix
</B>(float[]
matrix)
</PRE>
<DL>
<DD>Returns the rotation matrix describing the devices rotation as per
<a href="http://developer.android.com/reference/android/hardware/SensorManager.html#getRotationMatrix(float[], float[], float[], float[])">SensorManager#getRotationMatrix(float[], float[], float[], float[])
</a>.
Does not manipulate the matrix if the platform does not have an accelerometer.
<P>
<DD><DL>
<DT><B>Parameters:
</B><DD><CODE>matrix
</CODE> -
</DL>
</DD>
</DL>
<HR>
<A NAME="getCurrentEventTime()"><!-- --></A><H3>
getCurrentEventTime
</H3>
<PRE>
long
<B>getCurrentEventTime
</B>()
</PRE>
<DL>
<DD><DL>
<DT><B>Returns:
</B><DD>the time of the event currently reported to the
<A HREF="../../../com/badlogic/gdx/InputProcessor.html" title="interface in com.badlogic.gdx"><CODE>InputProcessor
</CODE></A>.
</DL>
</DD>
</DL>
<HR>
<A NAME="setCatchBackKey(boolean)"><!-- --></A><H3>
setCatchBackKey
</H3>
<PRE>
void
<B>setCatchBackKey
</B>(boolean
catchBack)
</PRE>
<DL>
<DD>Sets whether the BACK button on Android should be caught. This will prevent the app from being paused. Will have no effect
on the desktop.
<P>
<DD><DL>
<DT><B>Parameters:
</B><DD><CODE>catchBack
</CODE> - whether to catch the back button
</DL>
</DD>
</DL>
<HR>
<A NAME="setCatchMenuKey(boolean)"><!-- --></A><H3>
setCatchMenuKey
</H3>
<PRE>
void
<B>setCatchMenuKey
</B>(boolean
catchMenu)
</PRE>
<DL>
<DD>Sets whether the MENU button on Android should be caught. This will prevent the onscreen keyboard to show up. Will have no
effect on the desktop.
<P>
<DD><DL>
<DT><B>Parameters:
</B><DD><CODE>catchMenu
</CODE> - whether to catch the back button
</DL>
</DD>
</DL>
<HR>
<A NAME="setInputProcessor(com.badlogic.gdx.InputProcessor)"><!-- --></A><H3>
setInputProcessor
</H3>
<PRE>
void
<B>setInputProcessor
</B>(
<A HREF="../../../com/badlogic/gdx/InputProcessor.html" title="interface in com.badlogic.gdx">InputProcessor
</A> processor)
</PRE>
<DL>
<DD>Sets the
<A HREF="../../../com/badlogic/gdx/InputProcessor.html" title="interface in com.badlogic.gdx"><CODE>InputProcessor
</CODE></A> that will receive all touch and key input events. It will be called before the
<A HREF="../../../com/badlogic/gdx/ApplicationListener.html#render()"><CODE>ApplicationListener.render()
</CODE></A> method each frame.
<P>
<DD><DL>
<DT><B>Parameters:
</B><DD><CODE>processor
</CODE> - the InputProcessor
</DL>
</DD>
</DL>
<HR>
<A NAME="getInputProcessor()"><!-- --></A><H3>
getInputProcessor
</H3>
<PRE>
<A HREF="../../../com/badlogic/gdx/InputProcessor.html" title="interface in com.badlogic.gdx">InputProcessor
</A> <B>getInputProcessor
</B>()
</PRE>
<DL>
<DD><DL>
<DT><B>Returns:
</B><DD>the currently set
<A HREF="../../../com/badlogic/gdx/InputProcessor.html" title="interface in com.badlogic.gdx"><CODE>InputProcessor
</CODE></A> or null.
</DL>
</DD>
</DL>
<HR>
<A NAME="isPeripheralAvailable(com.badlogic.gdx.Input.Peripheral)"><!-- --></A><H3>
isPeripheralAvailable
</H3>
<PRE>
boolean
<B>isPeripheralAvailable
</B>(
<A HREF="../../../com/badlogic/gdx/Input.Peripheral.html" title="enum in com.badlogic.gdx">Input.Peripheral
</A> peripheral)
</PRE>
<DL>
<DD>Queries whether a
<A HREF="../../../com/badlogic/gdx/Input.Peripheral.html" title="enum in com.badlogic.gdx"><CODE>Input.Peripheral
</CODE></A> is currently available. In case of Android and the
<A HREF="../../../com/badlogic/gdx/Input.Peripheral.html#HardwareKeyboard"><CODE>Input.Peripheral.HardwareKeyboard
</CODE></A>
this returns the whether the keyboard is currently slid out or not.
<P>
<DD><DL>
<DT><B>Parameters:
</B><DD><CODE>peripheral
</CODE> - the
<A HREF="../../../com/badlogic/gdx/Input.Peripheral.html" title="enum in com.badlogic.gdx"><CODE>Input.Peripheral
</CODE></A>
<DT><B>Returns:
</B><DD>whether the peripheral is available or not.
</DL>
</DD>
</DL>
<HR>
<A NAME="getRotation()"><!-- --></A><H3>
getRotation
</H3>
<PRE>
int
<B>getRotation
</B>()
</PRE>
<DL>
<DD><DL>
<DT><B>Returns:
</B><DD>the rotation of the device with respect to its native orientation.
</DL>
</DD>
</DL>
<HR>
<A NAME="getNativeOrientation()"><!-- --></A><H3>
getNativeOrientation
</H3>
<PRE>
<A HREF="../../../com/badlogic/gdx/Input.Orientation.html" title="enum in com.badlogic.gdx">Input.Orientation
</A> <B>getNativeOrientation
</B>()
</PRE>
<DL>
<DD><DL>
<DT><B>Returns:
</B><DD>the native orientation of the device.
</DL>
</DD>
</DL>
<HR>
<A NAME="setCursorCatched(boolean)"><!-- --></A><H3>
setCursorCatched
</H3>
<PRE>
void
<B>setCursorCatched
</B>(boolean
catched)
</PRE>
<DL>
<DD>Only viable on the desktop. Will confine the mouse cursor location to the window and hide the mouse cursor.
<P>
<DD><DL>
<DT><B>Parameters:
</B><DD><CODE>catched
</CODE> - whether to catch or not to catch the mouse cursor
</DL>
</DD>
</DL>
<HR>
<A NAME="isCursorCatched()"><!-- --></A><H3>
isCursorCatched
</H3>
<PRE>
boolean
<B>isCursorCatched
</B>()
</PRE>
<DL>
<DD><DL>
<DT><B>Returns:
</B><DD>whether the mouse cursor is catched.
</DL>
</DD>
</DL>
<HR>
<A NAME="setCursorPosition(int, int)"><!-- --></A><H3>
setCursorPosition
</H3>
<PRE>
void
<B>setCursorPosition
</B>(int
x,
int
y)
</PRE>
<DL>
<DD>Only viable on the desktop. Will set the mouse cursor location to the given window coordinates (origin top-left corner).
<P>
<DD><DL>
<DT><B>Parameters:
</B><DD><CODE>x
</CODE> - the x-position
<DD><CODE>y
</CODE> - the y-position
</DL>
</DD>
</DL>
<!-- ========= END OF CLASS DATA ========= -->
<HR>
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<A NAME="navbar_bottom"><!-- --></A>
<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
<TR ALIGN="center" VALIGN="top">
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview
</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package
</B></FONT></A> </TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class
</B></FONT> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/Input.html"><FONT CLASS="NavBarFont1"><B>Use
</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree
</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated
</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index
</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help
</B></FONT></A> </TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
libgdx API
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../com/badlogic/gdx/Graphics.GraphicsType.html" title="enum in com.badlogic.gdx"><B>PREV CLASS
</B></A>
<A HREF="../../../com/badlogic/gdx/Input.Buttons.html" title="class in com.badlogic.gdx"><B>NEXT CLASS
</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../index.html?com/badlogic/gdx/Input.html" target="_top"><B>FRAMES
</B></A>
<A HREF="Input.html" target="_top"><B>NO FRAMES
</B></A>
<SCRIPT type="text/javascript">
<!--
if(window==top) {
document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
}
//-->
</SCRIPT>
<NOSCRIPT>
<A HREF="../../../allclasses-noframe.html"><B>All Classes
</B></A>
</NOSCRIPT>
</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
SUMMARY:
<A HREF="#nested_class_summary">NESTED
</A> |
FIELD
|
CONSTR
|
<A HREF="#method_summary">METHOD
</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL:
FIELD
|
CONSTR
|
<A HREF="#method_detail">METHOD
</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_bottom"></A>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<HR>
<div style="font-size:9pt"><i>
Copyright 2010 Mario Zechner (contact@badlogicgames.com), Nathan Sweet (admin@esotericsoftware.com)
</i></div>
</BODY>
</HTML>