3대 근본 버그 수정 (RE 조사 기반)
1. HotkeyService: modifier 먼저 놓기 대응 - Alt+1에서 Alt를 먼저 놓아도 release 감지 - _handleKeyUp에서 pressed 핫키의 구성 키(main/modifier) 매칭 2. ResultPopup auto-close IPC 핸들러 추가 - window:hideResultPopup 핸들러가 없어서 팝업이 안 꺼지던 버그 - window-handlers.ts에 hideResultPopup/hideRecordingTip 핸들러 등록 3. bootstrap.ts 이중 팝업 제어 제거 - session-completed에서 무조건 showResultPopup 호출하던 코드 제거 - 팝업 제어는 VoiceModeService 내부에서만 처리 - bootstrap은 효과음만 담당
This commit is contained in:
parent
788600b66b
commit
c64ab3b58f
3 changed files with 49 additions and 29 deletions
|
|
@ -15,11 +15,6 @@ import { initDatabase } from './db'
|
|||
import {
|
||||
createMainWindow,
|
||||
preloadPopupWindows,
|
||||
showRecordingTip,
|
||||
hideRecordingTip,
|
||||
updateRecordingTipState,
|
||||
sendAudioLevelToTip,
|
||||
showResultPopup,
|
||||
showHistoryPopup,
|
||||
hideHistoryPopup,
|
||||
sendKeyToHistoryPopup,
|
||||
|
|
@ -134,28 +129,13 @@ async function initVoiceMode(): Promise<void> {
|
|||
|
||||
const soundEffect = getSoundEffectService()
|
||||
|
||||
// RecordingTip 연동: 세션 시작/종료 시 팝업 표시/숨김
|
||||
// 효과음 연동 (팝업 제어는 VoiceModeService 내부에서 처리)
|
||||
voiceMode.on('session-started', () => {
|
||||
soundEffect.play('recording-start')
|
||||
showRecordingTip('recording')
|
||||
})
|
||||
|
||||
voiceMode.on('audio-level', ({ level }) => {
|
||||
sendAudioLevelToTip(level)
|
||||
})
|
||||
|
||||
voiceMode.on('recognition-state-changed', ({ current }) => {
|
||||
if (current === 'recognizing') {
|
||||
updateRecordingTipState('thinking')
|
||||
}
|
||||
})
|
||||
|
||||
voiceMode.on('session-completed', ({ session, finalText }) => {
|
||||
soundEffect.play('recording-stop')
|
||||
hideRecordingTip()
|
||||
if (finalText.length > 0) {
|
||||
showResultPopup(finalText)
|
||||
}
|
||||
|
||||
// 이력 저장
|
||||
try {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue