(e)
| 2176 | } |
| 2177 | |
| 2178 | function onKeyPress(e) { |
| 2179 | var cm = this; |
| 2180 | if (signalDOMEvent(cm, e) || cm.options.onKeyEvent && cm.options.onKeyEvent(cm, addStop(e))) return; |
| 2181 | var keyCode = e.keyCode, charCode = e.charCode; |
| 2182 | if (opera && keyCode == lastStoppedKey) {lastStoppedKey = null; e_preventDefault(e); return;} |
| 2183 | if (((opera && (!e.which || e.which < 10)) || khtml) && handleKeyBinding(cm, e)) return; |
| 2184 | var ch = String.fromCharCode(charCode == null ? keyCode : charCode); |
| 2185 | if (handleCharBinding(cm, e, ch)) return; |
| 2186 | if (ie && !ie_lt9) cm.display.inputHasSelection = null; |
| 2187 | fastPoll(cm); |
| 2188 | } |
| 2189 | |
| 2190 | function onFocus(cm) { |
| 2191 | if (cm.options.readOnly == "nocursor") return; |
nothing calls this directly
no test coverage detected