mirror of
https://github.com/Termix-SSH/Termix.git
synced 2026-10-30 15:15:24 +00:00
fix(remote-desktop): clip cursor overflow without disabling zoom (#1535)
This commit is contained in:
1 parent
93db4799c0
commit
dc6c522782
1 file changed
+3
-3
@@ -176,8 +176,8 @@ export const GuacamoleDisplay = forwardRef<
|
|||||||
const scale = fitScaleRef.current * zoom;
|
const scale = fitScaleRef.current * zoom;
|
||||||
scaleRef.current = scale;
|
scaleRef.current = scale;
|
||||||
display.scale(scale);
|
display.scale(scale);
|
||||||
displayRef.current.style.width = `${display.getWidth() * scale}px`;
|
displayRef.current.style.width = `${Math.floor(display.getWidth() * scale)}px`;
|
||||||
displayRef.current.style.height = `${display.getHeight() * scale}px`;
|
displayRef.current.style.height = `${Math.floor(display.getHeight() * scale)}px`;
|
||||||
}
|
}
|
||||||
onZoomChange?.(zoom);
|
onZoomChange?.(zoom);
|
||||||
return zoom;
|
return zoom;
|
||||||
@@ -904,7 +904,7 @@ export const GuacamoleDisplay = forwardRef<
|
|||||||
>
|
>
|
||||||
<div
|
<div
|
||||||
ref={displayRef}
|
ref={displayRef}
|
||||||
className="relative flex min-h-full min-w-full items-center justify-center"
|
className="relative flex min-h-full min-w-full items-center justify-center overflow-hidden"
|
||||||
style={{
|
style={{
|
||||||
cursor: isReady ? "none" : "default",
|
cursor: isReady ? "none" : "default",
|
||||||
visibility: isReady ? "visible" : "hidden",
|
visibility: isReady ? "visible" : "hidden",
|
||||||
|
|||||||
Reference in new issue
Block a user