This commit is contained in:
Il Harper 2024-07-29 14:21:51 +08:00
parent 2fd93dfb88
commit 660c7d5a7e
No known key found for this signature in database
GPG Key ID: 4B71FCA698E7E8EC
2 changed files with 20 additions and 0 deletions

View File

@ -0,0 +1,14 @@
---
title: 2151启动了其他应用
sidebar_position: 2151
---
import { ErrorScope } from '@site/src/components/ErrorScope'
<ErrorScope scope="user" />
启动的应用并非 QQ而是其他应用。
一般情况下,当 QQ 在下列情况下启动时Chronocat 不会启动:
1. 小程序

View File

@ -1,4 +1,5 @@
import h from '@satorijs/element' import h from '@satorijs/element'
import { app } from 'electron'
import { initServers } from './server' import { initServers } from './server'
import { api } from './services/api' import { api } from './services/api'
import { getAuthData } from './services/authData' import { getAuthData } from './services/authData'
@ -28,6 +29,11 @@ export const chronocat = () => {
l.info(`${cyan('Chronocat')} ${bold(__DEFINE_CHRONO_VERSION__)}`) l.info(`${cyan('Chronocat')} ${bold(__DEFINE_CHRONO_VERSION__)}`)
l.info(grey('当左侧错误指示灯亮起时,点击错误码以检查说明。')) l.info(grey('当左侧错误指示灯亮起时,点击错误码以检查说明。'))
if (app.commandLine.hasSwitch('loadapp')) {
l.warn('启动的应用并非 QQChronocat 不会启用。', { code: 2151 })
return
}
let ready: () => void let ready: () => void
const readyPromise = new Promise<void>((res) => { const readyPromise = new Promise<void>((res) => {
ready = res ready = res