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/atx.js | |
parent | c233e3bee7b30f7f285869d81f2e18b16b8708c2 (diff) |
bindSimpleSwitch()
Diffstat (limited to 'web/share/js/kvm/atx.js')
-rw-r--r-- | web/share/js/kvm/atx.js | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/web/share/js/kvm/atx.js b/web/share/js/kvm/atx.js index fb1e0d28..b0978b2c 100644 --- a/web/share/js/kvm/atx.js +++ b/web/share/js/kvm/atx.js @@ -36,11 +36,7 @@ export function Atx() { $("atx-power-led").title = "Power Led"; $("atx-hdd-led").title = "Disk Activity Led"; - $("atx-ask-switch").checked = tools.storage.getBool("atx.ask", true); - tools.el.setOnClick($("atx-ask-switch"), function() { - tools.storage.setBool("atx.ask", $("atx-ask-switch").checked); - }, false); - + tools.storage.bindSimpleSwitch($("atx-ask-switch"), "atx.ask", true); for (let args of [ ["atx-power-button", "power", "Are you sure you want to press the power button?"], |