From f926b203b00806453c39329fdc6d88f6e19f05b5 Mon Sep 17 00:00:00 2001 From: mayunteng_1 Date: Tue, 13 Dec 2022 09:11:18 +0800 Subject: [PATCH] =?UTF-8?q?inputdevice=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: mayunteng_1 Change-Id: Ib9f06bbfb021f6797cda927f76e296feaeaa7aea --- .../application-dev/reference/apis/js-apis-inputdevice.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/zh-cn/application-dev/reference/apis/js-apis-inputdevice.md b/zh-cn/application-dev/reference/apis/js-apis-inputdevice.md index e10e496b95..735081c1a2 100755 --- a/zh-cn/application-dev/reference/apis/js-apis-inputdevice.md +++ b/zh-cn/application-dev/reference/apis/js-apis-inputdevice.md @@ -238,7 +238,7 @@ getDeviceIds(callback: AsyncCallback<Array<number>>): void **示例**: ```js -inputDevice.getDeviceList((error, ids) => { +inputDevice.getDeviceIds((error, ids) => { if (error) { console.log(`Failed to get device id list, error: ${JSON.stringify(error, [`code`, `message`])}`); return; @@ -266,7 +266,7 @@ getDeviceIds(): Promise<Array<number>> **示例**: ```js -inputDevice.getDeviceList().then((ids) => { +inputDevice.getDeviceIds().then((ids) => { console.log(`Device id list: ${JSON.stringify(ids)}`); }); ``` @@ -292,7 +292,7 @@ getDevice(deviceId: number, callback: AsyncCallback<InputDeviceData>): voi ```js // 获取输入设备id为1的设备信息。 -inputDevice.getDeviceInfo(1, (error, deviceData) => { +inputDevice.getDevice(1, (error, deviceData) => { if (error) { console.log(`Failed to get device info, error: ${JSON.stringify(error, [`code`, `message`])}`); return; @@ -327,7 +327,7 @@ getDevice(deviceId: number): Promise<InputDeviceData> ```js // 获取输入设备id为1的设备信息。 -inputDevice.getDeviceInfo(1).then((deviceData) => { +inputDevice.getDevice(1).then((deviceData) => { console.log(`Device info: ${JSON.stringify(deviceData)}`); }); ``` -- GitLab