openharmony 鸿蒙 js-apis-multimodalinput-gestureevent

2025-06-16 浏览 (1)

@ohos.multimodalInput.gestureEvent (手势事件)

设备上报的手势事件。

说明:

本模块首批接口从API version 10开始支持。后续版本的新增接口,采用上角标单独标记接口的起始版本。

导入模块

import { Rotate, Pinch, ThreeFingersSwipe, FourFingersSwipe, ActionType } from '@kit.InputKit';

Pinch

捏合事件。

系统能力:SystemCapability.MultimodalInput.Input.Core

名称类型只读可选说明
typeActionType捏合事件类型。
scalenumber捏合度,取值范围大于等于0。

Rotate11+

旋转事件。

系统能力:SystemCapability.MultimodalInput.Input.Core

名称类型只读可选说明
typeActionType旋转事件类型。
anglenumber旋转角度。

ThreeFingersSwipe

三指滑动事件。

系统能力:SystemCapability.MultimodalInput.Input.Core

名称类型只读可选说明
typeActionType三指滑动事件类型。
xnumber坐标x。
ynumber坐标y。

FourFingersSwipe

四指滑动事件。

系统能力:SystemCapability.MultimodalInput.Input.Core

名称类型只读可选说明
typeActionType四指滑动事件类型。
xnumber坐标x。
ynumber坐标y。

ThreeFingersTap11+

三指轻点事件。

系统能力:SystemCapability.MultimodalInput.Input.Core

名称类型只读可选说明
typeActionType三指轻点事件类型。

ActionType

手势事件类型。

系统能力:SystemCapability.MultimodalInput.Input.Core

名称说明
CANCEL0取消。
BEGIN1手势开始。
UPDATE2手势更新。
END3手势结束。

你可能感兴趣的鸿蒙文章

harmony 鸿蒙Input Kit(多模输入服务)

harmony 鸿蒙Input_AxisEvent

harmony 鸿蒙Input_DeviceInfo

harmony 鸿蒙Input_DeviceListener

harmony 鸿蒙Input_Hotkey

harmony 鸿蒙Input_InterceptorEventCallback

harmony 鸿蒙Input_InterceptorOptions

harmony 鸿蒙Input_KeyEvent

harmony 鸿蒙Input_KeyState

harmony 鸿蒙Input_MouseEvent

  • 所属分类: 后端技术
  • 本文标签: 软件 鸿蒙
  • 版权声明: 本文链接 https://seaxiang.com/blog/aExjf0