add drag new api

Signed-off-by: zhangjinyu101 <zhangjinyu101@huawei.com>
Change-Id: I118b1dd51155a874581a3567023c3dc2ce3e6813
This commit is contained in:
zhangjinyu101 2024-07-31 18:26:28 +08:00
parent ab2d75caf9
commit 5d6328e634
2 changed files with 17 additions and 0 deletions

View File

@ -298,6 +298,19 @@ int32_t OH_ArkUI_DragEvent_GetDataTypes(
*/
int32_t OH_ArkUI_DragEvent_GetDragResult(ArkUI_DragEvent* event, ArkUI_DragResult* result);
/**
* @brief Obtains the drop operation from a drag event.
*
* @param event Indicates the pointer to an <b>ArkUI_DragEvent</b> object.
* @param operation Indicates the drop operation which the data receiver set.
* @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.
* Possible causes: 1. The given parameters are null or the given event is not a valid DragEvent.
* @since 12
*/
int32_t OH_ArkUI_DragEvent_GetDropOperation(ArkUI_DragEvent* event, ArkUI_DropOperation* operation);
/**
* @brief Obtains the X coordinate of the touch point for a drag preview from a drag event.
*

View File

@ -1799,6 +1799,10 @@
"first_introduced": "12",
"name": "OH_ArkUI_DragEvent_GetDragResult"
},
{
"first_introduced": "12",
"name": "OH_ArkUI_DragEvent_GetDropOperation"
},
{
"first_introduced": "12",
"name": "OH_ArkUI_DragEvent_GetPreviewTouchPointX"