mirror of
https://github.com/th-ch/youtube-music.git
synced 2026-01-16 20:52:06 +00:00
8
providers/song-controls-front.ts
Normal file
8
providers/song-controls-front.ts
Normal file
@ -0,0 +1,8 @@
|
||||
import { ipcRenderer } from 'electron';
|
||||
|
||||
export const setupSongControls = () => {
|
||||
document.addEventListener('apiLoaded', (event) => {
|
||||
ipcRenderer.on('seekTo', (_, t: number) => event.detail.seekTo(t));
|
||||
ipcRenderer.on('seekBy', (_, t: number) => event.detail.seekBy(t));
|
||||
}, { once: true, passive: true });
|
||||
};
|
||||
Reference in New Issue
Block a user