toggle active flag in KeyboardNavigation

This commit is contained in:
NikolaBorislavovHristov 2019-08-02 16:54:55 +03:00
parent f7856d09e9
commit b83397a25e

View file

@ -21,6 +21,7 @@ function KeyboardNavigation() {
}
window.addEventListener('keydown', onKeyDown);
active = true;
}
function stop() {
if (!active) {
@ -28,6 +29,7 @@ function KeyboardNavigation() {
}
window.removeEventListener('keydown', onKeyDown);
active = false;
}
Object.defineProperties(this, {