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

!17200 翻译已完成16853+16998

Merge pull request !17200 from shawn_he/16998-d
......@@ -29,7 +29,6 @@ When a user enters text, the input method determines whether to launch the virtu
1. Call the **getDeviceList** API to obtain the list of connected input devices. Call the **getKeyboardType** API to traverse all connected devices to check whether a physical keyboard exists. If a physical keyboard exists, mark the physical keyboard as connected. This step ensures that your application detects all inserted input devices before listening for device hot swap events.
2. Call the **on** API to listen for device hot swap events. If a physical keyboard is inserted, mark the physical keyboard as connected. If a physical keyboard is removed, mark the physical keyboard as disconnected.
3. When a user enters text, check whether a physical keyboard is connected. If a physical keyboard is not connected, launch the virtual keyboard.
```js
......@@ -65,6 +64,4 @@ try {
} catch (error) {
console.log(`Execute failed, error: ${JSON.stringify(error, [`code`, `message`])}`);
}
// 3. Determine whether to launch the virtual keyboard based on the value of isPhysicalKeyboardExist.
// TODO
```
......@@ -1542,7 +1542,7 @@ For details about the error codes, see [Resource Manager Error Codes](../errorco
```
### closeRawFd<sup>8+</sup>
### closeRawFd<sup>9+</sup>
closeRawFd(path: string): Promise&lt;void&gt;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册