From e8bf13530125cb938ebf64a2254254f5c0adce7c Mon Sep 17 00:00:00 2001 From: yanxinyu7 Date: Thu, 11 Sep 2025 16:31:53 +0800 Subject: [PATCH 1/2] overload Signed-off-by: yanxinyu7 --- api/@ohos.window.d.ts | 176 ++++++++++++++++++++++++++++++++++-------- 1 file changed, 144 insertions(+), 32 deletions(-) diff --git a/api/@ohos.window.d.ts b/api/@ohos.window.d.ts index 69d0beedad..edfc295424 100644 --- a/api/@ohos.window.d.ts +++ b/api/@ohos.window.d.ts @@ -6908,17 +6908,29 @@ declare namespace window { * Register the callback of keyboardHeightChange * * @param { 'keyboardHeightChange' } type - The value is fixed at 'keyboardHeightChange', indicating the keyboard height change event. - * @param { Callback } callback - Callback used to return the current keyboard height, which is an integer, in px. + * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. * @throws { BusinessError } 401 - Parameter error. Possible cause: 1. Mandatory parameters are left unspecified; * 2. Incorrect parameter types; * 3. Parameter verification failed. * @syscap SystemCapability.WindowManager.WindowManager.Core * @atomicservice * @since 12 dynamic - * @since 20 static */ on(type: 'keyboardHeightChange', callback: Callback): void; + /** + * Register the callback of keyboardHeightChange + * + * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @throws { BusinessError } 401 - Parameter error. Possible cause: 1. Mandatory parameters are left unspecified; + * 2. Incorrect parameter types; + * 3. Parameter verification failed. + * @syscap SystemCapability.WindowManager.WindowManager.Core + * @atomicservice + * @since 22 static + */ + onKeyboardHeightChange(callback: Callback): void; + /** * Unregister the callback of keyboardHeightChange * @@ -6935,7 +6947,7 @@ declare namespace window { * Unregister the callback of keyboardHeightChange * * @param { 'keyboardHeightChange' } type - The value is fixed at 'keyboardHeightChange', indicating the keyboard height change event. - * @param { Callback } callback - Callback used to return the current keyboard height, which is an integer, in px. + * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. * If a value is passed in, the corresponding subscription is canceled. * If no value is passed in, all subscriptions to the specified event are canceled. * @throws { BusinessError } 401 - Parameter error. Possible cause: 1. Incorrect parameter types; @@ -6943,15 +6955,28 @@ declare namespace window { * @syscap SystemCapability.WindowManager.WindowManager.Core * @atomicservice * @since 12 dynamic - * @since 20 static */ off(type: 'keyboardHeightChange', callback?: Callback): void; + /** + * Unregister the callback of keyboardHeightChange + * + * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * If a value is passed in, the corresponding subscription is canceled. + * If no value is passed in, all subscriptions to the specified event are canceled. + * @throws { BusinessError } 401 - Parameter error. Possible cause: 1. Incorrect parameter types; + * 2. Parameter verification failed. + * @syscap SystemCapability.WindowManager.WindowManager.Core + * @atomicservice + * @since 22 static + */ + offKeyboardHeightChange(callback?: Callback): void; + /** * Register the callback of keyboardWillShow * * @param { 'keyboardWillShow' } type - The value is fixed at 'keyboardWillShow', indicating the start of the keyboard show animation event. - * @param { Callback } callback - Callback invoked before the keyboard show animation start. + * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardWillShow can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager @@ -6960,11 +6985,23 @@ declare namespace window { */ on(type: 'keyboardWillShow', callback: Callback): void; + /** + * Register the callback of keyboardWillShow + * + * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @throws { BusinessError } 801 - Capability not supported. Function keyboardWillShow can not work correctly due to limited device capabilities. + * @throws { BusinessError } 1300002 - This window state is abnormal. + * @syscap SystemCapability.Window.SessionManager + * @atomicservice + * @since 22 static + */ + onKeyboardWillShow(callback: Callback): void; + /** * Unregister the callback of keyboardWillShow * * @param { 'keyboardWillShow' } type - The value is fixed at 'keyboardWillShow', indicating the start of the keyboard show animation event. - * @param { Callback } callback - Callback invoked before the keyboard show animation start. + * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardWillShow can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager @@ -6973,11 +7010,23 @@ declare namespace window { */ off(type: 'keyboardWillShow', callback?: Callback): void; + /** + * Unregister the callback of keyboardWillShow + * + * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @throws { BusinessError } 801 - Capability not supported. Function keyboardWillShow can not work correctly due to limited device capabilities. + * @throws { BusinessError } 1300002 - This window state is abnormal. + * @syscap SystemCapability.Window.SessionManager + * @atomicservice + * @since 22 static + */ + offKeyboardWillShow(callback?: Callback): void; + /** * Register the callback of keyboardWillHide * * @param { 'keyboardWillHide' } type - The value is fixed at 'keyboardWillHide', indicating the start of the keyboard hide animation event. - * @param { Callback } callback - Callback invoked before the keyboard hide animation start. + * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardWillHide can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager @@ -6986,11 +7035,23 @@ declare namespace window { */ on(type: 'keyboardWillHide', callback: Callback): void; + /** + * Register the callback of keyboardWillHide + * + * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @throws { BusinessError } 801 - Capability not supported. Function keyboardWillHide can not work correctly due to limited device capabilities. + * @throws { BusinessError } 1300002 - This window state is abnormal. + * @syscap SystemCapability.Window.SessionManager + * @atomicservice + * @since 22 static + */ + onKeyboardWillHide(callback: Callback): void; + /** * Unregister the callback of keyboardWillHide * * @param { 'keyboardWillHide' } type - The value is fixed at 'keyboardWillHide', indicating the start of the keyboard hide animation event. - * @param { Callback } callback - Callback invoked before the keyboard hide animation start. + * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardWillHide can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager @@ -6999,62 +7060,118 @@ declare namespace window { */ off(type: 'keyboardWillHide', callback?: Callback): void; + /** + * Unregister the callback of keyboardWillHide + * + * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @throws { BusinessError } 801 - Capability not supported. Function keyboardWillHide can not work correctly due to limited device capabilities. + * @throws { BusinessError } 1300002 - This window state is abnormal. + * @syscap SystemCapability.Window.SessionManager + * @atomicservice + * @since 22 static + */ + offKeyboardWillHide(callback?: Callback): void; + /** * Register the callback of keyboardDidShow * * @param { 'keyboardDidShow' } type - The value is fixed at 'keyboardDidShow', indicating the completion of the keyboard show animation event. - * @param { Callback } callback - Callback invoked when the keyboard show animation is completed. + * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardDidShow can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager * @atomicservice * @since 18 dynamic - * @since 20 static */ on(type: 'keyboardDidShow', callback: Callback): void; + /** + * Register the callback of keyboardDidShow + * + * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @throws { BusinessError } 801 - Capability not supported. Function keyboardDidShow can not work correctly due to limited device capabilities. + * @throws { BusinessError } 1300002 - This window state is abnormal. + * @syscap SystemCapability.Window.SessionManager + * @atomicservice + * @since 22 static + */ + onKeyboardDidShow(callback: Callback): void; + /** * Unregister the callback of keyboardDidShow * * @param { 'keyboardDidShow' } type - The value is fixed at 'keyboardDidShow', indicating the completion of the keyboard show animation event. - * @param { Callback } callback - Callback invoked when the keyboard show animation is completed. + * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardDidShow can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager * @atomicservice * @since 18 dynamic - * @since 20 static */ off(type: 'keyboardDidShow', callback?: Callback): void; + /** + * Unregister the callback of keyboardDidShow + * + * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @throws { BusinessError } 801 - Capability not supported. Function keyboardDidShow can not work correctly due to limited device capabilities. + * @throws { BusinessError } 1300002 - This window state is abnormal. + * @syscap SystemCapability.Window.SessionManager + * @atomicservice + * @since 22 static + */ + offKeyboardDidShow(callback?: Callback): void; + /** * Register the callback of keyboardDidHide * * @param { 'keyboardDidHide' } type - The value is fixed at 'keyboardDidHide', indicating the completion of the keyboard hide animation event. - * @param { Callback } callback - Callback invoked when the keyboard hide animation is completed. + * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardDidHide can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager * @atomicservice * @since 18 dynamic - * @since 20 static */ on(type: 'keyboardDidHide', callback: Callback): void; + /** + * Register the callback of keyboardDidHide + * + * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @throws { BusinessError } 801 - Capability not supported. Function keyboardDidHide can not work correctly due to limited device capabilities. + * @throws { BusinessError } 1300002 - This window state is abnormal. + * @syscap SystemCapability.Window.SessionManager + * @atomicservice + * @since 22 static + */ + onKeyboardDidHide(callback: Callback): void; + /** * Unregister the callback of keyboardDidHide * * @param { 'keyboardDidHide' } type - The value is fixed at 'keyboardDidHide', indicating the completion of the keyboard hide animation event. - * @param { Callback } callback - Callback invoked when the keyboard hide animation is completed. + * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardDidHide can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager * @atomicservice * @since 18 dynamic - * @since 20 static */ off(type: 'keyboardDidHide', callback?: Callback): void; + /** + * Unregister the callback of keyboardDidHide + * + * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @throws { BusinessError } 801 - Capability not supported. Function keyboardDidHide can not work correctly due to limited device capabilities. + * @throws { BusinessError } 1300002 - This window state is abnormal. + * @syscap SystemCapability.Window.SessionManager + * @atomicservice + * @since 22 static + */ + offKeyboardDidHide(callback?: Callback): void; + /** * Subscribes to the touch event outside this window. * @@ -10514,8 +10631,8 @@ declare namespace window { * * @param { 'rotationChange' } type - The value is fixed at 'rotationChange', * indicating the window rotation change event. - * @param { RotationChangeCallback } callback - - * Callback used to return the rotation change result. + * @param { RotationChangeCallback } [callback] - + * Unregister the callback function. If not provided, all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. * Failed to call the API due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. @@ -10529,20 +10646,17 @@ declare namespace window { /** * Register the callback of rotation change * - * @param { 'rotationChange' } type - The value is fixed at 'rotationChange', - * indicating the window rotation change event. - * @param { RotationChangeCallback } callback - - * Callback used to return the rotation change result. + * @param { RotationChangeCallback } [callback] - + * Unregister the callback function. If not provided, all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. * Failed to call the API due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @throws { BusinessError } 1300003 - This window manager service works abnormally. * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 20 static + * @since 22 static */ - on(type: 'rotationChange', callback: RotationChangeCallback): - void; + onRotationChange(callback: RotationChangeCallback): void; /** * Unregister the callback of rotationChange @@ -10550,7 +10664,7 @@ declare namespace window { * @param { 'rotationChange' } type - The value is fixed at 'rotationChange', * indicating the window rotation change event. * @param { RotationChangeCallback } [callback] - - * Callback used to return the RectChangeOptions. + * Unregister the callback function. If not provided, all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. * Failed to call the API due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. @@ -10565,20 +10679,18 @@ declare namespace window { /** * Unregister the callback of rotationChange * - * @param { 'rotationChange' } type - The value is fixed at 'rotationChange', - * indicating the window rotation change event. * @param { RotationChangeCallback } [callback] - - * Callback used to return the RectChangeOptions. + * Unregister the callback function. If not provided, all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. * Failed to call the API due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @throws { BusinessError } 1300003 - This window manager service works abnormally. * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 20 static + * @since 22 static */ - off(type: 'rotationChange', - callback?: RotationChangeCallback): void; + offRotationChange(callback?: RotationChangeCallback): + void; /** * UIExtension in window secure limit change callback on. -- Gitee From 433723046c7b38bf3a7af639c04f06b690a24dfc Mon Sep 17 00:00:00 2001 From: yanxinyu7 Date: Mon, 15 Sep 2025 10:37:06 +0800 Subject: [PATCH 2/2] fix_0915 Signed-off-by: yanxinyu7 --- api/@ohos.window.d.ts | 64 +++++++++++++++++++++++++++---------------- 1 file changed, 40 insertions(+), 24 deletions(-) diff --git a/api/@ohos.window.d.ts b/api/@ohos.window.d.ts index edfc295424..da5f60b4c7 100644 --- a/api/@ohos.window.d.ts +++ b/api/@ohos.window.d.ts @@ -6908,7 +6908,8 @@ declare namespace window { * Register the callback of keyboardHeightChange * * @param { 'keyboardHeightChange' } type - The value is fixed at 'keyboardHeightChange', indicating the keyboard height change event. - * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @param { Callback } [callback] - Unregister the callback function. If not provided, + * all callbacks for the given event type will be removed. * @throws { BusinessError } 401 - Parameter error. Possible cause: 1. Mandatory parameters are left unspecified; * 2. Incorrect parameter types; * 3. Parameter verification failed. @@ -6921,7 +6922,8 @@ declare namespace window { /** * Register the callback of keyboardHeightChange * - * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @param { Callback } [callback] - Unregister the callback function. If not provided, + * all callbacks for the given event type will be removed. * @throws { BusinessError } 401 - Parameter error. Possible cause: 1. Mandatory parameters are left unspecified; * 2. Incorrect parameter types; * 3. Parameter verification failed. @@ -6947,9 +6949,8 @@ declare namespace window { * Unregister the callback of keyboardHeightChange * * @param { 'keyboardHeightChange' } type - The value is fixed at 'keyboardHeightChange', indicating the keyboard height change event. - * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. - * If a value is passed in, the corresponding subscription is canceled. - * If no value is passed in, all subscriptions to the specified event are canceled. + * @param { Callback } [callback] - Unregister the callback function. If not provided, + * all callbacks for the given event type will be removed. * @throws { BusinessError } 401 - Parameter error. Possible cause: 1. Incorrect parameter types; * 2. Parameter verification failed. * @syscap SystemCapability.WindowManager.WindowManager.Core @@ -6961,9 +6962,8 @@ declare namespace window { /** * Unregister the callback of keyboardHeightChange * - * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. - * If a value is passed in, the corresponding subscription is canceled. - * If no value is passed in, all subscriptions to the specified event are canceled. + * @param { Callback } [callback] - Unregister the callback function. If not provided, + * all callbacks for the given event type will be removed. * @throws { BusinessError } 401 - Parameter error. Possible cause: 1. Incorrect parameter types; * 2. Parameter verification failed. * @syscap SystemCapability.WindowManager.WindowManager.Core @@ -6976,7 +6976,8 @@ declare namespace window { * Register the callback of keyboardWillShow * * @param { 'keyboardWillShow' } type - The value is fixed at 'keyboardWillShow', indicating the start of the keyboard show animation event. - * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @param { Callback } [callback] - Unregister the callback function. If not provided, + * all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardWillShow can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager @@ -6988,7 +6989,8 @@ declare namespace window { /** * Register the callback of keyboardWillShow * - * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @param { Callback } [callback] - Unregister the callback function. If not provided, + * all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardWillShow can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager @@ -7001,7 +7003,8 @@ declare namespace window { * Unregister the callback of keyboardWillShow * * @param { 'keyboardWillShow' } type - The value is fixed at 'keyboardWillShow', indicating the start of the keyboard show animation event. - * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @param { Callback } [callback] - Unregister the callback function. If not provided, + * all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardWillShow can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager @@ -7013,7 +7016,8 @@ declare namespace window { /** * Unregister the callback of keyboardWillShow * - * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @param { Callback } [callback] - Unregister the callback function. If not provided, + * all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardWillShow can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager @@ -7026,7 +7030,8 @@ declare namespace window { * Register the callback of keyboardWillHide * * @param { 'keyboardWillHide' } type - The value is fixed at 'keyboardWillHide', indicating the start of the keyboard hide animation event. - * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @param { Callback } [callback] - Unregister the callback function. If not provided, + * all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardWillHide can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager @@ -7038,7 +7043,8 @@ declare namespace window { /** * Register the callback of keyboardWillHide * - * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @param { Callback } [callback] - Unregister the callback function. If not provided, + * all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardWillHide can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager @@ -7051,7 +7057,8 @@ declare namespace window { * Unregister the callback of keyboardWillHide * * @param { 'keyboardWillHide' } type - The value is fixed at 'keyboardWillHide', indicating the start of the keyboard hide animation event. - * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @param { Callback } [callback] - Unregister the callback function. If not provided, + * all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardWillHide can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager @@ -7063,7 +7070,8 @@ declare namespace window { /** * Unregister the callback of keyboardWillHide * - * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @param { Callback } [callback] - Unregister the callback function. If not provided, + * all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardWillHide can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager @@ -7076,7 +7084,8 @@ declare namespace window { * Register the callback of keyboardDidShow * * @param { 'keyboardDidShow' } type - The value is fixed at 'keyboardDidShow', indicating the completion of the keyboard show animation event. - * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @param { Callback } [callback] - Unregister the callback function. If not provided, + * all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardDidShow can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager @@ -7088,7 +7097,8 @@ declare namespace window { /** * Register the callback of keyboardDidShow * - * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @param { Callback } [callback] - Unregister the callback function. If not provided, + * all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardDidShow can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager @@ -7101,7 +7111,8 @@ declare namespace window { * Unregister the callback of keyboardDidShow * * @param { 'keyboardDidShow' } type - The value is fixed at 'keyboardDidShow', indicating the completion of the keyboard show animation event. - * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @param { Callback } [callback] - Unregister the callback function. If not provided, + * all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardDidShow can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager @@ -7113,7 +7124,8 @@ declare namespace window { /** * Unregister the callback of keyboardDidShow * - * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @param { Callback } [callback] - Unregister the callback function. If not provided, + * all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardDidShow can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager @@ -7126,7 +7138,8 @@ declare namespace window { * Register the callback of keyboardDidHide * * @param { 'keyboardDidHide' } type - The value is fixed at 'keyboardDidHide', indicating the completion of the keyboard hide animation event. - * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @param { Callback } [callback] - Unregister the callback function. If not provided, + * all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardDidHide can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager @@ -7138,7 +7151,8 @@ declare namespace window { /** * Register the callback of keyboardDidHide * - * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @param { Callback } [callback] - Unregister the callback function. If not provided, + * all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardDidHide can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager @@ -7151,7 +7165,8 @@ declare namespace window { * Unregister the callback of keyboardDidHide * * @param { 'keyboardDidHide' } type - The value is fixed at 'keyboardDidHide', indicating the completion of the keyboard hide animation event. - * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @param { Callback } [callback] - Unregister the callback function. If not provided, + * all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardDidHide can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager @@ -7163,7 +7178,8 @@ declare namespace window { /** * Unregister the callback of keyboardDidHide * - * @param { Callback } [callback] - Unregister the callback function. If not provided, all callbacks for the given event type will be removed. + * @param { Callback } [callback] - Unregister the callback function. If not provided, + * all callbacks for the given event type will be removed. * @throws { BusinessError } 801 - Capability not supported. Function keyboardDidHide can not work correctly due to limited device capabilities. * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager -- Gitee