summaryrefslogtreecommitdiff
path: root/web/js/kvm/mouse.js
diff options
context:
space:
mode:
Diffstat (limited to 'web/js/kvm/mouse.js')
-rw-r--r--web/js/kvm/mouse.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/web/js/kvm/mouse.js b/web/js/kvm/mouse.js
index 9f93a659..58e46d15 100644
--- a/web/js/kvm/mouse.js
+++ b/web/js/kvm/mouse.js
@@ -21,8 +21,8 @@ function Mouse() {
$("stream-box").oncontextmenu = (event) => event.preventDefault();
$("stream-box").onmousemove = __moveHandler;
$("stream-box").onwheel = __wheelHandler;
-
$("stream-box").ontouchstart = (event) => __touchMoveHandler(event);
+
Array.prototype.forEach.call(document.querySelectorAll("[data-mouse-button]"), function(el_button) {
var button = el_button.getAttribute("data-mouse-button");
tools.setOnDown(el_button, () => __sendButton(button, true));
@@ -115,6 +115,7 @@ function Mouse() {
x: __translate(pos.x, 0, el_stream_image.clientWidth, -32768, 32767),
y: __translate(pos.y, 0, el_stream_image.clientHeight, -32768, 32767),
};
+
tools.debug("Mouse: moved:", to);
if (__ws) {
__ws.send(JSON.stringify({