MCPcopy Index your code
hub / github.com/ChinaGodMan/UserScripts / bindHotkey

Function bindHotkey

web-clipper/web-clipper.user.js:525–530  ·  view source on GitHub ↗
(key)

Source from the content-addressed store, hash-verified

523 let currentHotkey = GM_getValue(STORAGE_KEY, DEFAULT_KEY)
524
525 function bindHotkey(key) {
526 Mousetrap.reset()
527 Mousetrap.bind(key, function () {
528 startSelecting()
529 })
530 }
531
532 bindHotkey(currentHotkey)
533 GM_registerMenuCommand(translate.hotkey1, openHotkeyUI)

Callers 2

openHotkeyUIFunction · 0.85

Calls 1

startSelectingFunction · 0.85

Tested by

no test coverage detected