From dcaa9890141210e0c182f73ba824f3434171cbd7 Mon Sep 17 00:00:00 2001 From: jixinbao Date: Thu, 23 May 2024 15:33:54 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E5=BC=95=E5=85=A5=20event=20=E6=B5=8B?= =?UTF-8?q?=E8=AF=95=E6=96=B9=E6=A1=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- store/index.uts | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/store/index.uts b/store/index.uts index df8e5b1a..b6dda9cf 100644 --- a/store/index.uts +++ b/store/index.uts @@ -14,12 +14,15 @@ type State = { safeArea : SafeArea // 设备像素比 devicePixelRatio : number + // 事件判断回调 + eventCallbackNum: number } export const state = reactive({ lifeCycleNum: 0, statusBarHeight: 0, - devicePixelRatio: 1, + devicePixelRatio: 1, + eventCallbackNum: 0, safeArea: { top: 0, right: 0, @@ -32,6 +35,10 @@ export const state = reactive({ export const setLifeCycleNum = (num : number) => { state.lifeCycleNum = num +} + +export const setEventCallbackNum = (num : number) => { + state.eventCallbackNum = num } export const setStatusBarHeight = (height : number) => { @@ -45,3 +52,4 @@ export const setSafeArea = (value : SafeArea) => { export const setDevicePixelRatio = (devicePixelRatio : number) => { state.devicePixelRatio = devicePixelRatio } + -- GitLab