From 19fe8fa68e1dd4528c600cacaf196ef031a8fcdf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=BD=9C=E7=A7=8B=E5=AE=8F?= Date: Tue, 29 Jul 2025 17:04:08 +0800 Subject: [PATCH] =?UTF-8?q?=E5=B7=AE=E5=BC=82=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: 潜秋宏 Change-Id: Ic423991d269ffe84a10fed2005c2c615fd34d95e --- arkui/ace_engine/native/drag_and_drop.h | 5 +- arkui/ace_engine/native/native_node.h | 8 +-- arkui/ace_engine/native/native_type.h | 68 ++++++++++++------------ arkui/ace_engine/native/ui_input_event.h | 10 ++-- 4 files changed, 46 insertions(+), 45 deletions(-) diff --git a/arkui/ace_engine/native/drag_and_drop.h b/arkui/ace_engine/native/drag_and_drop.h index 15f4de621..70b775084 100644 --- a/arkui/ace_engine/native/drag_and_drop.h +++ b/arkui/ace_engine/native/drag_and_drop.h @@ -467,8 +467,8 @@ float OH_ArkUI_DragEvent_GetVelocity(ArkUI_DragEvent* event); * @brief Obtains the pressed status of modifier keys from a drag event. * * @param event Indicates the pointer to an ArkUI_DragEvent object. - * @param keys {@link ArkUI_ModifierKeyName} Indicates the returned combination of modifier keys that are currently pressed. - * The application can determine the pressed modifier keys through bitwise operations. + * @param keys {@link ArkUI_ModifierKeyName} Indicates the returned combination of modifier keys that are + * currently pressed. The application can determine the pressed modifier keys through bitwise operations. * @return Returns the result code. * Returns {@link ARKUI_ERROR_CODE_NO_ERROR} if the operation is successful. * Returns {@link ARKUI_ERROR_CODE_PARAM_INVALID} if a parameter error occurs. @@ -968,7 +968,6 @@ int32_t OH_ArkUI_NotifyDragEndPendingDone(int32_t requestIdentify); * to pass a character array for receiving the string and explicitly specify the array length. It is * recommended that the array length be no less than 128 characters. If the length cannot accommodate * the actual bundle name length, the ERROR result will be returned. - * * @param event Indicates the pointer to an ArkUI_DragEvent object. * @param bundleName A string array used to receive the source application's bundle name. * @param length Use this to explicitly specify the length of the incoming string array. diff --git a/arkui/ace_engine/native/native_node.h b/arkui/ace_engine/native/native_node.h index cd08b26e8..f24e6e0d8 100644 --- a/arkui/ace_engine/native/native_node.h +++ b/arkui/ace_engine/native/native_node.h @@ -1802,8 +1802,8 @@ typedef enum { * */ NODE_VISIBLE_AREA_CHANGE_RATIO = 93, - - /** + + /** * @brief Sets the transition effect when the component is inserted or deleted. * This attribute can be set, and obtained as required through APIs. * @@ -3614,6 +3614,7 @@ typedef enum { * */ NODE_TEXT_AREA_SHOW_KEYBOARD_ON_FOCUS, + /** * @brief When this property is set, the height of the textArea component is calculated using this property. * @@ -6857,7 +6858,8 @@ typedef enum { /** * @brief Defines the gesture event type. * - * When the event callback occurs, the union type in the {@link ArkUI_NodeEvent} object is {@link ArkUI_UIInputEvent}. + * When the event callback occurs, the union type in the {@link ArkUI_NodeEvent} object is + * {@link ArkUI_UIInputEvent}. */ NODE_TOUCH_EVENT = 0, diff --git a/arkui/ace_engine/native/native_type.h b/arkui/ace_engine/native/native_type.h index 76e20d772..520aa5547 100644 --- a/arkui/ace_engine/native/native_type.h +++ b/arkui/ace_engine/native/native_type.h @@ -2330,6 +2330,11 @@ typedef enum { * @since 14 */ ARKUI_ERROR_CODE_INVALID_STYLED_STRING = 180101, + /** + * @error The gesture recognizer type is not supported. + * @since 18 + */ + ARKUI_ERROR_CODE_RECOGNIZER_TYPE_NOT_SUPPORTED = 180102, /** * @error The uiContext is invalid. * @since 18 @@ -2340,11 +2345,6 @@ typedef enum { * @since 18 */ ARKUI_ERROR_CODE_CALLBACK_INVALID = 190002, - /** - * @error The gesture recognizer type is not supported. - * @since 18 - */ - ARKUI_ERROR_CODE_RECOGNIZER_TYPE_NOT_SUPPORTED = 180102, /** * @error operation is not allowed for current drag drop pharse. * @since 19 @@ -5062,35 +5062,6 @@ float OH_ArkUI_ProgressLinearStyleOption_GetStrokeWidth(ArkUI_ProgressLinearStyl */ float OH_ArkUI_ProgressLinearStyleOption_GetStrokeRadius(ArkUI_ProgressLinearStyleOption* option); -/** - * @brief Creates an option for taking snapshot, the returned value must be released through - * {@link OH_ArkUI_DestroySnapshotOptions} when it's not used anymore. - * - * @return Returns the pointer to the created snapshot options object.If the object returns a null pointer, - * it indicates a creation failure, and the reason for the failure may be that the address space is full. - * @since 15 - */ -ArkUI_SnapshotOptions* OH_ArkUI_CreateSnapshotOptions(); - -/** - * @brief Dispose a snapshot option object. - * - * @param snapshotOptions Indicates the pointer to the snapshot option. - * @since 15 - */ -void OH_ArkUI_DestroySnapshotOptions(ArkUI_SnapshotOptions* snapshotOptions); - -/** - * @brief Config the snapshot option with scale. - * - * @param snapshotOptions Indicates the pointer to the snapshot option. - * @param scale Indicates the scale property to take the snapshot. - * @return Returns {@link ARKUI_ERROR_CODE_NO_ERROR} if the operation is successful. - * Returns {@link ARKUI_ERROR_CODE_PARAM_INVALID} if a parameter error occurs. - * @since 15 - */ -int32_t OH_ArkUI_SnapshotOptions_SetScale(ArkUI_SnapshotOptions* snapshotOptions, float scale); - /** * @brief Create a cross-language option instance. * @@ -5126,6 +5097,35 @@ void OH_ArkUI_CrossLanguageOption_SetAttributeSettingStatus(ArkUI_CrossLanguageO */ bool OH_ArkUI_CrossLanguageOption_GetAttributeSettingStatus(ArkUI_CrossLanguageOption* option); +/** + * @brief Creates an option for taking snapshot, the returned value must be released through + * {@link OH_ArkUI_DestroySnapshotOptions} when it's not used anymore. + * + * @return Returns the pointer to the created snapshot options object.If the object returns a null pointer, + * it indicates a creation failure, and the reason for the failure may be that the address space is full. + * @since 15 + */ +ArkUI_SnapshotOptions* OH_ArkUI_CreateSnapshotOptions(); + +/** + * @brief Dispose a snapshot option object. + * + * @param snapshotOptions Indicates the pointer to the snapshot option. + * @since 15 + */ +void OH_ArkUI_DestroySnapshotOptions(ArkUI_SnapshotOptions* snapshotOptions); + +/** + * @brief Config the snapshot option with scale. + * + * @param snapshotOptions Indicates the pointer to the snapshot option. + * @param scale Indicates the scale property to take the snapshot. + * @return Returns {@link ARKUI_ERROR_CODE_NO_ERROR} if the operation is successful. + * Returns {@link ARKUI_ERROR_CODE_PARAM_INVALID} if a parameter error occurs. + * @since 15 + */ +int32_t OH_ArkUI_SnapshotOptions_SetScale(ArkUI_SnapshotOptions* snapshotOptions, float scale); + /** * @brief Defines the parameters for visible area change events. * diff --git a/arkui/ace_engine/native/ui_input_event.h b/arkui/ace_engine/native/ui_input_event.h index 9e4c31d85..464644dfb 100644 --- a/arkui/ace_engine/native/ui_input_event.h +++ b/arkui/ace_engine/native/ui_input_event.h @@ -61,9 +61,9 @@ typedef enum { ARKUI_UIINPUTEVENT_TYPE_AXIS = 2, /** Mouse event. */ ARKUI_UIINPUTEVENT_TYPE_MOUSE = 3, - /** + /** * @brief key event. - * + * * @since 20 */ ARKUI_UIINPUTEVENT_TYPE_KEY = 4, @@ -334,7 +334,7 @@ int32_t OH_ArkUI_UIInputEvent_GetSourceType(const ArkUI_UIInputEvent* event); /** * @brief Obtains the tool type of a UI input event. - * + * * The input tool is the device used to interact with the input source, such as a finger or stylus. * It is defined by the UI_INPUT_EVENT_TOOL_TYPE_XXX enum. * These tools do not produce events directly but drive the input source to generate them. @@ -1243,7 +1243,7 @@ int32_t OH_ArkUI_UIInputEvent_GetTargetDisplayId(const ArkUI_UIInputEvent* event * @since 17 */ int32_t OH_ArkUI_AxisEvent_SetPropagation(const ArkUI_UIInputEvent* event, bool propagation); - + /** * @brief Obtains the scroll step coefficient for a wheel-based axis event. * This API returns the user-configured scroll scale factor factor. @@ -1380,7 +1380,7 @@ int32_t OH_ArkUI_PointerEvent_PostClonedEvent(ArkUI_NodeHandle node, const ArkUI * In most cases, this method is unnecessary unless you need to determine if the return value indicates an error. * Here's an example of usage: For return values like float (where 0.0 doesn't indicate an error), use GetLatestStatus * to confirm if an error occurred. - * float x = OH_ArkUI_PointerEvent_GetX(event); + * float x = OH_ArkUI_PointerEvent_GetX(event); * if (ARKUI_ERROR_CODE_NO_ERROR != OH_ArkUI_UIInputEvent_GetLatestStatus()) { * // error * return; -- Gitee