mirror of
https://gitee.com/openharmony/arkui_ace_engine
synced 2025-01-24 02:59:30 +00:00
update native interface defines
Signed-off-by: yan-shuifeng <yanshuifeng@huawei.com> Change-Id: I4a9e8d9790ec4da31be2157f5c33e9f68da4ccd3
This commit is contained in:
parent
9fcd740122
commit
27cf1e8092
@ -46,7 +46,6 @@ ColumnLimit: 120
|
||||
CommentPragmas: '^ IWYU pragma:'
|
||||
QualifierAlignment: Leave
|
||||
ReflowComments: false
|
||||
PenaltyBreakComment: 1000000
|
||||
CompactNamespaces: false
|
||||
ConstructorInitializerAllOnOneLineOrOnePerLine: false
|
||||
ConstructorInitializerIndentWidth: 4
|
||||
@ -86,7 +85,6 @@ PenaltyBreakString: 1000
|
||||
PenaltyExcessCharacter: 1000000
|
||||
PenaltyReturnTypeOnItsOwnLine: 80
|
||||
PointerAlignment: Left
|
||||
ReflowComments: true
|
||||
SortIncludes: true
|
||||
SortUsingDeclarations: true
|
||||
SpaceAfterCStyleCast: false
|
||||
|
@ -199,7 +199,7 @@ typedef struct {
|
||||
|
||||
/**
|
||||
* @brief 返回此事件中的历史点信息。这些是在此事件和上一个事件之间发生的运动。
|
||||
* @param points 用来接受数据的指针对象。
|
||||
* @param historicalPoints 用来接受数据的指针对象。
|
||||
* @return 历史点数据数组元素数量。
|
||||
* @note
|
||||
* 框架会在该函数调用时创建历史点数据数组的堆内存对象并返回指针,开发者需要在使用完成后调用delete[]手动释放内存。
|
||||
|
@ -65,6 +65,16 @@ typedef enum {
|
||||
ARKUI_NATIVE_NODE,
|
||||
} ArkUI_NativeAPIVariantKind;
|
||||
|
||||
/**
|
||||
* @brief 定义ARKUI_NATIVE_NODE类型支持的版本号信息。
|
||||
*
|
||||
* @since 12
|
||||
*/
|
||||
typedef enum {
|
||||
/** ARKUI_NATIVE_NODE类型支持版本1的结构体{@link ArkUI_NativeNodeAPI_1}。*/
|
||||
ARKUI_NATIVE_NODE_VERSION_1,
|
||||
} ArkUI_NativeNodeAPIVersion;
|
||||
|
||||
/**
|
||||
* @brief 获取指定版本的Native接口集合。
|
||||
*
|
||||
@ -85,6 +95,26 @@ typedef enum {
|
||||
*/
|
||||
ArkUI_AnyNativeAPI* OH_ArkUI_GetNativeAPI(ArkUI_NativeAPIVariantKind type, int32_t version);
|
||||
|
||||
/**
|
||||
* @brief 获取指定版本的Native模块接口集合。
|
||||
*
|
||||
* @param type ArkUI提供的Native接口集合大类,例如UI组件接口类:ARKUI_NATIVE_NODE。
|
||||
* @param version native接口结构体的版本信息,通过结构体支持的版本枚举获得,如ARKUI_NATIVE_NODE的可用版本{@link ARKUI_NATIVE_NODE_VERSION_1}。
|
||||
* @return ArkUI_AnyNativeAPI* 返回携带版本的Native接口抽象对象。
|
||||
* @code {.cpp}
|
||||
* #include<arkui/native_interface.h>
|
||||
* #include<arkui/native_node.h>
|
||||
*
|
||||
* auto anyNativeAPI = OH_ArkUI_QueryModuleInterface(ARKUI_NATIVE_NODE, ARKUI_NATIVE_NODE_VERSION_1);
|
||||
* if (anyNativeAPI->version == ARKUI_NATIVE_NODE_VERSION_1) {
|
||||
* auto nativeNodeApi = reinterpret_cast<ArkUI_NativeNodeAPI_1*>(anyNativeAPI);
|
||||
* }
|
||||
* @endcode
|
||||
*
|
||||
* @since 12
|
||||
*/
|
||||
ArkUI_AnyNativeAPI* OH_ArkUI_QueryModuleInterface(ArkUI_NativeAPIVariantKind type, int32_t version);
|
||||
|
||||
#ifdef __cplusplus
|
||||
};
|
||||
#endif
|
||||
|
File diff suppressed because it is too large
Load Diff
Loading…
x
Reference in New Issue
Block a user