Update: 使用 howler 优化音效播放逻辑
This commit is contained in:
@ -8,6 +8,7 @@ contextBridge.exposeInMainWorld('electronAPI', {
|
||||
console.error('播放音效失败:', err)
|
||||
}
|
||||
},
|
||||
getSoundPath: (soundFile) => ipcRenderer.invoke('get-sound-path', soundFile),
|
||||
showTooltip: (text) => ipcRenderer.send('show-tooltip', text),
|
||||
onUpdatePosition: (callback) => {
|
||||
ipcRenderer.on('update-position', (_, position) => callback(position))
|
||||
|
Reference in New Issue
Block a user