summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--configs/kvmd/main/v0-hdmi.yaml1
-rw-r--r--configs/kvmd/main/v0-vga.yaml1
-rw-r--r--configs/kvmd/main/v1-hdmi.yaml1
-rw-r--r--configs/kvmd/main/v1-vga.yaml1
-rw-r--r--testenv/main.yaml1
-rw-r--r--web/share/js/kvm/stream.js33
6 files changed, 27 insertions, 11 deletions
diff --git a/configs/kvmd/main/v0-hdmi.yaml b/configs/kvmd/main/v0-hdmi.yaml
index 37e9f755..7ad0fa4b 100644
--- a/configs/kvmd/main/v0-hdmi.yaml
+++ b/configs/kvmd/main/v0-hdmi.yaml
@@ -43,6 +43,7 @@ kvmd:
- "--quality={quality}"
- "--desired-fps={desired_fps}"
- "--drop-same-frames=30"
+ - "--last-as-blank=0"
- "--unix={unix}"
- "--unix-rm"
- "--unix-mode=0660"
diff --git a/configs/kvmd/main/v0-vga.yaml b/configs/kvmd/main/v0-vga.yaml
index d70648c4..acd9c551 100644
--- a/configs/kvmd/main/v0-vga.yaml
+++ b/configs/kvmd/main/v0-vga.yaml
@@ -39,6 +39,7 @@ kvmd:
- "--desired-fps={desired_fps}"
- "--resolution=720x756"
- "--fake-resolution=800x600"
+ - "--last-as-blank=0"
- "--unix={unix}"
- "--unix-rm"
- "--unix-mode=0660"
diff --git a/configs/kvmd/main/v1-hdmi.yaml b/configs/kvmd/main/v1-hdmi.yaml
index 6bfb1672..830ff378 100644
--- a/configs/kvmd/main/v1-hdmi.yaml
+++ b/configs/kvmd/main/v1-hdmi.yaml
@@ -45,6 +45,7 @@ kvmd:
- "--quality={quality}"
- "--desired-fps={desired_fps}"
- "--drop-same-frames=30"
+ - "--last-as-blank=0"
- "--unix={unix}"
- "--unix-rm"
- "--unix-mode=0660"
diff --git a/configs/kvmd/main/v1-vga.yaml b/configs/kvmd/main/v1-vga.yaml
index 8593a377..87c25a4b 100644
--- a/configs/kvmd/main/v1-vga.yaml
+++ b/configs/kvmd/main/v1-vga.yaml
@@ -44,6 +44,7 @@ kvmd:
- "--desired-fps={desired_fps}"
- "--resolution=720x576"
- "--fake-resolution=800x600"
+ - "--last-as-blank=0"
- "--unix={unix}"
- "--unix-rm"
- "--unix-mode=0660"
diff --git a/testenv/main.yaml b/testenv/main.yaml
index 4ff88d94..f0f48d4d 100644
--- a/testenv/main.yaml
+++ b/testenv/main.yaml
@@ -35,6 +35,7 @@ kvmd:
- "--quality={quality}"
- "--desired-fps={desired_fps}"
- "--resolution=800x600"
+ - "--last-as-blank=0"
- "--unix={unix}"
- "--unix-rm"
- "--unix-mode=0666"
diff --git a/web/share/js/kvm/stream.js b/web/share/js/kvm/stream.js
index 48908b60..8338805c 100644
--- a/web/share/js/kvm/stream.js
+++ b/web/share/js/kvm/stream.js
@@ -101,8 +101,6 @@ export function Streamer() {
}
if (__ensureStream(state.stream.clients_stat)) {
- $("stream-image").className = "stream-image-active";
- $("stream-box").classList.remove("stream-box-inactive");
$("stream-led").className = "led-green";
$("stream-led").title = "Stream is active";
wm.switchDisabled($("stream-screenshot-button"), false);
@@ -112,11 +110,9 @@ export function Streamer() {
tools.info("Stream: active");
}
- __updateStreamHeader(true);
+ __updateStreamWindow(true, state.source.online);
} else {
- $("stream-image").className = "stream-image-inactive";
- $("stream-box").classList.add("stream-box-inactive");
$("stream-led").className = "led-gray";
$("stream-led").title = "Stream inactive";
wm.switchDisabled($("stream-screenshot-button"), true);
@@ -125,7 +121,7 @@ export function Streamer() {
wm.switchDisabled($("stream-desired-fps-slider"), true);
tools.info("Stream: inactive");
- __updateStreamHeader(false);
+ __updateStreamWindow(false, false);
}
};
@@ -161,14 +157,29 @@ export function Streamer() {
}
};
- var __updateStreamHeader = function(online) {
+ var __updateStreamWindow = function(is_active, online) {
+ if (online) {
+ $("stream-image").className = "stream-image-active";
+ $("stream-box").classList.remove("stream-box-inactive");
+ } else {
+ $("stream-image").className = "stream-image-inactive";
+ $("stream-box").classList.add("stream-box-inactive");
+ }
+
let el_grab = document.querySelector("#stream-window-header .window-grab");
let el_info = $("stream-info");
- if (online) {
- let fps_suffix = (__client_fps >= 0 ? ` / ${__client_fps} fps` : "");
- el_grab.innerHTML = el_info.innerHTML = `Stream – ${__resolution.width}x${__resolution.height}${fps_suffix}`;
+ if (is_active) {
+ let title = "Stream – ";
+ if (!online) {
+ title += "no signal / ";
+ }
+ title += `${__resolution.width}x${__resolution.height}`;
+ if (__client_fps >= 0) {
+ title += ` / ${__client_fps} fps`;
+ }
+ el_grab.innerHTML = el_info.innerHTML = title;
} else {
- el_grab.innerHTML = el_info.innerHTML = "Stream – offline";
+ el_grab.innerHTML = el_info.innerHTML = "Stream – inactive";
}
};