diff --git a/pages/hotkey_mapper.html b/pages/hotkey_mapper.html index d6b65b5..6a5c5f2 100644 --- a/pages/hotkey_mapper.html +++ b/pages/hotkey_mapper.html @@ -1,92 +1,105 @@ - - - - - hotkey | Mapper Tool - - - - - -
-

Hotkey Code

-

Press a key combination to see the corresponding hotkey string. Quickly press another combination to build a sequence.

-
- - -
- - + - + - + - - Copy to clipboard - + Copy to clipboard +
- - - + hotkeyCodeElement.addEventListener('keyup', () => { + // we still have to use the keydown event, not the keyup event, because the keyup event won't have the modifier + // properties (ie, `ctrlKey` will be false). + if (lastKeyDownModifierEvent) registerEvent(lastKeyDownModifierEvent) + }) + resetButtonElement.addEventListener('click', () => { + sequenceTracker.reset() + hotkeyCodeElement.value = '' + }) + + diff --git a/pages/index.html b/pages/index.html index 68cdde3..812a50b 100644 --- a/pages/index.html +++ b/pages/index.html @@ -5,7 +5,7 @@ hotkey - +