未验证 提交 02363527 编写于 作者: O openharmony_ci 提交者: Gitee

!5612 翻译已完成5150

Merge pull request !5612 from shawn_he/5150-a
......@@ -121,10 +121,10 @@ 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.|
| ---------- | -------------------------- | ---------------------------------------------------- |
| 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<[SourceType](#sourcetype)> | 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.|
| sources | Array<[SourceType](#sourcetype)> | 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<[axisRanges](#axisrange)> | Axis information of the input device. |
| bus | number | Bus type of the input device. |
| product | number | Product information of the input device. |
......
# 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.
先完成此消息的编辑!
想要评论请 注册