| 109 | // The handler stack handles chrome events (which may need to be suppressed) and internal (pseudo) |
| 110 | // events. This checks whether the event at hand is a chrome event. |
| 111 | isChromeEvent(event) { |
| 112 | // TODO(philc): Shorten this. |
| 113 | return ((event != null ? event.preventDefault : undefined) != null) || |
| 114 | ((event != null ? event.stopImmediatePropagation : undefined) != null); |
| 115 | } |
| 116 | |
| 117 | // Convenience wrappers. Handlers must return an approriate value. These are wrappers which |
| 118 | // handlers can use to always return the same value. This then means that the handler itself can |