From 28f8df8abbc6169d6591bfbb2c3ff0b98a053acb Mon Sep 17 00:00:00 2001 From: yan-shuifeng Date: Sat, 21 Dec 2024 16:15:41 +0800 Subject: [PATCH] update the api of get window name by ui node Signed-off-by: yan-shuifeng --- arkui/ace_engine/native/native_node.h | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/arkui/ace_engine/native/native_node.h b/arkui/ace_engine/native/native_node.h index ccbb77543..52d4b349f 100644 --- a/arkui/ace_engine/native/native_node.h +++ b/arkui/ace_engine/native/native_node.h @@ -7976,6 +7976,20 @@ float OH_ArkUI_SystemFontStyleEvent_GetFontSizeScale(const ArkUI_SystemFontStyle */ float OH_ArkUI_SystemFontStyleEvent_GetFontWeightScale(const ArkUI_SystemFontStyleEvent* event); +/** + * @brief Obtain the name of the window in which the UI node is located. + * + * @param handle A Pointer which points to UI node. + * @param name A string pointer that stores the name of the window. + * @param length The maximum length of the string. + * @param resultLength The true length of the window name string. + * @return Error Code: + * {@link ARKUI_ERROR_CODE_NO_ERROR} succeed. + * {@link ARKUI_ERROR_CODE_PARAM_INVALID} Function parameter exception,such as empty pointers and insufficient string size. + * @since 16 + */ +int32 OH_ArkUI_NodeUtils_GetWindowName(ArkUI_NodeHandle handle, char* name, int32_t length, *int32_t resultLength); + #ifdef __cplusplus }; #endif -- Gitee