From 3c3204bc2324cf28e050911f16b8a648b12c9fed Mon Sep 17 00:00:00 2001 From: yuwenze Date: Tue, 1 Apr 2025 15:08:35 +0800 Subject: [PATCH] add revokeDelegator Signed-off-by: yuwenze Change-Id: I3e57cd10d2bce924299f6ea35f2178a36920b025 --- api/application/UIAbilityContext.d.ts | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/api/application/UIAbilityContext.d.ts b/api/application/UIAbilityContext.d.ts index c13231a61..9f9b00358 100644 --- a/api/application/UIAbilityContext.d.ts +++ b/api/application/UIAbilityContext.d.ts @@ -4781,6 +4781,22 @@ export default class UIAbilityContext extends Context { */ setAbilityInstanceInfo(label: string, icon: image.PixelMap): Promise; + /** + * Revoke delegator. + * + * @returns { Promise } The promise returned by the function. + * @throws { BusinessError } 801 - Capability not support. + * @throws { BusinessError } 16000011 - The context does not exist. + * @throws { BusinessError } 16000050 - Internal error. + * @throws { BusinessError } 16000065 - The API can be called only when the ability is running in the foreground. + * @throws { BusinessError } 16000084 - The context does not belong to HookAbility; multiple calls are invoked. + * @throws { BusinessError } 16000085 - Failed to cancel the hook of the window module. + * @syscap SystemCapability.Ability.AbilityRuntime.Core + * @stagemodelonly + * @since 17 + */ + revokeDelegator(): Promise; + /** * Set colorMode of uiability. *