mirror of
https://github.com/ksyasuda/SubMiner.git
synced 2026-11-22 16:46:10 -08:00
fix(jellyfin): find mpv when SubMiner is launched from Finder (#298)
This commit is contained in:
1 parent
01613f1be5
commit
d047e3e0a4
16 files changed
+193
-32
No files matched your search
+10
-3
@@ -392,7 +392,11 @@ import {
|
||||
getConfiguredWindowsMpvPathStatus,
|
||||
launchWindowsMpv,
|
||||
} from './main/runtime/windows-mpv-launch';
|
||||
import { resolveMpvExecutablePath, spawnMpvProcess } from './main/runtime/mpv-process';
|
||||
import {
|
||||
findMpvExecutablePath,
|
||||
resolveMpvExecutablePath,
|
||||
spawnMpvProcess,
|
||||
} from './main/runtime/mpv-process';
|
||||
import { createWaitForMpvConnectedHandler } from './main/runtime/jellyfin-remote-connection';
|
||||
import {
|
||||
DEFAULT_JELLYFIN_CLIENT_NAME,
|
||||
@@ -2995,8 +2999,11 @@ const mediaTimingReviewRuntime = createMediaTimingReviewRuntime({
|
||||
getMpvClient: () => appState.mpvClient,
|
||||
getCurrentMediaPath: () =>
|
||||
appState.currentMediaPath?.trim() || appState.mpvClient?.currentVideoPath?.trim() || null,
|
||||
getMpvExecutablePath: () =>
|
||||
configService.getConfig().mpv.executablePath || process.env.SUBMINER_MPV_PATH?.trim() || '',
|
||||
// An invalid configured path is passed through so the preview fails instead of using PATH mpv.
|
||||
getMpvExecutablePath: () => {
|
||||
const configuredPath = configService.getConfig().mpv.executablePath;
|
||||
return findMpvExecutablePath(configuredPath) || configuredPath;
|
||||
},
|
||||
createPreviewSession: () => new MediaTimingPreviewSession(),
|
||||
generateWaveform: (options) => generateSpeechWaveform(options),
|
||||
generateFrame: (options) => mediaTimingFrameExtractor.generate(options),
|
||||
|
||||
Reference in new issue
Block a user