madrobby/zepto — pull request #402 by joelambert (2012-02-21 11:23:12+00:00)
Title: Added support for `blur` and `focus` when used with the `delegate()` function

The `blur` and `focus` events don't bubble so I've modified the `delegate()` function to swap in `focusin` and `focusout` instead.

Firefox doesn't support these events so as a fallback I've modified the code to listen for `blur` and `focus` using capture. Unfortunately there is no neat way to feature detect support for `focusin` so I've had to just test against $.webkit.

I've also created a test in zepto.html which passes in both browsers.