mirror of
https://github.com/ksyasuda/SubMiner.git
synced 2026-10-21 05:01:26 -07:00
feat(overlay): run session help commands with Enter or double-click (#275)
This commit is contained in:
1 parent
4e43c5c6e1
commit
0bbd8617f4
16 files changed
+701
-49
No files matched your search
+7
-1
@@ -3073,9 +3073,15 @@ function openSubtitleGenerationOverlay(): void {
|
||||
);
|
||||
}
|
||||
|
||||
// currentMediaPath follows every mpv path change and is cleared on disconnect; the
|
||||
// client's currentVideoPath outlives the connection, so a reconnect could reuse it.
|
||||
function isMediaPlaybackActive(): boolean {
|
||||
return appState.mpvClient?.connected === true && Boolean(appState.currentMediaPath?.trim());
|
||||
}
|
||||
|
||||
function openSessionHelpOverlay(): void {
|
||||
openOverlayHostedModalWithOsd(
|
||||
openSessionHelpModalRuntime,
|
||||
(deps) => openSessionHelpModalRuntime({ ...deps, isMediaPlaybackActive }),
|
||||
'Session help overlay unavailable.',
|
||||
'Failed to open session help overlay.',
|
||||
);
|
||||
|
||||
Reference in new issue
Block a user