I'm confused about this -- since focus is still in `$searchField`, how would CodeMirror even know about the key event?  Does the fix not work if you take these lines out?