diff --git a/src/composables/useHandleScreen.ts b/src/composables/useHandleScreen.ts index a6b1492..bd4a8eb 100644 --- a/src/composables/useHandleScreen.ts +++ b/src/composables/useHandleScreen.ts @@ -53,7 +53,7 @@ export const useHandleScreen = (callback: () => void) => { } //跳转屏保挂载到全局 供app使用 - window.sleepToWallpaper = () => { + window.leaveScreenSave = () => { checkHandleScreen() } @@ -86,7 +86,7 @@ export const useHandleScreen = (callback: () => void) => { showCountDownDialog.value = (indexTime >= MIN_TIME && indexTime <= MAX_TIME) || (wallpaperTime >= MIN_TIME && wallpaperTime <= MAX_TIME) }) - watch(mapStatus, async (newVal: boolean) => { + watch(mapStatus, (newVal: boolean) => { //当地图加载成功之后自动触发一次屏保弹框以便能进入屏保 if (newVal) { if (!nativeMethods.value?.hasProgram()) { diff --git a/src/types/native.d.ts b/src/types/native.d.ts index 29a782b..284a9de 100644 --- a/src/types/native.d.ts +++ b/src/types/native.d.ts @@ -35,14 +35,14 @@ export declare global { pushFaceAttribute(): VideoStream //APP获取人脸属性推送给应用 takePhoto(): string //应用通知APP拍照 返回Base64 startVoice(): boolean //应用通知APP开始语音识别 - stopVoice(): boolean //应用通知APP开始语音识别 + stopVoice(): boolean //应用通知APP停止语音识别 voiceContent(): VoiceContent //语音返回数据 deviceInfo(): HardwareInfo //设备信息 goScreenSave(): void // 针对导视应用与app之间屏保跳转进行通讯 hasProgram(): boolean //是否有节目列表 用于前端导视是否弹起屏保弹框 } interface Window { - sleepToWallpaper(): void + leaveScreenSave(): void android: NativeMethods chrome: { webview: {