mirror of
https://github.com/hicccc77/WeFlow.git
synced 2026-03-25 07:16:51 +00:00
feat: 一些优化
This commit is contained in:
@@ -20,6 +20,7 @@ import { voiceTranscribeService } from './services/voiceTranscribeService'
|
||||
import { videoService } from './services/videoService'
|
||||
import { snsService } from './services/snsService'
|
||||
import { contactExportService } from './services/contactExportService'
|
||||
import { windowsHelloService } from './services/windowsHelloService'
|
||||
|
||||
|
||||
// 配置自动更新
|
||||
@@ -798,6 +799,17 @@ function registerIpcHandlers() {
|
||||
return true
|
||||
})
|
||||
|
||||
// Windows Hello
|
||||
ipcMain.handle('auth:hello', async (event, message?: string) => {
|
||||
// 无论哪个窗口调用,都尝试强制附着到主窗口,确保体验一致
|
||||
// 如果主窗口不存在(极其罕见),则回退到调用者窗口
|
||||
const targetWin = (mainWindow && !mainWindow.isDestroyed())
|
||||
? mainWindow
|
||||
: (BrowserWindow.fromWebContents(event.sender) || undefined)
|
||||
|
||||
return windowsHelloService.verify(message, targetWin)
|
||||
})
|
||||
|
||||
// 导出相关
|
||||
ipcMain.handle('export:exportSessions', async (event, sessionIds: string[], outputDir: string, options: ExportOptions) => {
|
||||
const onProgress = (progress: ExportProgress) => {
|
||||
|
||||
Reference in New Issue
Block a user