Use the `target` field of events, insted of `srcElement`.

This fixes #24.
Kudos to @mitar for the tip.