17777dab0Sopenharmony_ci/*
27777dab0Sopenharmony_ci * Copyright (c) 2024 Huawei Device Co., Ltd.
37777dab0Sopenharmony_ci * Licensed under the Apache License, Version 2.0 (the "License");
47777dab0Sopenharmony_ci * you may not use this file except in compliance with the License.
57777dab0Sopenharmony_ci * You may obtain a copy of the License at
67777dab0Sopenharmony_ci *
77777dab0Sopenharmony_ci *     http://www.apache.org/licenses/LICENSE-2.0
87777dab0Sopenharmony_ci *
97777dab0Sopenharmony_ci * Unless required by applicable law or agreed to in writing, software
107777dab0Sopenharmony_ci * distributed under the License is distributed on an "AS IS" BASIS,
117777dab0Sopenharmony_ci * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
127777dab0Sopenharmony_ci * See the License for the specific language governing permissions and
137777dab0Sopenharmony_ci * limitations under the License.
147777dab0Sopenharmony_ci */
157777dab0Sopenharmony_ci
167777dab0Sopenharmony_ci/**
177777dab0Sopenharmony_ci * @addtogroup ArkUI_EventModule
187777dab0Sopenharmony_ci * @{
197777dab0Sopenharmony_ci *
207777dab0Sopenharmony_ci * @brief Declares the UI input event capabilities provided by ArkUI on the native side.
217777dab0Sopenharmony_ci *
227777dab0Sopenharmony_ci * @since 12
237777dab0Sopenharmony_ci */
247777dab0Sopenharmony_ci
257777dab0Sopenharmony_ci/**
267777dab0Sopenharmony_ci * @file ui_input_event.h
277777dab0Sopenharmony_ci *
287777dab0Sopenharmony_ci * @brief Provides ArkUI event definitions on the native side.
297777dab0Sopenharmony_ci *
307777dab0Sopenharmony_ci * @library libace_ndk.z.so
317777dab0Sopenharmony_ci * @syscap SystemCapability.ArkUI.ArkUI.Full
327777dab0Sopenharmony_ci * @kit ArkUI
337777dab0Sopenharmony_ci * @since 12
347777dab0Sopenharmony_ci */
357777dab0Sopenharmony_ci
367777dab0Sopenharmony_ci#ifndef _ARKUI_UI_INPUT_EVENT_H_
377777dab0Sopenharmony_ci#define _ARKUI_UI_INPUT_EVENT_H_
387777dab0Sopenharmony_ci
397777dab0Sopenharmony_ci#include <stdint.h>
407777dab0Sopenharmony_ci
417777dab0Sopenharmony_ci#ifdef __cplusplus
427777dab0Sopenharmony_ciextern "C" {
437777dab0Sopenharmony_ci#endif
447777dab0Sopenharmony_ci
457777dab0Sopenharmony_ci/**
467777dab0Sopenharmony_ci * @brief Defines the UI input event.
477777dab0Sopenharmony_ci *
487777dab0Sopenharmony_ci * @since 12
497777dab0Sopenharmony_ci */
507777dab0Sopenharmony_citypedef struct ArkUI_UIInputEvent ArkUI_UIInputEvent;
517777dab0Sopenharmony_ci
527777dab0Sopenharmony_ci/**
537777dab0Sopenharmony_ci * @brief Enumerates the UI input event types.
547777dab0Sopenharmony_ci *
557777dab0Sopenharmony_ci * @since 12
567777dab0Sopenharmony_ci */
577777dab0Sopenharmony_citypedef enum {
587777dab0Sopenharmony_ci    ARKUI_UIINPUTEVENT_TYPE_UNKNOWN = 0,
597777dab0Sopenharmony_ci    ARKUI_UIINPUTEVENT_TYPE_TOUCH = 1,
607777dab0Sopenharmony_ci    ARKUI_UIINPUTEVENT_TYPE_AXIS = 2,
617777dab0Sopenharmony_ci    /** Mouse event. */
627777dab0Sopenharmony_ci    ARKUI_UIINPUTEVENT_TYPE_MOUSE = 3,
637777dab0Sopenharmony_ci} ArkUI_UIInputEvent_Type;
647777dab0Sopenharmony_ci
657777dab0Sopenharmony_ci/**
667777dab0Sopenharmony_ci * @brief Defines the action code of the input event.
677777dab0Sopenharmony_ci *
687777dab0Sopenharmony_ci * @since 12
697777dab0Sopenharmony_ci */
707777dab0Sopenharmony_cienum {
717777dab0Sopenharmony_ci    /** Cancellation of touch. */
727777dab0Sopenharmony_ci    UI_TOUCH_EVENT_ACTION_CANCEL = 0,
737777dab0Sopenharmony_ci    /** Pressing of a touch point. */
747777dab0Sopenharmony_ci    UI_TOUCH_EVENT_ACTION_DOWN = 1,
757777dab0Sopenharmony_ci    /** Moving of a touch point. */
767777dab0Sopenharmony_ci    UI_TOUCH_EVENT_ACTION_MOVE = 2,
777777dab0Sopenharmony_ci    /** Lifting of a touch point. */
787777dab0Sopenharmony_ci    UI_TOUCH_EVENT_ACTION_UP = 3,
797777dab0Sopenharmony_ci};
807777dab0Sopenharmony_ci
817777dab0Sopenharmony_ci/**
827777dab0Sopenharmony_ci * @brief Defines the tool type of the touch event.
837777dab0Sopenharmony_ci *
847777dab0Sopenharmony_ci * @since 12
857777dab0Sopenharmony_ci */
867777dab0Sopenharmony_cienum {
877777dab0Sopenharmony_ci    /** Unknown tool type. */
887777dab0Sopenharmony_ci    UI_INPUT_EVENT_TOOL_TYPE_UNKNOWN = 0,
897777dab0Sopenharmony_ci
907777dab0Sopenharmony_ci    /** Finger. */
917777dab0Sopenharmony_ci    UI_INPUT_EVENT_TOOL_TYPE_FINGER = 1,
927777dab0Sopenharmony_ci
937777dab0Sopenharmony_ci    /** Pen. */
947777dab0Sopenharmony_ci    UI_INPUT_EVENT_TOOL_TYPE_PEN = 2,
957777dab0Sopenharmony_ci
967777dab0Sopenharmony_ci    /** Mouse. */
977777dab0Sopenharmony_ci    UI_INPUT_EVENT_TOOL_TYPE_MOUSE = 3,
987777dab0Sopenharmony_ci
997777dab0Sopenharmony_ci    /** TouchPad. */
1007777dab0Sopenharmony_ci    UI_INPUT_EVENT_TOOL_TYPE_TOUCHPAD = 4,
1017777dab0Sopenharmony_ci
1027777dab0Sopenharmony_ci    /** JoyStick. */
1037777dab0Sopenharmony_ci    UI_INPUT_EVENT_TOOL_TYPE_JOYSTICK = 5,
1047777dab0Sopenharmony_ci};
1057777dab0Sopenharmony_ci
1067777dab0Sopenharmony_ci/**
1077777dab0Sopenharmony_ci * @brief Defines the source type of the touch event.
1087777dab0Sopenharmony_ci *
1097777dab0Sopenharmony_ci * @since 12
1107777dab0Sopenharmony_ci */
1117777dab0Sopenharmony_cienum {
1127777dab0Sopenharmony_ci    /** Unknown source type. */
1137777dab0Sopenharmony_ci    UI_INPUT_EVENT_SOURCE_TYPE_UNKNOWN = 0,
1147777dab0Sopenharmony_ci    /** Mouse. */
1157777dab0Sopenharmony_ci    UI_INPUT_EVENT_SOURCE_TYPE_MOUSE = 1,
1167777dab0Sopenharmony_ci    /** Touchscreen. */
1177777dab0Sopenharmony_ci    UI_INPUT_EVENT_SOURCE_TYPE_TOUCH_SCREEN = 2,
1187777dab0Sopenharmony_ci};
1197777dab0Sopenharmony_ci
1207777dab0Sopenharmony_ci/**
1217777dab0Sopenharmony_ci * @brief Enumerates the hit test modes.
1227777dab0Sopenharmony_ci *
1237777dab0Sopenharmony_ci * @since 12
1247777dab0Sopenharmony_ci */
1257777dab0Sopenharmony_citypedef enum {
1267777dab0Sopenharmony_ci    /** Both the node and its child node respond to the hit test of a touch event, but its sibling node is blocked from
1277777dab0Sopenharmony_ci     *  the hit test.
1287777dab0Sopenharmony_ci     */
1297777dab0Sopenharmony_ci    HTM_DEFAULT = 0,
1307777dab0Sopenharmony_ci
1317777dab0Sopenharmony_ci    /** The node responds to the hit test of a touch event, but its child node and sibling node are blocked from the hit
1327777dab0Sopenharmony_ci     *  test.
1337777dab0Sopenharmony_ci     */
1347777dab0Sopenharmony_ci    HTM_BLOCK,
1357777dab0Sopenharmony_ci
1367777dab0Sopenharmony_ci    /** Both the node and its child node respond to the hit test of a touch event, and its sibling node is also
1377777dab0Sopenharmony_ci     *  considered during the hit test.
1387777dab0Sopenharmony_ci     */
1397777dab0Sopenharmony_ci    HTM_TRANSPARENT,
1407777dab0Sopenharmony_ci
1417777dab0Sopenharmony_ci    /** The node does not respond to the hit test of a touch event, but its child node and sibling node are considered
1427777dab0Sopenharmony_ci     *  during the hit test.
1437777dab0Sopenharmony_ci     */
1447777dab0Sopenharmony_ci    HTM_NONE,
1457777dab0Sopenharmony_ci} HitTestMode;
1467777dab0Sopenharmony_ci
1477777dab0Sopenharmony_ci/**
1487777dab0Sopenharmony_ci * @brief Define the Action Code for mouse events.
1497777dab0Sopenharmony_ci *
1507777dab0Sopenharmony_ci * @since 12
1517777dab0Sopenharmony_ci */
1527777dab0Sopenharmony_cienum {
1537777dab0Sopenharmony_ci    /** Invalid. */
1547777dab0Sopenharmony_ci    UI_MOUSE_EVENT_ACTION_UNKNOWN = 0,
1557777dab0Sopenharmony_ci    /** Press. */
1567777dab0Sopenharmony_ci    UI_MOUSE_EVENT_ACTION_PRESS = 1,
1577777dab0Sopenharmony_ci    /** Release. */
1587777dab0Sopenharmony_ci    UI_MOUSE_EVENT_ACTION_RELEASE = 2,
1597777dab0Sopenharmony_ci    /** Move. */
1607777dab0Sopenharmony_ci    UI_MOUSE_EVENT_ACTION_MOVE = 3,
1617777dab0Sopenharmony_ci};
1627777dab0Sopenharmony_ci
1637777dab0Sopenharmony_ci/**
1647777dab0Sopenharmony_ci * @brief Define the button type for mouse events.
1657777dab0Sopenharmony_ci *
1667777dab0Sopenharmony_ci * @since 12
1677777dab0Sopenharmony_ci */
1687777dab0Sopenharmony_cienum {
1697777dab0Sopenharmony_ci    /** None. */
1707777dab0Sopenharmony_ci    UI_MOUSE_EVENT_BUTTON_NONE = 0,
1717777dab0Sopenharmony_ci    /** Left. */
1727777dab0Sopenharmony_ci    UI_MOUSE_EVENT_BUTTON_LEFT = 1,
1737777dab0Sopenharmony_ci    /** Right. */
1747777dab0Sopenharmony_ci    UI_MOUSE_EVENT_BUTTON_RIGHT = 2,
1757777dab0Sopenharmony_ci    /** Middle. */
1767777dab0Sopenharmony_ci    UI_MOUSE_EVENT_BUTTON_MIDDLE = 3,
1777777dab0Sopenharmony_ci    /** Back. */
1787777dab0Sopenharmony_ci    UI_MOUSE_EVENT_BUTTON_BACK = 4,
1797777dab0Sopenharmony_ci    /** Forward. */
1807777dab0Sopenharmony_ci    UI_MOUSE_EVENT_BUTTON_FORWARD = 5,
1817777dab0Sopenharmony_ci};
1827777dab0Sopenharmony_ci
1837777dab0Sopenharmony_ci/**
1847777dab0Sopenharmony_ci * @brief Defines an enum for modifier keys.
1857777dab0Sopenharmony_ci *
1867777dab0Sopenharmony_ci * @since 12
1877777dab0Sopenharmony_ci */
1887777dab0Sopenharmony_citypedef enum {
1897777dab0Sopenharmony_ci    /** Ctrl. */
1907777dab0Sopenharmony_ci    ARKUI_MODIFIER_KEY_CTRL = 1 << 0,
1917777dab0Sopenharmony_ci    /** Shift. */
1927777dab0Sopenharmony_ci    ARKUI_MODIFIER_KEY_SHIFT = 1 << 1,
1937777dab0Sopenharmony_ci    /** Alt. */
1947777dab0Sopenharmony_ci    ARKUI_MODIFIER_KEY_ALT = 1 << 2,
1957777dab0Sopenharmony_ci    /** Fn. */
1967777dab0Sopenharmony_ci    ARKUI_MODIFIER_KEY_FN = 1 << 3,
1977777dab0Sopenharmony_ci} ArkUI_ModifierKeyName;
1987777dab0Sopenharmony_ci
1997777dab0Sopenharmony_ci/**
2007777dab0Sopenharmony_ci * @brief Obtains the type of this UI input event.
2017777dab0Sopenharmony_ci *
2027777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
2037777dab0Sopenharmony_ci * @return Returns the type of the current UI input event; returns <b>0</b> if any parameter error occurs.
2047777dab0Sopenharmony_ci * @since 12
2057777dab0Sopenharmony_ci */
2067777dab0Sopenharmony_ciint32_t OH_ArkUI_UIInputEvent_GetType(const ArkUI_UIInputEvent* event);
2077777dab0Sopenharmony_ci
2087777dab0Sopenharmony_ci/**
2097777dab0Sopenharmony_ci * @brief Obtains the action type of this UI input event.
2107777dab0Sopenharmony_ci *
2117777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
2127777dab0Sopenharmony_ci * @return Returns the action type of the current UI input event; returns <b>0</b> if any parameter error occurs.
2137777dab0Sopenharmony_ci * @since 12
2147777dab0Sopenharmony_ci */
2157777dab0Sopenharmony_ciint32_t OH_ArkUI_UIInputEvent_GetAction(const ArkUI_UIInputEvent* event);
2167777dab0Sopenharmony_ci
2177777dab0Sopenharmony_ci/**
2187777dab0Sopenharmony_ci * @brief Obtains the source type of this UI input event.
2197777dab0Sopenharmony_ci *
2207777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
2217777dab0Sopenharmony_ci * @return Returns the source type of the current UI input event.
2227777dab0Sopenharmony_ci * @since 12
2237777dab0Sopenharmony_ci */
2247777dab0Sopenharmony_ciint32_t OH_ArkUI_UIInputEvent_GetSourceType(const ArkUI_UIInputEvent* event);
2257777dab0Sopenharmony_ci
2267777dab0Sopenharmony_ci/**
2277777dab0Sopenharmony_ci * @brief Obtains the tool type of this UI input event.
2287777dab0Sopenharmony_ci *
2297777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
2307777dab0Sopenharmony_ci * @return Returns the tool type of the current UI input event.
2317777dab0Sopenharmony_ci * @since 12
2327777dab0Sopenharmony_ci */
2337777dab0Sopenharmony_ciint32_t OH_ArkUI_UIInputEvent_GetToolType(const ArkUI_UIInputEvent* event);
2347777dab0Sopenharmony_ci
2357777dab0Sopenharmony_ci/**
2367777dab0Sopenharmony_ci * @brief Obtains the time when this UI input event occurs.
2377777dab0Sopenharmony_ci *
2387777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
2397777dab0Sopenharmony_ci * @return Returns the time when the UI input event occurs; returns <b>0</b> if any parameter error occurs.
2407777dab0Sopenharmony_ci * @since 12
2417777dab0Sopenharmony_ci */
2427777dab0Sopenharmony_ciint64_t OH_ArkUI_UIInputEvent_GetEventTime(const ArkUI_UIInputEvent* event);
2437777dab0Sopenharmony_ci
2447777dab0Sopenharmony_ci/**
2457777dab0Sopenharmony_ci * @brief Obtains the number of touch points from a directional input event (such as a touch event, mouse event,
2467777dab0Sopenharmony_ci * or axis event).
2477777dab0Sopenharmony_ci *
2487777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
2497777dab0Sopenharmony_ci * @return Returns the number of touch points for the directional input event.
2507777dab0Sopenharmony_ci * @since 12
2517777dab0Sopenharmony_ci */
2527777dab0Sopenharmony_ciuint32_t OH_ArkUI_PointerEvent_GetPointerCount(const ArkUI_UIInputEvent* event);
2537777dab0Sopenharmony_ci
2547777dab0Sopenharmony_ci/**
2557777dab0Sopenharmony_ci * @brief Obtains the ID of a touch point from a directional input event (such as a touch event, mouse event,
2567777dab0Sopenharmony_ci * or axis event).
2577777dab0Sopenharmony_ci *
2587777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
2597777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
2607777dab0Sopenharmony_ci * @return Returns the ID of the corresponding touch point.
2617777dab0Sopenharmony_ci * @since 12
2627777dab0Sopenharmony_ci */
2637777dab0Sopenharmony_ciint32_t OH_ArkUI_PointerEvent_GetPointerId(const ArkUI_UIInputEvent* event, uint32_t pointerIndex);
2647777dab0Sopenharmony_ci
2657777dab0Sopenharmony_ci/**
2667777dab0Sopenharmony_ci * @brief Obtains the X coordinate relative to the upper left corner of the current component from a directional
2677777dab0Sopenharmony_ci * input event (such as a touch event, mouse event, or axis event).
2687777dab0Sopenharmony_ci *
2697777dab0Sopenharmony_ci * @param event Indicates the pointer to the directional input event.
2707777dab0Sopenharmony_ci * @return Returns the X coordinate relative to the upper left corner of the current component;
2717777dab0Sopenharmony_ci * returns <b>0</b> if any parameter error occurs.
2727777dab0Sopenharmony_ci * @since 12
2737777dab0Sopenharmony_ci */
2747777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetX(const ArkUI_UIInputEvent* event);
2757777dab0Sopenharmony_ci
2767777dab0Sopenharmony_ci/**
2777777dab0Sopenharmony_ci * @brief Obtains the X coordinate of a specific touch point relative to the upper left corner of the current component
2787777dab0Sopenharmony_ci * from a directional input event (such as a touch event, mouse event, or axis event).
2797777dab0Sopenharmony_ci *
2807777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
2817777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
2827777dab0Sopenharmony_ci * @return Returns the X coordinate relative to the upper left corner of the current component;
2837777dab0Sopenharmony_ci * returns <b>0.0f</b> if any parameter error occurs.
2847777dab0Sopenharmony_ci * @since 12
2857777dab0Sopenharmony_ci */
2867777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetXByIndex(const ArkUI_UIInputEvent* event, uint32_t pointerIndex);
2877777dab0Sopenharmony_ci
2887777dab0Sopenharmony_ci/**
2897777dab0Sopenharmony_ci * @brief Obtains the Y coordinate relative to the upper left corner of the current component from a directional
2907777dab0Sopenharmony_ci * input event (such as a touch event, mouse event, or axis event).
2917777dab0Sopenharmony_ci *
2927777dab0Sopenharmony_ci * @param event Indicates the pointer to the UI input event.
2937777dab0Sopenharmony_ci * @return Returns the Y coordinate relative to the upper left corner of the current component;
2947777dab0Sopenharmony_ci * returns <b>0</b> if any parameter error occurs.
2957777dab0Sopenharmony_ci * @since 12
2967777dab0Sopenharmony_ci */
2977777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetY(const ArkUI_UIInputEvent* event);
2987777dab0Sopenharmony_ci
2997777dab0Sopenharmony_ci/**
3007777dab0Sopenharmony_ci * @brief Obtains the Y coordinate of a specific touch point relative to the upper left corner of the current component
3017777dab0Sopenharmony_ci * from a directional input event (such as a touch event, mouse event, or axis event).
3027777dab0Sopenharmony_ci *
3037777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
3047777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
3057777dab0Sopenharmony_ci * @return Returns the Y coordinate relative to the upper left corner of the current component;
3067777dab0Sopenharmony_ci * returns <b>0.0f</b> if any parameter error occurs.
3077777dab0Sopenharmony_ci * @since 12
3087777dab0Sopenharmony_ci */
3097777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetYByIndex(const ArkUI_UIInputEvent* event, uint32_t pointerIndex);
3107777dab0Sopenharmony_ci
3117777dab0Sopenharmony_ci/**
3127777dab0Sopenharmony_ci * @brief Obtains the X coordinate relative to the upper left corner of the current application window from a
3137777dab0Sopenharmony_ci * directional input event (such as a touch event, mouse event, or axis event).
3147777dab0Sopenharmony_ci *
3157777dab0Sopenharmony_ci * @param event Indicates the pointer to the UI input event.
3167777dab0Sopenharmony_ci * @return Returns the X coordinate relative to the upper left corner of the current application window;
3177777dab0Sopenharmony_ci * returns <b>0</b> if any parameter error occurs.
3187777dab0Sopenharmony_ci * @since 12
3197777dab0Sopenharmony_ci */
3207777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetWindowX(const ArkUI_UIInputEvent* event);
3217777dab0Sopenharmony_ci
3227777dab0Sopenharmony_ci/**
3237777dab0Sopenharmony_ci * @brief Obtains the X coordinate of a specific touch point relative to the upper left corner of the current
3247777dab0Sopenharmony_ci * application window from a directional input event (such as a touch event, mouse event, or axis event).
3257777dab0Sopenharmony_ci *
3267777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
3277777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
3287777dab0Sopenharmony_ci * @return Returns the X coordinate relative to the upper left corner of the current application window;
3297777dab0Sopenharmony_ci * returns <b>0.0f</b> if any parameter error occurs.
3307777dab0Sopenharmony_ci * @since 12
3317777dab0Sopenharmony_ci */
3327777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetWindowXByIndex(const ArkUI_UIInputEvent* event, uint32_t pointerIndex);
3337777dab0Sopenharmony_ci
3347777dab0Sopenharmony_ci/**
3357777dab0Sopenharmony_ci * @brief Obtains the Y coordinate relative to the upper left corner of the current application window from a
3367777dab0Sopenharmony_ci * directional input event (such as a touch event, mouse event, or axis event).
3377777dab0Sopenharmony_ci *
3387777dab0Sopenharmony_ci * @param event Indicates the pointer to the UI input event.
3397777dab0Sopenharmony_ci * @return Returns the Y coordinate relative to the upper left corner of the current application window;
3407777dab0Sopenharmony_ci * returns <b>0</b> if any parameter error occurs.
3417777dab0Sopenharmony_ci * @since 12
3427777dab0Sopenharmony_ci */
3437777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetWindowY(const ArkUI_UIInputEvent* event);
3447777dab0Sopenharmony_ci
3457777dab0Sopenharmony_ci/**
3467777dab0Sopenharmony_ci * @brief Obtains the Y coordinate of a specific touch point relative to the upper left corner of the current
3477777dab0Sopenharmony_ci * application window from a directional input event (such as a touch event, mouse event, or axis event).
3487777dab0Sopenharmony_ci *
3497777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
3507777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
3517777dab0Sopenharmony_ci * @return Returns the Y coordinate relative to the upper left corner of the current application window;
3527777dab0Sopenharmony_ci * returns <b>0.0f</b> if any parameter error occurs.
3537777dab0Sopenharmony_ci * @since 12
3547777dab0Sopenharmony_ci */
3557777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetWindowYByIndex(const ArkUI_UIInputEvent* event, uint32_t pointerIndex);
3567777dab0Sopenharmony_ci
3577777dab0Sopenharmony_ci/**
3587777dab0Sopenharmony_ci * @brief Obtains the X coordinate relative to the upper left corner of the current screen from a directional input
3597777dab0Sopenharmony_ci * event (such as a touch event, mouse event, or axis event).
3607777dab0Sopenharmony_ci *
3617777dab0Sopenharmony_ci * @param event Indicates the pointer to the UI input event.
3627777dab0Sopenharmony_ci * @return Returns the X coordinate relative to the upper left corner of the current screen;
3637777dab0Sopenharmony_ci * returns <b>0</b> if any parameter error occurs.
3647777dab0Sopenharmony_ci * @since 12
3657777dab0Sopenharmony_ci */
3667777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetDisplayX(const ArkUI_UIInputEvent* event);
3677777dab0Sopenharmony_ci
3687777dab0Sopenharmony_ci/**
3697777dab0Sopenharmony_ci * @brief Obtains the X coordinate of a specific touch point relative to the upper left corner of the current screen
3707777dab0Sopenharmony_ci * from a directional input event (such as a touch event, mouse event, or axis event).
3717777dab0Sopenharmony_ci *
3727777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
3737777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
3747777dab0Sopenharmony_ci * @return Returns the X coordinate relative to the upper left corner of the current screen;
3757777dab0Sopenharmony_ci * returns <b>0.0f</b> if any parameter error occurs.
3767777dab0Sopenharmony_ci * @since 12
3777777dab0Sopenharmony_ci */
3787777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetDisplayXByIndex(const ArkUI_UIInputEvent* event, uint32_t pointerIndex);
3797777dab0Sopenharmony_ci
3807777dab0Sopenharmony_ci/**
3817777dab0Sopenharmony_ci * @brief Obtains the Y coordinate relative to the upper left corner of the current screen from a directional input
3827777dab0Sopenharmony_ci * event (such as a touch event, mouse event, or axis event).
3837777dab0Sopenharmony_ci *
3847777dab0Sopenharmony_ci * @param event Indicates the pointer to the UI input event.
3857777dab0Sopenharmony_ci * @return Returns the Y coordinate relative to the upper left corner of the current screen;
3867777dab0Sopenharmony_ci * returns <b>0</b> if any parameter error occurs.
3877777dab0Sopenharmony_ci * @since 12
3887777dab0Sopenharmony_ci */
3897777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetDisplayY(const ArkUI_UIInputEvent* event);
3907777dab0Sopenharmony_ci
3917777dab0Sopenharmony_ci/**
3927777dab0Sopenharmony_ci * @brief Obtains the Y coordinate of a specific touch point relative to the upper left corner of the current screen
3937777dab0Sopenharmony_ci * from a directional input event (such as a touch event, mouse event, or axis event).
3947777dab0Sopenharmony_ci *
3957777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
3967777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
3977777dab0Sopenharmony_ci * @return Returns the Y coordinate relative to the upper left corner of the current screen;
3987777dab0Sopenharmony_ci * returns <b>0.0f</b> if any parameter error occurs.
3997777dab0Sopenharmony_ci * @since 12
4007777dab0Sopenharmony_ci */
4017777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetDisplayYByIndex(const ArkUI_UIInputEvent* event, uint32_t pointerIndex);
4027777dab0Sopenharmony_ci
4037777dab0Sopenharmony_ci/**
4047777dab0Sopenharmony_ci * @brief Obtains the pressure applied to the touchscreen from a directional input event (for example, a touch event).
4057777dab0Sopenharmony_ci *
4067777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
4077777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
4087777dab0Sopenharmony_ci * @return Returns the pressure applied to the touchscreen; returns <b>0.0f</b> if any parameter error occurs.
4097777dab0Sopenharmony_ci * @since 12
4107777dab0Sopenharmony_ci */
4117777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetPressure(const ArkUI_UIInputEvent* event, uint32_t pointerIndex);
4127777dab0Sopenharmony_ci
4137777dab0Sopenharmony_ci/**
4147777dab0Sopenharmony_ci * @brief Obtains the angle relative to the YZ plane from a directional input event (for example, a touch event).
4157777dab0Sopenharmony_ci * The value range is [-90, 90]. A positive value indicates a rightward tilt.
4167777dab0Sopenharmony_ci *
4177777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
4187777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
4197777dab0Sopenharmony_ci * @return Returns the angle relative to the YZ plane.
4207777dab0Sopenharmony_ci * @since 12
4217777dab0Sopenharmony_ci */
4227777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetTiltX(const ArkUI_UIInputEvent* event, uint32_t pointerIndex);
4237777dab0Sopenharmony_ci
4247777dab0Sopenharmony_ci/**
4257777dab0Sopenharmony_ci * @brief Obtains the angle relative to the XZ plane from a directional input event (for example, a touch event).
4267777dab0Sopenharmony_ci * The value range is [-90, 90]. A positive value indicates a downward tilt.
4277777dab0Sopenharmony_ci *
4287777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
4297777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
4307777dab0Sopenharmony_ci * @return Returns the angle relative to the XZ plane.
4317777dab0Sopenharmony_ci * @since 12
4327777dab0Sopenharmony_ci */
4337777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetTiltY(const ArkUI_UIInputEvent* event, uint32_t pointerIndex);
4347777dab0Sopenharmony_ci
4357777dab0Sopenharmony_ci/**
4367777dab0Sopenharmony_ci * @brief Obtains the width of the touch area from a directional input event (for example, a touch event).
4377777dab0Sopenharmony_ci *
4387777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
4397777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
4407777dab0Sopenharmony_ci * @return Returns the width of the touch area.
4417777dab0Sopenharmony_ci * @since 12
4427777dab0Sopenharmony_ci */
4437777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetTouchAreaWidth(const ArkUI_UIInputEvent* event, uint32_t pointerIndex);
4447777dab0Sopenharmony_ci
4457777dab0Sopenharmony_ci/**
4467777dab0Sopenharmony_ci * @brief Obtains the height of the touch area from a directional input event (for example, a touch event).
4477777dab0Sopenharmony_ci *
4487777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
4497777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
4507777dab0Sopenharmony_ci * @return Returns the height of the touch area.
4517777dab0Sopenharmony_ci * @since 12
4527777dab0Sopenharmony_ci */
4537777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetTouchAreaHeight(const ArkUI_UIInputEvent* event, uint32_t pointerIndex);
4547777dab0Sopenharmony_ci
4557777dab0Sopenharmony_ci/**
4567777dab0Sopenharmony_ci * @brief Obtains the number of historical events from a directional input event (such as a touch event, mouse event,
4577777dab0Sopenharmony_ci * or axis event).
4587777dab0Sopenharmony_ci *
4597777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
4607777dab0Sopenharmony_ci * @return Returns the number of historical events.
4617777dab0Sopenharmony_ci * @since 12
4627777dab0Sopenharmony_ci */
4637777dab0Sopenharmony_ciuint32_t OH_ArkUI_PointerEvent_GetHistorySize(const ArkUI_UIInputEvent* event);
4647777dab0Sopenharmony_ci
4657777dab0Sopenharmony_ci/**
4667777dab0Sopenharmony_ci * @brief Obtains the occurrence time of a historical event from a directional input event (such as a touch event,
4677777dab0Sopenharmony_ci * mouse event, or axis event).
4687777dab0Sopenharmony_ci *
4697777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
4707777dab0Sopenharmony_ci * @param historyIndex Indicates the index of the target historical event.
4717777dab0Sopenharmony_ci * @return Returns the time when the UI input event occurs; returns <b>0</b> if any parameter error occurs.
4727777dab0Sopenharmony_ci * @since 12
4737777dab0Sopenharmony_ci */
4747777dab0Sopenharmony_ciint64_t OH_ArkUI_PointerEvent_GetHistoryEventTime(const ArkUI_UIInputEvent* event, uint32_t historyIndex);
4757777dab0Sopenharmony_ci
4767777dab0Sopenharmony_ci/**
4777777dab0Sopenharmony_ci * @brief Obtains the number of touch points in a specific historical event from a directional input event (such as
4787777dab0Sopenharmony_ci * a touch event, mouse event, or axis event).
4797777dab0Sopenharmony_ci *
4807777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
4817777dab0Sopenharmony_ci * @param historyIndex Indicates the index of the target historical event.
4827777dab0Sopenharmony_ci * @return Returns the number of touch points in the specified historical event
4837777dab0Sopenharmony_ci * @since 12
4847777dab0Sopenharmony_ci */
4857777dab0Sopenharmony_ciuint32_t OH_ArkUI_PointerEvent_GetHistoryPointerCount(const ArkUI_UIInputEvent* event, uint32_t historyIndex);
4867777dab0Sopenharmony_ci
4877777dab0Sopenharmony_ci/**
4887777dab0Sopenharmony_ci * @brief Obtains the ID of a touch point in a specific historical event from a directional input event (such as
4897777dab0Sopenharmony_ci * a touch event, mouse event, or axis event).
4907777dab0Sopenharmony_ci *
4917777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
4927777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
4937777dab0Sopenharmony_ci * @param historyIndex Indicates the index of the target historical event.
4947777dab0Sopenharmony_ci * @return Returns the ID of the corresponding touch point in the specified historical event.
4957777dab0Sopenharmony_ci * @since 12
4967777dab0Sopenharmony_ci */
4977777dab0Sopenharmony_ciint32_t OH_ArkUI_PointerEvent_GetHistoryPointerId(
4987777dab0Sopenharmony_ci    const ArkUI_UIInputEvent* event, uint32_t pointerIndex, uint32_t historyIndex);
4997777dab0Sopenharmony_ci
5007777dab0Sopenharmony_ci/**
5017777dab0Sopenharmony_ci * @brief Obtains the X coordinate of a specific touch point in a historical event relative to the upper left corner
5027777dab0Sopenharmony_ci * of the current component from a directional input event (such as a touch event, mouse event, or axis event).
5037777dab0Sopenharmony_ci *
5047777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
5057777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
5067777dab0Sopenharmony_ci * @param historyIndex Indicates the index of the target historical event.
5077777dab0Sopenharmony_ci * @return Returns the X coordinate relative to the upper left corner of the current component;
5087777dab0Sopenharmony_ci * returns <b>0.0f</b> if any parameter error occurs.
5097777dab0Sopenharmony_ci * @since 12
5107777dab0Sopenharmony_ci */
5117777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetHistoryX(const ArkUI_UIInputEvent* event, uint32_t pointerIndex, uint32_t historyIndex);
5127777dab0Sopenharmony_ci
5137777dab0Sopenharmony_ci/**
5147777dab0Sopenharmony_ci * @brief Obtains the Y coordinate of a specific touch point in a historical event relative to the upper left corner
5157777dab0Sopenharmony_ci * of the current component from a directional input event (such as a touch event, mouse event, or axis event).
5167777dab0Sopenharmony_ci *
5177777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
5187777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
5197777dab0Sopenharmony_ci * @param historyIndex Indicates the index of the target historical event.
5207777dab0Sopenharmony_ci * @return Returns the Y coordinate relative to the upper left corner of the current component;
5217777dab0Sopenharmony_ci * returns <b>0.0f</b> if any parameter error occurs.
5227777dab0Sopenharmony_ci * @since 12
5237777dab0Sopenharmony_ci */
5247777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetHistoryY(const ArkUI_UIInputEvent* event, uint32_t pointerIndex, uint32_t historyIndex);
5257777dab0Sopenharmony_ci
5267777dab0Sopenharmony_ci/**
5277777dab0Sopenharmony_ci * @brief Obtains the X coordinate of a specific touch point in a historical event relative to the upper left corner
5287777dab0Sopenharmony_ci * of the current application window from a directional input event (such as a touch event, mouse event, or axis event).
5297777dab0Sopenharmony_ci *
5307777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
5317777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
5327777dab0Sopenharmony_ci * @param historyIndex Indicates the index of the target historical event.
5337777dab0Sopenharmony_ci * @return Returns the X coordinate relative to the upper left corner of the current application window;
5347777dab0Sopenharmony_ci * returns <b>0.0f</b> if any parameter error occurs.
5357777dab0Sopenharmony_ci * @since 12
5367777dab0Sopenharmony_ci */
5377777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetHistoryWindowX(
5387777dab0Sopenharmony_ci    const ArkUI_UIInputEvent* event, uint32_t pointerIndex, uint32_t historyIndex);
5397777dab0Sopenharmony_ci
5407777dab0Sopenharmony_ci/**
5417777dab0Sopenharmony_ci * @brief Obtains the Y coordinate of a specific touch point in a historical event relative to the upper left corner
5427777dab0Sopenharmony_ci * of the current application window from a directional input event (such as a touch event, mouse event, or axis event).
5437777dab0Sopenharmony_ci *
5447777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
5457777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
5467777dab0Sopenharmony_ci * @param historyIndex Indicates the index of the target historical event.
5477777dab0Sopenharmony_ci * @return Returns the Y coordinate relative to the upper left corner of the current application window;
5487777dab0Sopenharmony_ci * returns <b>0.0f</b> if any parameter error occurs.
5497777dab0Sopenharmony_ci * @since 12
5507777dab0Sopenharmony_ci */
5517777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetHistoryWindowY(
5527777dab0Sopenharmony_ci    const ArkUI_UIInputEvent* event, uint32_t pointerIndex, uint32_t historyIndex);
5537777dab0Sopenharmony_ci
5547777dab0Sopenharmony_ci/**
5557777dab0Sopenharmony_ci * @brief Obtains the X coordinate of a specific touch point in a historical event relative to the upper left corner
5567777dab0Sopenharmony_ci * of the current screen from a directional input event (such as a touch event, mouse event, or axis event).
5577777dab0Sopenharmony_ci *
5587777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
5597777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
5607777dab0Sopenharmony_ci * @param historyIndex Indicates the index of the target historical event.
5617777dab0Sopenharmony_ci * @return Returns the X coordinate relative to the upper left corner of the current screen;
5627777dab0Sopenharmony_ci * returns <b>0.0f</b> if any parameter error occurs.
5637777dab0Sopenharmony_ci * @since 12
5647777dab0Sopenharmony_ci */
5657777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetHistoryDisplayX(
5667777dab0Sopenharmony_ci    const ArkUI_UIInputEvent* event, uint32_t pointerIndex, uint32_t historyIndex);
5677777dab0Sopenharmony_ci
5687777dab0Sopenharmony_ci/**
5697777dab0Sopenharmony_ci * @brief Obtains the Y coordinate of a specific touch point in a historical event relative to the upper left corner
5707777dab0Sopenharmony_ci * of the current screen from a directional input event (such as a touch event, mouse event, or axis event).
5717777dab0Sopenharmony_ci *
5727777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
5737777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
5747777dab0Sopenharmony_ci * @param historyIndex Indicates the index of the target historical event.
5757777dab0Sopenharmony_ci * @return Returns the Y coordinate relative to the upper left corner of the current screen;
5767777dab0Sopenharmony_ci * returns <b>0.0f</b> if any parameter error occurs.
5777777dab0Sopenharmony_ci * @since 12
5787777dab0Sopenharmony_ci */
5797777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetHistoryDisplayY(
5807777dab0Sopenharmony_ci    const ArkUI_UIInputEvent* event, uint32_t pointerIndex, uint32_t historyIndex);
5817777dab0Sopenharmony_ci
5827777dab0Sopenharmony_ci/**
5837777dab0Sopenharmony_ci * @brief Obtains the pressure applied to the touchscreen in a specific historical event from a directional input event
5847777dab0Sopenharmony_ci * (for example, a touch event)..
5857777dab0Sopenharmony_ci *
5867777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
5877777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
5887777dab0Sopenharmony_ci * @param historyIndex Indicates the index of the target historical event.
5897777dab0Sopenharmony_ci * @return Returns the pressure applied to the touchscreen; returns <b>0.0f</b> if any parameter error occurs.
5907777dab0Sopenharmony_ci * @since 12
5917777dab0Sopenharmony_ci */
5927777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetHistoryPressure(
5937777dab0Sopenharmony_ci    const ArkUI_UIInputEvent* event, uint32_t pointerIndex, uint32_t historyIndex);
5947777dab0Sopenharmony_ci
5957777dab0Sopenharmony_ci/**
5967777dab0Sopenharmony_ci * @brief Obtains the angle relative to the YZ plane in a specific historical event from a directional input event
5977777dab0Sopenharmony_ci * (for example, a touch event). The value range is [-90, 90]. A positive value indicates a rightward tilt.
5987777dab0Sopenharmony_ci *
5997777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
6007777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
6017777dab0Sopenharmony_ci * @param historyIndex Indicates the index of the target historical event.
6027777dab0Sopenharmony_ci * @return Returns the angle relative to the YZ plane.
6037777dab0Sopenharmony_ci * @since 12
6047777dab0Sopenharmony_ci */
6057777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetHistoryTiltX(
6067777dab0Sopenharmony_ci    const ArkUI_UIInputEvent* event, uint32_t pointerIndex, uint32_t historyIndex);
6077777dab0Sopenharmony_ci
6087777dab0Sopenharmony_ci/**
6097777dab0Sopenharmony_ci * @brief Obtains the angle relative to the XZ plane in a specific historical event from a directional input event
6107777dab0Sopenharmony_ci * (for example, a touch event). The value range is [-90, 90]. A positive value indicates a downward tilt.
6117777dab0Sopenharmony_ci *
6127777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
6137777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
6147777dab0Sopenharmony_ci * @param historyIndex Indicates the index of the target historical event.
6157777dab0Sopenharmony_ci * @return Returns the angle relative to the XZ plane.
6167777dab0Sopenharmony_ci * @since 12
6177777dab0Sopenharmony_ci */
6187777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetHistoryTiltY(
6197777dab0Sopenharmony_ci    const ArkUI_UIInputEvent* event, uint32_t pointerIndex, uint32_t historyIndex);
6207777dab0Sopenharmony_ci
6217777dab0Sopenharmony_ci/**
6227777dab0Sopenharmony_ci * @brief Obtains the width of the touch area in a specific historical event from a directional input event
6237777dab0Sopenharmony_ci * (for example, a touch event).
6247777dab0Sopenharmony_ci *
6257777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
6267777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
6277777dab0Sopenharmony_ci * @param historyIndex Indicates the index of the target historical event.
6287777dab0Sopenharmony_ci * @return Returns the width of the touch area.
6297777dab0Sopenharmony_ci * @since 12
6307777dab0Sopenharmony_ci */
6317777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetHistoryTouchAreaWidth(
6327777dab0Sopenharmony_ci    const ArkUI_UIInputEvent* event, uint32_t pointerIndex, uint32_t historyIndex);
6337777dab0Sopenharmony_ci
6347777dab0Sopenharmony_ci/**
6357777dab0Sopenharmony_ci * @brief Obtains the height of the touch area in a specific historical event from a directional input event
6367777dab0Sopenharmony_ci * (for example, a touch event).
6377777dab0Sopenharmony_ci *
6387777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
6397777dab0Sopenharmony_ci * @param pointerIndex Indicates the index of the target touch point in the multi-touch data list.
6407777dab0Sopenharmony_ci * @param historyIndex Indicates the index of the target historical event.
6417777dab0Sopenharmony_ci * @return Returns the height of the touch area.
6427777dab0Sopenharmony_ci * @since 12
6437777dab0Sopenharmony_ci */
6447777dab0Sopenharmony_cifloat OH_ArkUI_PointerEvent_GetHistoryTouchAreaHeight(
6457777dab0Sopenharmony_ci    const ArkUI_UIInputEvent* event, uint32_t pointerIndex, uint32_t historyIndex);
6467777dab0Sopenharmony_ci
6477777dab0Sopenharmony_ci/**
6487777dab0Sopenharmony_ci * @brief Obtains the value of the vertical scroll axis for this axis event.
6497777dab0Sopenharmony_ci *
6507777dab0Sopenharmony_ci * @param event Indicates the pointer to the UI input event.
6517777dab0Sopenharmony_ci * @return Returns the value of the vertical scroll axis of the current axis event;
6527777dab0Sopenharmony_ci * returns <b>0</b> if any parameter error occurs.
6537777dab0Sopenharmony_ci * @since 12
6547777dab0Sopenharmony_ci */
6557777dab0Sopenharmony_cidouble OH_ArkUI_AxisEvent_GetVerticalAxisValue(const ArkUI_UIInputEvent* event);
6567777dab0Sopenharmony_ci
6577777dab0Sopenharmony_ci/**
6587777dab0Sopenharmony_ci * @brief Obtains the value of the horizontal scroll axis for this axis event.
6597777dab0Sopenharmony_ci *
6607777dab0Sopenharmony_ci * @param event Indicates the pointer to the UI input event.
6617777dab0Sopenharmony_ci * @return Returns the value of the horizontal scroll axis of the current axis event;
6627777dab0Sopenharmony_ci * returns <b>0</b> if any parameter error occurs.
6637777dab0Sopenharmony_ci * @since 12
6647777dab0Sopenharmony_ci */
6657777dab0Sopenharmony_cidouble OH_ArkUI_AxisEvent_GetHorizontalAxisValue(const ArkUI_UIInputEvent* event);
6667777dab0Sopenharmony_ci
6677777dab0Sopenharmony_ci/**
6687777dab0Sopenharmony_ci * @brief Obtains the scale value of the pinch axis for this axis event.
6697777dab0Sopenharmony_ci *
6707777dab0Sopenharmony_ci * @param event Indicates the pointer to the UI input event.
6717777dab0Sopenharmony_ci * @return Returns the scale value of the pinch axis of the current axis event;
6727777dab0Sopenharmony_ci * returns <b>0</b> if any parameter error occurs.
6737777dab0Sopenharmony_ci * @since 12
6747777dab0Sopenharmony_ci */
6757777dab0Sopenharmony_cidouble OH_ArkUI_AxisEvent_GetPinchAxisScaleValue(const ArkUI_UIInputEvent* event);
6767777dab0Sopenharmony_ci
6777777dab0Sopenharmony_ci/**
6787777dab0Sopenharmony_ci * @brief Sets how the component behaves during hit testing.
6797777dab0Sopenharmony_ci *
6807777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
6817777dab0Sopenharmony_ci * @param mode Indicates how the component behaves during hit testing. The parameter type is {@link HitTestMode}.
6827777dab0Sopenharmony_ci * @return Returns the status code of the execution.
6837777dab0Sopenharmony_ci * @since 12
6847777dab0Sopenharmony_ci */
6857777dab0Sopenharmony_ciint32_t OH_ArkUI_PointerEvent_SetInterceptHitTestMode(const ArkUI_UIInputEvent* event, HitTestMode mode);
6867777dab0Sopenharmony_ci
6877777dab0Sopenharmony_ci/**
6887777dab0Sopenharmony_ci * @brief Get the value of the button type for mouse events.
6897777dab0Sopenharmony_ci *
6907777dab0Sopenharmony_ci * @param event Represents a pointer to the current UI input event.
6917777dab0Sopenharmony_ci * @return Return to the mouse button type, where <b>1</b> is the left button, <b>2</b> is the right button,
6927777dab0Sopenharmony_ci * <b>3</b> is the middle button, <b>4</b> is the back button, and <b>5</b> is the forward button.
6937777dab0Sopenharmony_ci * @since 12
6947777dab0Sopenharmony_ci */
6957777dab0Sopenharmony_ciint32_t OH_ArkUI_MouseEvent_GetMouseButton(const ArkUI_UIInputEvent* event);
6967777dab0Sopenharmony_ci
6977777dab0Sopenharmony_ci/**
6987777dab0Sopenharmony_ci * @brief Get the value of the mouse action type for mouse events.
6997777dab0Sopenharmony_ci *
7007777dab0Sopenharmony_ci * @param event Represents a pointer to the current UI input event.
7017777dab0Sopenharmony_ci * @return Returns the type of mouse action, where <b>1</b> represents button pressed,
7027777dab0Sopenharmony_ci * <b>2</b> represents button released, and <b>3</b> represents mouse movement.
7037777dab0Sopenharmony_ci * @since 12
7047777dab0Sopenharmony_ci */
7057777dab0Sopenharmony_ciint32_t OH_ArkUI_MouseEvent_GetMouseAction(const ArkUI_UIInputEvent* event);
7067777dab0Sopenharmony_ci
7077777dab0Sopenharmony_ci/**
7087777dab0Sopenharmony_ci * @brief Sets whether to prevent event bubbling.
7097777dab0Sopenharmony_ci *
7107777dab0Sopenharmony_ci * @param event Indicates the pointer to the current UI input event.
7117777dab0Sopenharmony_ci * @param stopPropagation Indicates whether the event is prevented from bubbling.
7127777dab0Sopenharmony_ci * @return Returns the status code of the execution. If 0 is returned, the setting is successful.
7137777dab0Sopenharmony_ci *         If 401 is returned, the execution fails.
7147777dab0Sopenharmony_ci *         The possible cause of the failure is that the event parameter is abnormal, such as a null pointer.
7157777dab0Sopenharmony_ci * @since 12
7167777dab0Sopenharmony_ci */
7177777dab0Sopenharmony_ciint32_t OH_ArkUI_PointerEvent_SetStopPropagation(const ArkUI_UIInputEvent* event, bool stopPropagation);
7187777dab0Sopenharmony_ci
7197777dab0Sopenharmony_ci#ifdef __cplusplus
7207777dab0Sopenharmony_ci};
7217777dab0Sopenharmony_ci#endif
7227777dab0Sopenharmony_ci
7237777dab0Sopenharmony_ci#endif // _ARKUI_UI_INPUT_EVENT_H_
7247777dab0Sopenharmony_ci/** @} */
725