提交 7e2aa564 编写于 作者: S shawn_he

update docs

Signed-off-by: Nshawn_he <shawn.he@huawei.com>
上级 78eeee8e
......@@ -11,7 +11,7 @@ The input device management module is used to listen for the connection, disconn
## Modules to Import
```
```js
import inputDevice from '@ohos.multimodalInput.inputDevice';
```
......@@ -33,7 +33,7 @@ Obtains the IDs of all input devices. This API uses an asynchronous callback to
**Example**
```
```js
export default {
data: {
deviceIds: Array,
......@@ -65,7 +65,7 @@ Obtains the IDs of all input devices. This API uses a promise to return the resu
**Example**
```
```js
export default {
testGetDeviceIds: function () {
console.info("InputDeviceJsTest---start---testGetDeviceIds");
......@@ -100,7 +100,7 @@ Obtains the information about an input device. This API uses an asynchronous cal
**Example**
```
```js
export default {
InputDeviceData: {
deviceId : 0,
......@@ -136,7 +136,7 @@ Obtains the information about an input device. This API uses a promise to return
**Example**
```
```js
export default {
InputDeviceData: {
deviceId : 0,
......@@ -166,17 +166,17 @@ Defines the information about an input device.
**System capability**: SystemCapability.MultimodalInput.Input.InputDevice
| Name | Type | Description |
| ---------- | -------------------------------------- | ------------------------------------------------------------ |
| id | number | Unique identifier of an input device. If the same physical device is repeatedly inserted and removed, its ID changes.|
| name | string | Name of the input device. |
| sources | Array&lt;[SourceType](#sourcetype)&gt; | Source types of the input device. For example, if a keyboard is attached with a touchpad, the device has two input sources: keyboard and touchpad.|
| axisRanges | Array&lt;[axisRanges](#axisrange)&gt; | Axis information of the input device. |
| bus | number | Bus type of the input device. |
| product | number | Product information of the input device. |
| vendor | number | Vendor information of the input device. |
| version | number | Version information of the input device. |
| phys | string | Physical address of the input device. |
| uniq | string | Unique ID of the input device. |
| ---------- | -------------------------- | ---------------------------------------------------- |
| id | number | Unique identifier of an input device. If the same physical device is repeatedly inserted and removed, its ID changes. |
| name | string | Name of the input device. |
| sources | Array&lt;[SourceType](#sourcetype)&gt; | Source types of the input device. For example, if a keyboard is attached with a touchpad, the device has two input sources: keyboard and touchpad. |
| axisRanges | Array&lt;[axisRanges](#axisrange)&gt; | Axis information of the input device. |
| bus | number | Bus type of the input device. |
| product | number | Product information of the input device. |
| vendor | number | Vendor information of the input device. |
| version | number | Version information of the input device. |
| phys | string | Physical address of the input device. |
| uniq | string | Unique ID of the input device. |
## AxisType
......
# Input Event Client
> ![icon-note.gif](public_sys-resources/icon-note.gif) **NOTE**
> **NOTE**
>
> - The initial APIs of this module are supported since API version 8. Newly added APIs will be marked with a superscript to indicate their earliest API version.
> The initial APIs of this module are supported since API version 8. Newly added APIs will be marked with a superscript to indicate their earliest API version.
>
> - The APIs of this module are system APIs and cannot be called by third-party applications.
> The APIs of this module are system APIs and cannot be called by third-party applications.
## Modules to Import
```
```js
import inputEventClient from '@ohos.multimodalInput.inputEventClient';
```
......@@ -32,14 +32,14 @@ Injects a key.
**Example**
```
```js
let keyEvent = {
isPressed: true,
keyCode: 2,
keyDownDuration: 0,
isIntercepted: false
}
res = inputEventClient.injectEvent({KeyEvent: keyEvent});
let res = inputEventClient.injectEvent({KeyEvent: keyEvent});
```
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册