mirror of
https://github.com/jeffvli/feishin.git
synced 2026-05-08 13:00:13 +02:00
[enhancement]: allow downloading individual tracks for external use
This commit is contained in:
@@ -364,6 +364,10 @@ const createWindow = async (first = true) => {
|
||||
}
|
||||
});
|
||||
|
||||
ipcMain.on('download-url', (_event, url: string) => {
|
||||
mainWindow?.webContents.downloadURL(url);
|
||||
});
|
||||
|
||||
const globalMediaKeysEnabled = store.get('global_media_hotkeys', true) as boolean;
|
||||
|
||||
if (globalMediaKeysEnabled) {
|
||||
|
||||
@@ -47,7 +47,12 @@ const logger = (
|
||||
ipcRenderer.send('logger', cb);
|
||||
};
|
||||
|
||||
const download = (url: string) => {
|
||||
ipcRenderer.send('download-url', url);
|
||||
};
|
||||
|
||||
export const utils = {
|
||||
download,
|
||||
isLinux,
|
||||
isMacOS,
|
||||
isWindows,
|
||||
|
||||
Reference in New Issue
Block a user