Lines Matching full:code
27 <p>Key layout files (<code>.kl</code> files) map Linux key codes and axis codes
43 <li><code>/system/usr/keylayout/Vendor_XXXX_Product_XXXX_Version_XXXX.kl</code></li>
44 <li><code>/system/usr/keylayout/Vendor_XXXX_Product_XXXX.kl</code></li>
45 <li><code>/system/usr/keylayout/DEVICE_NAME.kl</code></li>
46 <li><code>/data/system/devices/keylayout/Vendor_XXXX_Product_XXXX_Version_XXXX.kl</code></li>
47 <li><code>/data/system/devices/keylayout/Vendor_XXXX_Product_XXXX.kl</code></li>
48 <li><code>/data/system/devices/keylayout/DEVICE_NAME.kl</code></li>
49 <li><code>/system/usr/keylayout/Generic.kl</code></li>
50 <li><code>/data/system/devices/keylayout/Generic.kl</code></li>
59 <code>Generic.kl</code>. This key layout is intended to support a variety of
68 <p>Key declarations consist of the keyword <code>key</code> followed by a Linux
69 key code number and Android key code name, or the keyword usage followed by a
70 HID usage and Android key code name. The HID usage is represented as a 32-bit
74 <pre><code>key 1 ESCAPE
78 </code></pre>
81 <li><code>FUNCTION</code>: The key should be interpreted as if the FUNCTION key
83 <li><code>GESTURE</code>: The key generated by a user gesture, such as palming
85 <li><code>VIRTUAL</code>: The key is a virtual soft key (capacitive button)
91 <p>Axis declarations each consist of the keyword <code>axis</code> followed by a
92 Linux axis code number and qualifiers that control the behavior of the axis
93 including at least one Android axis code name.</p>
96 <p>A basic axis simply maps a Linux axis code to an Android axis code name. The
97 following declaration maps <code>ABS_X</code> (indicated by <code>0x00</code>)
98 to <code>AXIS_X</code> (indicated by <code>X</code>).</p>
99 <pre><code>axis 0x00 X</code></pre>
100 <p>In the above example, if the value of <code>ABS_X</code> is <code>5</code>
101 then <code>AXIS_X</code> is set to <code>5</code>.</p>
104 <p>A split axis maps a Linux axis code to two Android axis code names, such that
108 <p>The following declaration maps values of the <code>ABS_Y</code> axis
109 (indicated by <code>0x01</code>) to <code>AXIS_GAS</code> when less than
110 <code>0x7f</code> or to <code>AXIS_BRAKE</code> when greater than
111 <code>0x7f</code>.</p>
112 <pre><code>axis 0x01 split 0x7f GAS BRAKE</code></pre>
113 <p>In the above example, if the value of <code>ABS_Y</code> is <code>0x7d</code>
114 then <code>AXIS_GAS</code> is set to <code>2</code> (<code>0x7f - 0x7d</code>)
115 and <code>AXIS_BRAKE</code> is set to <code>0</code>. Conversely, if the value
116 of <code>ABS_Y</code> is <code>0x83</code> then <code>AXIS_GAS</code> is set to
117 <code>0</code> and <code>AXIS_BRAKE</code> is set to <code>4</code>
118 (<code>0x83 - 0x7f</code>). Finally, if the value of <code>ABS_Y</code> equals
119 the split value of <code>0x7f</code> then both <code>AXIS_GAS</code> and
120 <code>AXIS_BRAKE</code> are set to <code>0</code>.</p>
124 declaration maps <code>ABS_RZ</code> (indicated by <code>0x05</code>) to
125 <code>AXIS_BRAKE</code> (indicated by <code>BRAKE</code>), and inverts the
127 <pre><code>axis 0x05 invert BRAKE</code></pre>
128 <p>In the above example, if the value of <code>ABS_RZ</code> is <code>2</code>
129 then <code>AXIS_BRAKE</code> is set to <code>-2</code>.</p>
138 followed by a <code>flat</code> option that specifies the value of the center
140 <pre><code>axis 0x03 Z flat 4096</code></pre>
141 <p>In the above example, the center flat position is set to <code>4096</code>.
146 <pre><code># A comment!</code></pre>
152 <pre><code># This is an example of a key layout file for a keyboard.
170 </code></pre>
173 <pre><code># This is an example of a key layout file for basic system controls,
180 </code></pre>
183 <pre><code># This is an example of a key layout file for a touch device with capacitive buttons.
189 </code></pre>
192 <pre><code># This is an example of a key layout file for headset mounted media controls.
201 </code></pre>
204 <pre><code># This is an example of a key layout file for a joystick.
235 </code></pre>
253 the <code>VIRTUAL</code> flag for each key.</li>
259 appropriate key mapping and include the <code>VIRTUAL</code> flag for each key.</li>
271 input device with the <code>VIRTUAL</code> flag set for each key.
272 <pre><code>key 139 MENU VIRTUAL
276 </code></pre>
279 framework <code>config.xml</code> resource.
280 <pre><code><!-- Specifies the amount of time to disable virtual keys after the screen
287 </code></pre>