diff options
author | Maxim Devaev <[email protected]> | 2021-08-13 16:39:56 +0300 |
---|---|---|
committer | Maxim Devaev <[email protected]> | 2021-08-13 16:39:56 +0300 |
commit | 976662df8310b145f23ac22360a3bd9e38ed65a1 (patch) | |
tree | 369dbca05e61bf9d950e15960749725f8824f2c4 /web/share/js/kvm/mouse.js | |
parent | c233e3bee7b30f7f285869d81f2e18b16b8708c2 (diff) |
bindSimpleSwitch()
Diffstat (limited to 'web/share/js/kvm/mouse.js')
-rw-r--r-- | web/share/js/kvm/mouse.js | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/web/share/js/kvm/mouse.js b/web/share/js/kvm/mouse.js index c3215d55..cfc70bff 100644 --- a/web/share/js/kvm/mouse.js +++ b/web/share/js/kvm/mouse.js @@ -61,10 +61,7 @@ export function Mouse(__getResolution, __recordWsEvent) { $("stream-box").onwheel = __streamWheelHandler; $("stream-box").ontouchstart = (event) => __streamTouchMoveHandler(event); - $("hid-mouse-squash-switch").checked = tools.storage.getBool("hid.mouse.squash", true); - tools.el.setOnClick($("hid-mouse-squash-switch"), function() { - tools.storage.setBool("hid.mouse.squash", $("hid-mouse-squash-switch").checked); - }, false); + tools.storage.bindSimpleSwitch($("hid-mouse-squash-switch"), "hid.mouse.squash", true); setInterval(__sendMove, 100); }; |