From f968393d3f5032a86fcbea563108e62b086bffba Mon Sep 17 00:00:00 2001 From: mayunteng_1 Date: Mon, 24 Oct 2022 16:01:14 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E8=AE=A2=E9=98=85=E5=A2=9E=E5=8A=A0?= =?UTF-8?q?=E6=8C=89=E9=94=AE=E6=8A=AC=E8=B5=B7=E5=BB=B6=E6=97=B6=E6=97=B6?= =?UTF-8?q?=E9=97=B4=E5=8F=82=E6=95=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: mayunteng_1 Change-Id: I629aac38a382fab706bdc40abb605f7a5919258d --- api/@ohos.multimodalInput.inputConsumer.d.ts | 17 +++++++++ api/@ohos.multimodalInput.pointer.d.ts | 37 ++++++++++++++++++++ 2 files changed, 54 insertions(+) diff --git a/api/@ohos.multimodalInput.inputConsumer.d.ts b/api/@ohos.multimodalInput.inputConsumer.d.ts index b7e0d8f3c9..dd4ed5e24a 100644 --- a/api/@ohos.multimodalInput.inputConsumer.d.ts +++ b/api/@ohos.multimodalInput.inputConsumer.d.ts @@ -28,6 +28,7 @@ declare namespace inputConsumer { /** * Defines event of key that user want to subscribe or unsubscribe. * + * @since 8 * @syscap SystemCapability.MultimodalInput.Input.InputConsumer * @systemapi hide for inner use * @param preKeys The pre-keys that want to subscribe or unsubscribe. @@ -36,10 +37,26 @@ declare namespace inputConsumer { * @param finalKeyDownDuration Duration of final key press. */ interface KeyOptions { + /** + * @since 8 + */ preKeys: Array; + /** + * @since 8 + */ finalKey: number; + /** + * @since 8 + */ isFinalKeyDown: boolean; + /** + * @since 8 + */ finalKeyDownDuration: number; + /** + * @since 9 + */ + finalKeyUpDelay: number; } /** diff --git a/api/@ohos.multimodalInput.pointer.d.ts b/api/@ohos.multimodalInput.pointer.d.ts index 55fa1863b6..9aea71551f 100644 --- a/api/@ohos.multimodalInput.pointer.d.ts +++ b/api/@ohos.multimodalInput.pointer.d.ts @@ -288,6 +288,25 @@ declare namespace pointer { */ function setPointerStyle(windowId: number, pointerStyle: PointerStyle): Promise; + /** + * 设置全局默认鼠标样式 + * @since 10 + * @systemapi hide for inner use + * @syscap SystemCapability.MultimodalInput.Input.Pointer + * @param pointerStyle Pointer style. + * @param callback Callback used to return the result. + */ + function setPointerStyle(pointerStyle: PointerStyle, callback: AsyncCallback): void; + + /** + * 设置全局默认鼠标样式 + * @since 10 + * @systemapi hide for inner use + * @syscap SystemCapability.MultimodalInput.Input.Pointer + * @param pointerStyle Pointer style. + */ + function setPointerStyle(pointerStyle: PointerStyle): Promise; + /** * Queries the pointer style. * @since 9 @@ -308,6 +327,24 @@ declare namespace pointer { */ function getPointerStyle(windowId: number): Promise; + /** + * 查询全局默认鼠标样式 + * @since 10 + * @systemapi hide for inner use + * @syscap SystemCapability.MultimodalInput.Input.Pointer + * @param callback Callback used to return the result. + */ + function getPointerStyle(callback: AsyncCallback): void; + + /** + * Queries the pointer style. + * @since 10 + * @systemapi hide for inner use + * @syscap SystemCapability.MultimodalInput.Input.Pointer + * @return Returns the result through a promise. + */ + function getPointerStyle(): Promise; + /** * Sets whether the pointer icon is visible. * -- Gitee From 03da5bc3fb4a9e54f0bdf53925b89187349781b8 Mon Sep 17 00:00:00 2001 From: mayunteng_1 Date: Mon, 24 Oct 2022 17:50:56 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E6=9F=A5=E8=AF=A2=E6=8C=89=E9=94=AE?= =?UTF-8?q?=E6=94=AF=E6=8C=81=E5=85=A5=E5=8F=82=E7=B1=BB=E5=9E=8B=E4=BF=AE?= =?UTF-8?q?=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: I65a419054bd35506c084cf317cdcb81badeba869 --- api/@ohos.multimodalInput.inputDevice.d.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/@ohos.multimodalInput.inputDevice.d.ts b/api/@ohos.multimodalInput.inputDevice.d.ts index 2d3cc32091..37960c90a0 100755 --- a/api/@ohos.multimodalInput.inputDevice.d.ts +++ b/api/@ohos.multimodalInput.inputDevice.d.ts @@ -321,7 +321,7 @@ declare namespace inputDevice { * @return Returns a result indicating whether the specified key codes are supported. * @throws {BusinessError} 401 - Parameter error. */ - function supportKeys(deviceId: number, keys: Array, callback: Callback>): void; + function supportKeys(deviceId: number, keys: Array, callback: AsyncCallback>): void; /** * Checks whether the specified key codes of an input device are supported. -- Gitee