<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1"> <title>Crystal Space 1.2.1: _csKeyModifiers Struct Reference (Crystal Space 1.2.1 Public API Reference)</title> <link href="tabs.css" rel="stylesheet" type="text/css"> <link href="doxygen.css" rel="stylesheet" type="text/css"> </head><body> <table border="0" cellpadding="0" cellspacing="0" width="100%" class="head"> <tr height="59"> <td class="head" width="202" valign="bottom" style="padding-left:0;"><a href="http://www.crystalspace3d.org/"><img src="csblur.png" width="236" height="59" alt="CrystalSpace" border="0"></a></td> <td class="head"><h2>Public API Reference</h2></td> </tr> <tr height="11"> <td colspan="2" class="headshadow" valign="top" style="padding-left:0;"><img src="csblurb.png" width="236" height="11" alt="" border="0"></td> </tr> </table> <div class="content"> <!-- Generated by Doxygen 1.5.3 --> <div class="tabs"> <ul> <li><a href="index.html"><span>Main Page</span></a></li> <li><a href="modules.html"><span>Modules</span></a></li> <li><a href="namespaces.html"><span>Namespaces</span></a></li> <li class="current"><a href="classes.html"><span>Classes</span></a></li> <li><a href="files.html"><span>Files</span></a></li> <li><a href="pages.html"><span>Related Pages</span></a></li> </ul> </div> <div class="tabs"> <ul> <li><a href="classes.html"><span>Alphabetical List</span></a></li> <li><a href="annotated.html"><span>Class List</span></a></li> <li><a href="hierarchy.html"><span>Class Hierarchy</span></a></li> <li><a href="functions.html"><span>Class Members</span></a></li> </ul> </div> <h1>_csKeyModifiers Struct Reference</h1><!-- doxytag: class="_csKeyModifiers" -->Flags for all currently pressed modifiers. <a href="#_details">More...</a> <p> <code>#include <<a class="el" href="evdefs_8h-source.html">iutil/evdefs.h</a>></code> <p> <p> <a href="struct__csKeyModifiers-members.html">List of all members.</a><table border="0" cellpadding="0" cellspacing="0"> <tr><td></td></tr> <tr><td colspan="2"><br><h2>Public Attributes</h2></td></tr> <tr><td class="memItemLeft" nowrap align="right" valign="top">unsigned int </td><td class="memItemRight" valign="bottom"><a class="el" href="struct__csKeyModifiers.html#41ed4c2a59343849150ffe2e0e503dac">modifiers</a> [csKeyModifierTypeLast]</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Bitmasks for different modifiers. <a href="#41ed4c2a59343849150ffe2e0e503dac"></a><br></td></tr> </table> <hr><a name="_details"></a><h2>Detailed Description</h2> Flags for all currently pressed modifiers. <p>Definition at line <a class="el" href="evdefs_8h-source.html#l00136">136</a> of file <a class="el" href="evdefs_8h-source.html">evdefs.h</a>.</p> <hr><h2>Member Data Documentation</h2> <a class="anchor" name="41ed4c2a59343849150ffe2e0e503dac"></a><!-- doxytag: member="_csKeyModifiers::modifiers" ref="41ed4c2a59343849150ffe2e0e503dac" args="[csKeyModifierTypeLast]" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">unsigned int <a class="el" href="struct__csKeyModifiers.html#41ed4c2a59343849150ffe2e0e503dac">_csKeyModifiers::modifiers</a>[csKeyModifierTypeLast] </td> </tr> </table> </div> <div class="memdoc"> <p> Bitmasks for different modifiers. <p> If the modifier number <em>n</em> was pressed, the <em>n</em>th bit is set. <p> Example - testing for a specific modifier: <div class="fragment"><pre class="fragment"> <a class="code" href="struct__csKeyModifiers.html" title="Flags for all currently pressed modifiers.">csKeyModifiers</a> m; <span class="keywordtype">bool</span> rightAlt = m.<a class="code" href="struct__csKeyModifiers.html#41ed4c2a59343849150ffe2e0e503dac" title="Bitmasks for different modifiers.">modifiers</a>[<a class="code" href="evdefs_8h.html#912eb0936bd273cd2364621a21b1f284fbe47871afd23bc09433525811a9b084" title="&#39;Alt&#39; is held">csKeyModifierTypeAlt</a>] & (1 << <a class="code" href="evdefs_8h.html#0768a4bea2903e98b943d6ec82ed3c071f3c4ca798117271e08a6d2a136bbef4" title="The default number for a &#39;right&#39; version of a key.">csKeyModifierNumRight</a>); </pre></div> Example - testing if any modifier of a type is pressed: <div class="fragment"><pre class="fragment"> <a class="code" href="struct__csKeyModifiers.html" title="Flags for all currently pressed modifiers.">csKeyModifiers</a> m; <span class="keywordtype">bool</span> ctrl = m.<a class="code" href="struct__csKeyModifiers.html#41ed4c2a59343849150ffe2e0e503dac" title="Bitmasks for different modifiers.">modifiers</a>[<a class="code" href="evdefs_8h.html#912eb0936bd273cd2364621a21b1f284fbe47871afd23bc09433525811a9b084" title="&#39;Alt&#39; is held">csKeyModifierTypeAlt</a>] != 0; </pre></div> <p>Definition at line <a class="el" href="evdefs_8h-source.html#l00154">154</a> of file <a class="el" href="evdefs_8h-source.html">evdefs.h</a>.</p> </div> </div><p> <hr>The documentation for this struct was generated from the following file:<ul> <li>iutil/<a class="el" href="evdefs_8h-source.html">evdefs.h</a></ul> <hr size="1"><address><small>Generated for Crystal Space 1.2.1 by <a href="http://www.doxygen.org/index.html">doxygen</a> 1.5.3 </small></address> </div></body> </html>