home *** CD-ROM | disk | FTP | other *** search
- <!-- manual page source format generated by PolyglotMan v3.0.8+X.Org, -->
- <!-- available at http://polyglotman.sourceforge.net/ -->
-
- <html>
- <head>
- <title>"SDL_MouseButtonEvent"("3") manual page</title>
- </head>
- <body bgcolor='#efefef' text='black' link='blue' vlink='#551A8B' alink='red'>
- <a href='#toc'>Table of Contents</a><p>
-
- <h2><a name='sect0' href='#toc0'>Name</a></h2>
- SDL_MouseButtonEvent- Mouse button event structure
- <h2><a name='sect1' href='#toc1'>Structure Definition</a></h2>
- <p>
- <br>
- <pre>CWtypedef struct{
- Uint8 type;
- Uint8 button;
- Uint8 state;
- Uint16 x, y;
- } SDL_MouseButtonEvent;
- </pre><p>
-
- <h2><a name='sect2' href='#toc2'>Structure Data</a></h2>
-
- <dl>
-
- <dt><b>type</b> </dt>
- <dd><b>SDL_MOUSEBUTTONDOWN</b> or <b>SDL_MOUSEBUTTONUP</b> </dd>
-
- <dt><b>button</b> </dt>
- <dd>The
- mouse button index (SDL_BUTTON_LEFT, SDL_BUTTON_MIDDLE, SDL_BUTTON_RIGHT)
- </dd>
-
- <dt><b>state</b> </dt>
- <dd><b>SDL_PRESSED</b> or <b>SDL_RELEASED</b> </dd>
-
- <dt><b>x</b>, <b>y</b> </dt>
- <dd>The X/Y coordinates of the mouse
- at press/release time </dd>
- </dl>
-
- <h2><a name='sect3' href='#toc3'>Description</a></h2>
- <p>
- <b>SDL_MouseButtonEvent</b> is a member of the
- <i><b>SDL_Event</b></i> union and is used when an event of type <b>SDL_MOUSEBUTTONDOWN</b> or
- <b>SDL_MOUSEBUTTONUP</b> is reported. <p>
- When a mouse button press or release is detected
- then number of the button pressed (from 1 to 255, with 1 usually being
- the left button and 2 the right) is placed into <b>button</b>, the position of
- the mouse when this event occured is stored in the <b>x</b> and the <b>y</b> fields. Like
- <i><b>SDL_KeyboardEvent</b></i>, information on whether the event was a press or a release
- event is stored in both the <b>type</b> and <b>state</b> fields, but this should be obvious.
-
- <h2><a name='sect4' href='#toc4'>See Also</a></h2>
- <p>
- <i><b>SDL_Event</b></i>, <i><b>SDL_MouseMotionEvent</b></i>
- <!--
-
- <p>
-
- <hr><p>
- <a name='toc'><b>Table of Contents</b></a><p>
- <ul>
- <li><a name='toc0' href='#sect0'>Name</a></li>
- <li><a name='toc1' href='#sect1'>Structure Definition</a></li>
- <li><a name='toc2' href='#sect2'>Structure Data</a></li>
- <li><a name='toc3' href='#sect3'>Description</a></li>
- <li><a name='toc4' href='#sect4'>See Also</a></li>
- </ul>
- </body>
- </html>
-