dmauro / Keypress

A keyboard input capturing utility in which any key can be a modifier key.
http://dmauro.github.io/Keypress/
Apache License 2.0
3.18k stars 313 forks source link

How to stop listening to key events in elements created in the future? #123

Closed garyking closed 8 years ago

garyking commented 8 years ago

stop_listening() works fine for events that exist before the script is loaded, but it doesn't work for future events. What's the best way to do this?

Edit: I guess I could check the event for the current element to see if it's part of my list of "ignored elements".